mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-29 09:34:05 +01:00
[Indic] Improve check on ligatures
Only skip actual ligatures, not marks in-between ligature components.
This commit is contained in:
1 parent
771a8f5028
commit
c3e6fdc379
2 files changed
+6
-1
No files matched your search
@@ -51,6 +51,11 @@ get_lig_comp (const hb_glyph_info_t &info)
|
||||
{
|
||||
return info.lig_props() & 0x0F;
|
||||
}
|
||||
static inline bool
|
||||
is_a_ligature (const hb_glyph_info_t &info)
|
||||
{
|
||||
return unlikely (get_lig_id (info) && ~get_lig_comp (info));
|
||||
}
|
||||
|
||||
static inline uint8_t allocate_lig_id (hb_buffer_t *buffer) {
|
||||
uint8_t lig_id = buffer->next_serial () & 0x0F;
|
||||
|
||||
@@ -201,7 +201,7 @@ static inline bool
|
||||
is_one_of (const hb_glyph_info_t &info, unsigned int flags)
|
||||
{
|
||||
/* If it ligated, all bets are off. */
|
||||
if (unlikely (get_lig_id (info))) return false;
|
||||
if (is_a_ligature (info)) return false;
|
||||
return !!(FLAG (info.indic_category()) & flags);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user