mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-25 00:41:09 +01:00
[ligature-cache] Handle case of ligature with no components (#5500)
In the cache with "seconds" set-digest.
This commit is contained in:
1 parent
724ae78d4c
commit
6b62d3678b
1 file changed
+7
-1
@@ -47,7 +47,13 @@ struct Ligature
|
||||
template <typename set_t>
|
||||
void collect_second (set_t &s) const
|
||||
{
|
||||
s.add (component[1]); // This adds codepoint 0 if component array is empty.
|
||||
if (unlikely (!component.get_length ()))
|
||||
{
|
||||
// A ligature without any components. Anything matches.
|
||||
s = set_t::full ();
|
||||
return;
|
||||
}
|
||||
s.add (component.arrayZ[0]);
|
||||
}
|
||||
|
||||
bool would_apply (hb_would_apply_context_t *c) const
|
||||
|
||||
Reference in new issue
Block a user