[HarfBuzz] inputting text already containing some glpyhs
Behdad Esfahbod
behdad at behdad.org
Thu Apr 21 13:57:35 PDT 2011
Hi Eric,
I understand your request, but I don't think we want to handle that. The way
such a case would work, IMO, is that the higher level will break the text into
text and glyph-index segments, and only pass the text runs to the shaper.
Shaping glyph indices makes little sense.
behdad
On 04/21/11 16:51, Eric Wasylishen wrote:
> Hi,
> I have a use case where I want to shape some text which might contain a mix of glyph indices and unicode characters. For example, a string like "hello <glyph 123> world".
>
> I get the feeling that just having strings like this is discouraged. There are, however, files in the wild that do this (e.g. Apple RTF files will sometime contain glyph indices).
>
> What would you think about allowing a Harfbuzz user preparing their buffer to call hb_buffer_add_glyph with a mask to indicate that the glyph being inserted is already a glyph index? It looks like the first few phases of hb_ot_shape_execute_internal, up to when hb_substitute_default is called, would have to check for this mask and ignore the glyph or treat it as some placeholder unicode character.
>
> Cheers,
> Eric
>
> P.S. I'm looking at adding Harfbuzz support to GNUstep, which is where this problem comes up.
More information about the HarfBuzz
mailing list