Add code points to the buffer.
Array of code points to be added to the buffer.
The offset of the first code point to add to the buffer.
The number of code points to add to the buffer, or null for the end of the array.
Add text to the buffer.
Text to be added to the buffer.
The offset of the first character to add to the buffer.
The number of characters to add to the buffer, or null for the end of text.
Similar to reset(), but does not clear the Unicode functions and the replacement code point.
Return the buffer content type.
The buffer content type as a BufferContentType value.
Get the glyph information and positions from the buffer.
The glyph information and positions.
The glyph information is returned as an array of objects with the properties from getGlyphInfos and getGlyphPositions combined.
Get the the number of items in the buffer.
The buffer length.
Set buffer script, language and direction.
This needs to be done before shaping.
Reset the buffer to its initial status.
Serialize the buffer contents to a string.
Optionalfont: Font | nullThe font to use for serialization.
The starting index of the glyphs to serialize.
Optionalend: number | nullThe ending index of the glyphs to serialize.
The BufferSerializeFormat to serialize the buffer contents to.
A combination of BufferSerializeFlag values (OR them together).
The serialized buffer contents.
Set the HarfBuzz clustering level.
Affects the cluster values returned from shaping.
Clustering level. See the HarfBuzz manual chapter on Clusters.
Set buffer flags explicitly.
A combination of BufferFlag values (OR them together).
Set buffer language explicitly.
The buffer language
Set buffer script explicitly.
The buffer script
Update the glyph positions in the buffer. WARNING: Do not use unless you know what you are doing.
An object representing a HarfBuzz buffer. A buffer holds the input text and its properties before shaping, and the output glyphs and their information after shaping.