org.gnu.pango
Class AttrList
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.
AttrList
public AttrList()
Construct a new AttrList.
AttrList
public AttrList(Handle handle)
AttrList
public AttrList(AttrList list)
Create a new AttrList that is a copyof the provided list.
change
public void change(Attribute attr)
Insert the given attribute into the list. It will replace any attribute
of the same type on that segment and be merged with any adjoining
attributes that are identical.
getAttrListFromHandle
public static AttrList getAttrListFromHandle(Handle handle)
Static factory method that should only be used interally by Java-Gnome.
getIterator
public AttrIterator getIterator()
Create an iterator pointing at the beginning of the list.
insert
public void insert(Attribute attr)
Insert the given attribute into the list. It will be inserted after all
other attributes with a matching start_index.
insertBefore
public void insertBefore(Attribute attr)
Insert the given attribute into the list. It will be inserted before all
other attributes with a matching start_index.
splice
public void splice(AttrList other,
int pos,
int len)
Splice on list into another.
other
- The other AttrList to splice in the current one.pos
- The position at which to insert.len
- The length of the spliced segment.