Pango.TabArray¶
Fields¶
None
Methods¶
| class | new(initial_size, positions_in_pixels) | 
| copy() | |
| free() | |
| get_positions_in_pixels() | |
| get_size() | |
| get_tab(tab_index) | |
| get_tabs() | |
| resize(new_size) | |
| set_tab(tab_index, alignment, location) | 
Details¶
- 
class Pango.TabArray¶
- A - Pango.TabArraystruct contains an array of tab stops. Each tab stop has an alignment and a position.- 
classmethod new(initial_size, positions_in_pixels)[source]¶
- Parameters: - Returns: - the newly allocated - Pango.TabArray, which should be freed with- Pango.TabArray.free().- Return type: - Creates an array of initial_size tab stops. Tab stops are specified in pixel units if positions_in_pixels is - True, otherwise in Pango units. All stops are initially at position 0.
 - 
copy()[source]¶
- Returns: - the newly allocated - Pango.TabArray, which should be freed with- Pango.TabArray.free().- Return type: - Pango.TabArray- Copies a - Pango.TabArray
 - 
get_positions_in_pixels()[source]¶
- Returns: - whether positions are in pixels. - Return type: - bool- Returns - Trueif the tab positions are in pixels,- Falseif they are in Pango units.
 - 
get_size()[source]¶
- Returns: - the number of tab stops in the array. - Return type: - int- Gets the number of tab stops in self. 
 - 
get_tab(tab_index)[source]¶
- Parameters: - tab_index ( - int) – tab stop index- Returns: - alignment: - location to store alignment, or - None- location: - location to store tab position, or - None- Return type: - (alignment: - Pango.TabAlign, location:- int)- Gets the alignment and position of a tab stop. 
 - 
get_tabs()[source]¶
- Returns: - alignments: - location to store an array of tab stop alignments, or - None- locations: - location to store an array of tab positions, or - None- Return type: - (alignments: - Pango.TabAlign, locations: [- int])- If non- - None, alignments and locations are filled with allocated arrays of length- Pango.TabArray.get_size(). You must free the returned array.
 - 
resize(new_size)[source]¶
- Parameters: - new_size ( - int) – new size of the array- Resizes a tab array. You must subsequently initialize any tabs that were added as a result of growing the array. 
 - 
set_tab(tab_index, alignment, location)[source]¶
- Parameters: - tab_index (int) – the index of a tab stop
- alignment (Pango.TabAlign) – tab alignment
- location (int) – tab location in Pango units
 - Sets the alignment and location of a tab stop. alignment must always be - Pango.TabAlign.LEFTin the current implementation.
- tab_index (
 
- 
classmethod