[HarfBuzz] HARFBUZZ - ARABIC SHAPING PROBLEM
Behdad Esfahbod
behdad at behdad.org
Thu Oct 13 11:35:06 PDT 2011
On 10/12/11 06:51, Sergey wrote:
> hb_font_t *hb_ft_font = hb_ft_font_create(Font_Mgr::Font_Face, NULL);
>
> hb_face_t *hb_ft_face = hb_ft_face_create(Font_Mgr::Font_Face, NULL);
You don't need the hb_ft_face anymore. You can drop it.
> hb_ft_font_set_funcs (hb_ft_font); // IS IT AS A MUST or could be ommited??
You don't need this. hb_ft_font_create already does it for you.
> // INPUT string is wchar_t - NOT SURE that further conversion works well!!
Yeah. Correct.
> const char *cur_lang = "ar"; // OK
> hb_buffer_set_unicode_funcs(buffer, hb_icu_get_unicode_funcs());
>
> // WHAT IS THE PURPOSE OF USING hb_icu_get_unicode_funcs() or what own
> implemtation should provide??
You can drop these now. The buffer defaults to whatever implementation was
compiled in (ICU in this case).
> /* Layout the text */
>
> hb_buffer_add_utf16 (buffer, cur_text_16, 5, 0, 5); // WHAT is the semantic
> usage of 3 last parameters??
The first integer is length. The next two are used to specify the portion of
text to shape. You got them right.
> What are we donig wrong??
What font are you using? Does the font work with other shapers?
behdad
More information about the HarfBuzz
mailing list