pango.TabArray
pango.TabArray — an object containing an array of tab stops.
Description
A pango.TabArray
object contains an array of tab stops. Each tab stop has an alignment and a
position.
Constructor
|     pango.TabArray(initial_size, positions_in_pixels)
 | 
| initial_size : | Initial number of tab stops to allocate, can be
0 | 
| positions_in_pixels : | if TRUE the tab positions are
in pixel units | 
| Returns : | a pango.TabArray | 
Creates a new pango.TabArray
object with the number of tab stops specified by
initial_size. If
positions_in_pixels is TRUE, the
tab stop positions are specified in pixel units otherwise in pango units
(one pixel = pango.SCALE pango units). All tab stops are
initially at position 0.
Methods
pango.TabArray.get_size
| Returns : | the number of tab stops in the
array. | 
The get_size() method returns the
number of tab stops in the tab array.
pango.TabArray.resize
| new_size : | the new size of the array | 
The resize() method sets the size of
the tab array to the value specified by new_size. You
must subsequently initialize any tabs that were added to the array.
pango.TabArray.set_tab
|     def set_tab(tab_index, alignment, location)
 | 
| tab_index : | the index of a tab stop | 
| alignment : | the tab alignment | 
| location : | the tab location in pango
units | 
The set_tab() method sets the specified
alignment and location of the
tab stop specified by tab_index. The value of
alignment must always be
pango.TAB_LEFT in the current implementation.
pango.TabArray.get_tab
| tab_index : | the tab stop index | 
| Returns : | a 2-tuple containing the tab alignment and
position | 
The get_tab() method returns a 2-tuple
containing the alignment and position of the tab stop specified by
tab_index.
pango.TabArray.get_tabs
| Returns : | a tuple containing a list of 2-tuples (each
holding the alignment and position of a tab stop). | 
The get_tabs() method returns a tuple
containing a list of 2-tuples (each holding the alignment and position of a
tab stop)
pango.TabArray.get_positions_in_pixels
|     def get_positions_in_pixels()
 | 
| Returns : | TRUE if tab stop positions
are specified in pixels | 
The get_positions_in_pixels() method
returns TRUE if the tab positions are specified in
pixels and FALSE if they are in pango units.