Function

Pango-1.0Pangoshape_itemSince 1.50

  • Convert the characters in item into glyphs.

    This is similar to Pango.shape_with_flags, except it takes a Pango.Item instead of separate item_text and analysis arguments.

    It also takes log_attrs, which are needed for implementing some aspects of hyphen insertion and text transforms (in particular, capitalization).

    Note that the extra attributes in the analyis that is returned from Pango.itemize have indices that are relative to the entire paragraph, so you do not pass the full paragraph text as paragraph_text, you need to subtract the item offset from their indices before calling Pango.shape_with_flags.

    Parameters

    • item: Pango.Item

      Pango.Item to shape

    • paragraph_text: string

      text of the paragraph (see details).

    • paragraph_length: number

      the length (in bytes) of paragraph_text. -1 means nul-terminated text.

    • log_attrs: LogAttr

      array of Pango.LogAttr for item

    • flags: Pango.ShapeFlags

      flags influencing the shaping process

    Returns GlyphString

    1.50