serialize


Description:

[ Version ( since = "2.7.3" ) ]
public uint serialize (uint start, uint end, out uint8[] buf, out uint buf_consumed, Font? font, BufferSerializeFormat format, BufferSerializeFlags flags)

Serializes buffer into a textual representation of its content, whether Unicode codepoints or glyph identifiers and positioning information.

This is useful for showing the contents of the buffer, for example during debugging. See the documentation of serialize_unicode and serialize_glyphs for a description of the output format.

Parameters:

start

the first item in buffer to serialize.

end

the last item in buffer to serialize.

buf

output string to write serialized buffer into.

buf_consumed

if not `NULL`, will be set to the number of bytes written into buf.

font

the Font used to shape this buffer, needed to read glyph names and extents. If `NULL`, an empty font will be used.

format

the BufferSerializeFormat to use for formatting the output.

flags

the BufferSerializeFlags that control what glyph properties to serialize.

buf_size

the size of buf.

buffer

an Buffer buffer.

Returns:

The number of serialized items.