[buffer] Comment

This commit is contained in:
Behdad Esfahbod 2022-02-03 11:19:23 -06:00
parent e59da2871a
commit 8670ffbf4c
1 changed files with 20 additions and 17 deletions

View File

@ -386,7 +386,10 @@ struct hb_buffer_t
HB_INTERNAL void delete_glyph (); HB_INTERNAL void delete_glyph ();
void set_glyph_flags (hb_mask_t mask, /* Adds glyph flags in mask to infos with clusters between start and end.
* The start index will be from out-buffer if from_out_buffer is true.
* If interior is true, then the cluster having the minimum value is skipped. */
void _set_glyph_flags (hb_mask_t mask,
unsigned start = 0, unsigned start = 0,
unsigned end = (unsigned) -1, unsigned end = (unsigned) -1,
bool interior = false, bool interior = false,
@ -437,25 +440,25 @@ struct hb_buffer_t
void unsafe_to_break (unsigned int start = 0, unsigned int end = -1) void unsafe_to_break (unsigned int start = 0, unsigned int end = -1)
{ {
set_glyph_flags (HB_GLYPH_FLAG_UNSAFE_TO_BREAK | HB_GLYPH_FLAG_UNSAFE_TO_CONCAT, _set_glyph_flags (HB_GLYPH_FLAG_UNSAFE_TO_BREAK | HB_GLYPH_FLAG_UNSAFE_TO_CONCAT,
start, end, start, end,
true); true);
} }
void unsafe_to_concat (unsigned int start = 0, unsigned int end = -1) void unsafe_to_concat (unsigned int start = 0, unsigned int end = -1)
{ {
set_glyph_flags (HB_GLYPH_FLAG_UNSAFE_TO_CONCAT, _set_glyph_flags (HB_GLYPH_FLAG_UNSAFE_TO_CONCAT,
start, end, start, end,
true); true);
} }
void unsafe_to_break_from_outbuffer (unsigned int start = 0, unsigned int end = -1) void unsafe_to_break_from_outbuffer (unsigned int start = 0, unsigned int end = -1)
{ {
set_glyph_flags (HB_GLYPH_FLAG_UNSAFE_TO_BREAK | HB_GLYPH_FLAG_UNSAFE_TO_CONCAT, _set_glyph_flags (HB_GLYPH_FLAG_UNSAFE_TO_BREAK | HB_GLYPH_FLAG_UNSAFE_TO_CONCAT,
start, end, start, end,
true, true); true, true);
} }
void unsafe_to_concat_from_outbuffer (unsigned int start = 0, unsigned int end = -1) void unsafe_to_concat_from_outbuffer (unsigned int start = 0, unsigned int end = -1)
{ {
set_glyph_flags (HB_GLYPH_FLAG_UNSAFE_TO_CONCAT, _set_glyph_flags (HB_GLYPH_FLAG_UNSAFE_TO_CONCAT,
start, end, start, end,
false, true); false, true);
} }