BLGlyphRunIterator Class Reference [¶]
A helper to iterate over a BLGlyphRun
.
Takes into consideration glyph-id advance and glyph-offset advance.
Example:
BLGlyphRunIterator it(glyph_run);
if (it.has_offsets()) {
while (!it.at_end()) {
BLGlyphId glyph_id = it.glyph_id();
BLPoint offset = it.placement();
// Do something with `glyph_id` and `offset`.
it.advance();
}
}
else {
while (!it.at_end()) {
BLGlyphId glyph_id = it.glyph_id();
// Do something with `glyph_id`.
it.advance();
}
}
}