pango.AttrIterator
pango.AttrIterator — an object pointing to a location in a pango.AttrList.
Methods
pango.AttrIterator.copy
The copy() method returns a new pango.AttrIterator
object that is a copy of this attribute iterator.
pango.AttrIterator.range
Returns : | a 2-tuple containing the start and end index of
the current attribute in the text. |
The range() method returns a 2-tuple
containing the start and end index of the application of the current
attribute change in the text.
pango.AttrIterator.next
The next() method advances the iterator
to the next attribute change in its pango.AttrList.
The next method returns FALSE if
the iterator is at the end of the pango.AttrList;
otherwise, TRUE.
pango.AttrIterator.get
The get() method returns the pango.Attribute
at the iterator location that matches the specified
type. When multiple attributes of the same type
overlap, the attribute whose range starts closest to the current location is
returned. If no attribute matches, None is
returned.
pango.AttrIterator.get_font
The get_font() method returns a 3-tuple
containing a pango.FontDescription
holding the current font attributes, a pango.Language
object (if a language is set) or None and a list of
non-font pango.Attribute
objects in effect at the current iterator location.
pango.AttrIterator.get_attrs
Returns : | a tuple containing the pango.Attribute
objects in effect at the current iterator
location. |
Note
This method is available in PyGTK 2.4 and above.
The get_attrs() method returns a tuple
containing the pango.Attribute
objects in effect at the current iterator location.