From: handa Date: Tue, 21 Aug 2007 07:17:33 +0000 (+0000) Subject: (ft_check_capability): Check cap->script_tag at first. X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=98fe2f4b871a1575f54e4b5a5602a115c21b985a;p=m17n%2Fm17n-lib.git (ft_check_capability): Check cap->script_tag at first. --- diff --git a/src/font-ft.c b/src/font-ft.c index 85c1298..e6f9bc2 100644 --- a/src/font-ft.c +++ b/src/font-ft.c @@ -2038,14 +2038,17 @@ ft_check_capability (MRealizedFont *rfont, MSymbol capability) MRealizedFontFT *ft_rfont = rfont->info; MFontCapability *cap = mfont__get_capability (capability); - if (cap->script != Mnil - && ft_check_script (ft_info, cap->script, ft_rfont->ft_face) < 0) + if (cap->script_tag) + { + if (ft_check_otf (ft_info, cap, ft_rfont->ft_face) < 0) + return -1; + } + else if (cap->script != Mnil + && ft_check_script (ft_info, cap->script, ft_rfont->ft_face) < 0) return -1; if (cap->language != Mnil && ft_check_language (ft_info, cap->language, ft_rfont->ft_face) < 0) return -1; - if (cap->script_tag && ft_check_otf (ft_info, cap, ft_rfont->ft_face) < 0) - return -1; return 0; }