[HarfBuzz] more complete feature/mask control
Behdad Esfahbod
behdad at behdad.org
Fri May 28 14:44:59 PDT 2010
Thanks Jonathan,
It gives me a starting point. I'll commit and start working on it.
BTW, I realized that in or_masks(), we can't really binary search because:
1) While hb_buffer_add_utf*() set ->cluster to be src index, the user is
free to modify those to be some other value they find useful for future
retrieval (or use hb_buffer_add() instead).
2) If ensure_direction() reversed the buffer, ->cluster is not increasing
anymore.
3) Since we also reverse_clusters() in ensure_direction(), the ->cluster
array may not even be monotonic.
We probably can do something like walking over it once and see if it is
monotone and save the result and bsearch if it is.
behdad
On 05/28/2010 05:58 AM, Jonathan Kew wrote:
> Hi Behdad,
>
> For Gecko, we really need support for turning off some of the default features, in addition to specifying extra ones. So I've tried to fill out the implementation of feature control and mask settings a bit more fully; see attached patch.
>
> The code here takes a fairly simple-minded approach, on the assumption that the list of feature settings will normally be short and so it's not terribly expensive to iterate over it.
>
> Hope you can take this or some equivalent behavior soon,
>
> Jonathan
>
>
>
>
>
>
More information about the HarfBuzz
mailing list