PgGlyphString.getLogicalWidths

Given a PangoGlyphString and corresponding text, determine the width corresponding to each character.

When multiple characters compose a single cluster, the width of the entire cluster is divided equally among the characters.

See also [method@Pango.GlyphItem.get_logical_widths].

class PgGlyphString
void
getLogicalWidths
(
string text
,
int length
,,)

Parameters

text string

the text corresponding to the glyphs

length int

the length of @text, in bytes

embeddingLevel int

the embedding level of the string

logicalWidths int[]

an array whose length is the number of characters in text (equal to g_utf8_strlen (text, length) unless text has NUL bytes) to be filled in with the resulting character widths.

Meta