PgAttributeList

The #PangoAttrList structure represents a list of attributes that apply to a section of text. The attributes are, in general, allowed to overlap in an arbitrary fashion, however, if the attributes are manipulated only through pango_attr_list_change(), the overlap between properties will meet stricter criteria.

Since the #PangoAttrList structure is stored as a linear list, it is not suitable for storing attributes for large amounts of text. In general, you should not use a single #PangoAttrList for more than one paragraph of text.

Constructors

this
this(PangoAttrList* pangoAttrList, bool ownedRef)

Sets our main struct and passes it to the parent class.

this
this()

Create a new empty attribute list with a reference count of one.

Destructor

~this
~this()
Undocumented in source.

Members

Functions

change
void change(PgAttribute attr)

Insert the given attribute into the #PangoAttrList. It will replace any attributes of the same type on that segment and be merged with any adjoining attributes that are identical.

copy
PgAttributeList copy()

Copy @list and return an identical new list.

doref
PgAttributeList doref()

Increase the reference count of the given attribute list by one.

filter
PgAttributeList filter(PangoAttrFilterFunc func, void* data)

Given a #PangoAttrList and callback function, removes any elements of @list for which @func returns %TRUE and inserts them into a new list.

getIterator
PgAttributeIterator getIterator()

Create a iterator initialized to the beginning of the list. @list must not be modified until this iterator is freed.

getPgAttributeListStruct
PangoAttrList* getPgAttributeListStruct(bool transferOwnership)

Get the main Gtk struct

getStruct
void* getStruct()

the main Gtk struct as a void*

insert
void insert(PgAttribute attr)

Insert the given attribute into the #PangoAttrList. It will be inserted after all other attributes with a matching @start_index.

insertBefore
void insertBefore(PgAttribute attr)

Insert the given attribute into the #PangoAttrList. It will be inserted before all other attributes with a matching @start_index.

splice
void splice(PgAttributeList other, int pos, int len)

This function opens up a hole in @list, fills it in with attributes from the left, and then merges @other on top of the hole.

unref
void unref()

Decrease the reference count of the given attribute list by one. If the result is zero, free the attribute list and the attributes it contains.

Static functions

getType
GType getType()

Variables

ownedRef
bool ownedRef;
Undocumented in source.
pangoAttrList
PangoAttrList* pangoAttrList;

the main Gtk struct

Meta