[os2] Inline a trivial function
This commit is contained in:
parent
075fe33446
commit
2dcbf3bd07
|
@ -269,12 +269,8 @@ struct OS2
|
||||||
if (c->plan->flags & HB_SUBSET_FLAGS_NO_PRUNE_UNICODE_RANGES)
|
if (c->plan->flags & HB_SUBSET_FLAGS_NO_PRUNE_UNICODE_RANGES)
|
||||||
return_trace (true);
|
return_trace (true);
|
||||||
|
|
||||||
/* when --gids option is not used, no need to do collect_mapping that is
|
os2_prime->usFirstCharIndex = hb_min (0xFFFFu, c->plan->unicodes.get_min ());
|
||||||
* iterating all codepoints in each subtable, which is not efficient */
|
os2_prime->usLastCharIndex = hb_min (0xFFFFu, c->plan->unicodes.get_max ());
|
||||||
uint16_t min_cp, max_cp;
|
|
||||||
find_min_and_max_codepoint (&c->plan->unicodes, &min_cp, &max_cp);
|
|
||||||
os2_prime->usFirstCharIndex = min_cp;
|
|
||||||
os2_prime->usLastCharIndex = max_cp;
|
|
||||||
|
|
||||||
_update_unicode_ranges (&c->plan->unicodes, os2_prime->ulUnicodeRange);
|
_update_unicode_ranges (&c->plan->unicodes, os2_prime->ulUnicodeRange);
|
||||||
|
|
||||||
|
@ -311,14 +307,6 @@ struct OS2
|
||||||
ulUnicodeRange[i] = ulUnicodeRange[i] & newBits[i]; // set bits only if set in the original
|
ulUnicodeRange[i] = ulUnicodeRange[i] & newBits[i]; // set bits only if set in the original
|
||||||
}
|
}
|
||||||
|
|
||||||
static void find_min_and_max_codepoint (const hb_set_t *codepoints,
|
|
||||||
uint16_t *min_cp, /* OUT */
|
|
||||||
uint16_t *max_cp /* OUT */)
|
|
||||||
{
|
|
||||||
*min_cp = hb_min (0xFFFFu, codepoints->get_min ());
|
|
||||||
*max_cp = hb_min (0xFFFFu, codepoints->get_max ());
|
|
||||||
}
|
|
||||||
|
|
||||||
/* https://github.com/Microsoft/Font-Validator/blob/520aaae/OTFontFileVal/val_OS2.cs#L644-L681
|
/* https://github.com/Microsoft/Font-Validator/blob/520aaae/OTFontFileVal/val_OS2.cs#L644-L681
|
||||||
* https://docs.microsoft.com/en-us/typography/legacy/legacy_arabic_fonts */
|
* https://docs.microsoft.com/en-us/typography/legacy/legacy_arabic_fonts */
|
||||||
enum font_page_t
|
enum font_page_t
|
||||||
|
|
Loading…
Reference in New Issue