[MPlayer-cvslog] r22228 - in trunk: help/help_mp-en.h libass/ass_font.c
eugeni
subversion at mplayerhq.hu
Thu Feb 15 23:03:09 CET 2007
Author: eugeni
Date: Thu Feb 15 23:03:09 2007
New Revision: 22228
Modified:
trunk/libass/ass_font.c
Changes in other areas also in this revision:
Modified:
trunk/help/help_mp-en.h
Log:
Select the first charmap in the font, if FreeType did not autoselect any.
This happens, for example, with fonts only having an Apple Roman charmap.
Modified: trunk/libass/ass_font.c
==============================================================================
--- trunk/libass/ass_font.c (original)
+++ trunk/libass/ass_font.c Thu Feb 15 23:03:09 2007
@@ -47,9 +47,19 @@
unsigned eid = cmap->encoding_id;
if (pid == 3 /*microsoft*/ && (eid == 1 /*unicode bmp*/ || eid == 10 /*full unicode*/)) {
FT_Set_Charmap(face, cmap);
- break;
+ return;
}
}
+
+ if (!face->charmap) {
+ if (face->num_charmaps == 0) {
+ mp_msg(MSGT_ASS, MSGL_WARN, MSGTR_LIBASS_NoCharmaps);
+ return;
+ }
+ mp_msg(MSGT_ASS, MSGL_WARN, MSGTR_LIBASS_NoCharmapAutodetected);
+ FT_Set_Charmap(face, face->charmaps[0]);
+ return;
+ }
}
/**
More information about the MPlayer-cvslog
mailing list