From 0066e824f02efce79e026f60391f3fd95214e1ac Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Fri, 23 Dec 2022 13:37:38 -0700 Subject: [PATCH] [util] Fix vertical positioning with --glyphs --- util/shape-options.hh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/util/shape-options.hh b/util/shape-options.hh index d5516a293..07dc4c138 100644 --- a/util/shape-options.hh +++ b/util/shape-options.hh @@ -71,6 +71,10 @@ struct shape_options_t if (glyphs) { + /* Call the setup_buffer first while the buffer is empty, + * as guess_segment_properties doesn't like glyphs in the buffer. */ + + setup_buffer (buffer); hb_buffer_deserialize_glyphs (buffer, text, text_len, nullptr,