diff options
author | Grigori Goronzy <greg@chown.ath.cx> | 2016-06-10 13:35:28 +0200 |
---|---|---|
committer | Grigori Goronzy <greg@chown.ath.cx> | 2016-06-10 13:35:28 +0200 |
commit | c93cb3dbfb7357179379ffd19ff973cf062e2129 (patch) | |
tree | 7cab519b4d6e9c63ff4a7ae17d5d7aa874884e32 /libass | |
parent | ecebb3fecc2efae2ff406a89aa4c01112919c2af (diff) | |
download | libass-c93cb3dbfb7357179379ffd19ff973cf062e2129.tar.bz2 libass-c93cb3dbfb7357179379ffd19ff973cf062e2129.tar.xz |
shaper: drop RTL base direction for RTL font encodings
VSFilter uses LTR base direction even if Arabic or Hebrew font
encodings are used, so do the same. This resolves some reordering
issues.
Fixes #224.
Diffstat (limited to 'libass')
-rw-r--r-- | libass/ass_shaper.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/libass/ass_shaper.c b/libass/ass_shaper.c index 31e3682..fa50982 100644 --- a/libass/ass_shaper.c +++ b/libass/ass_shaper.c @@ -965,11 +965,10 @@ FriBidiStrIndex *ass_shaper_reorder(ASS_Shaper *shaper, TextInfo *text_info) } /** - * \brief Resolve a Windows font charset number to a suitable - * base direction. 177 and 178 are Hebrew and Arabic respectively, and - * they map to RTL. Everything else maps to LTR for compatibility - * reasons. The special value -1, which is not a legal Windows font charset - * number, can be used for autodetection. + * \brief Resolve a Windows font charset number to a suitable base + * direction. Generally, use LTR for compatibility with VSFilter. The + * special value -1, which is not a legal Windows font charset number, + * can be used for autodetection. * \param enc Windows font encoding */ FriBidiParType resolve_base_direction(int enc) @@ -977,9 +976,6 @@ FriBidiParType resolve_base_direction(int enc) switch (enc) { case -1: return FRIBIDI_PAR_ON; - case 177: - case 178: - return FRIBIDI_PAR_RTL; default: return FRIBIDI_PAR_LTR; } |