Main Page Widgets Namespaces Book

# Pango::TabArray Class Reference

A Pango::TabArray contains an array of tab stops. More...

List of all members.

## Public Methods

| TabArray ()
| TabArray (PangoTabArray* castitem, bool make_a_copy=true)
| TabArray (const TabArray& src)
TabArray& | operator= (const TabArray& src)
| ~TabArray ()
PangoTabArray* | gobj ()
const PangoTabArray* | gobj () const
PangoTabArray* | gobj_copy () const
| TabArray (int initial_size, bool positions_in_pixels=true)
int | get_size () const
| Get the number of tab stops in tab_array.
void | resize (int new_size)
| Resizes a tab array.
void | set_tab (int tab_index, TabAlign alignment, int location)
| Sets the alignment and location of a tab stop.
std::pair<TabAlign, int> | get_tab (int tab_index) const
| Gets the alignment and position of a tab stop.
Glib::ArrayHandle< std::pair< TabAlign, int > > | get_tabs () const
| Gets an array of std::pairs containing the tab stop alignments and tab positions.
bool | get_positions_in_pixels () const
| Returns TRUE if the tab positions are in pixels, FALSE if they are in Pango units.

## Protected Attributes

PangoTabArray* | gobject_

## Related Functions

(Note that these are not member functions.)
Pango::TabArray | wrap (PangoTabArray* object, bool take_copy=false)

## Detailed Description

A Pango::TabArray contains an array of tab stops.

Each tab stop has an alignment and a position.

## Constructor & Destructor Documentation

Pango::TabArray::TabArray | ( |  | ) |

Pango::TabArray::TabArray | ( | PangoTabArray* | castitem,
|  | bool | make_a_copy = true
| ) | `[explicit]`

Pango::TabArray::TabArray | ( | const TabArray& | src | ) |

Pango::TabArray::~TabArray | ( |  | ) |

Pango::TabArray::TabArray | ( | int | initial_size,
|  | bool | positions_in_pixels = true
| ) | `[explicit]`

## Member Function Documentation

bool Pango::TabArray::get_positions_in_pixels | ( |  | ) |

Returns TRUE if the tab positions are in pixels, FALSE if they are in Pango units.

Returns:
  Whether positions are in pixels.

int Pango::TabArray::get_size | ( |  | ) |

Get the number of tab stops in tab_array.

Returns:
  The number of tab stops in the array.

std::pair<TabAlign,int> Pango::TabArray::get_tab | ( | int | tab_index | ) | const

Gets the alignment and position of a tab stop.

Returns:
  An std::pair<TabAlign, int>. The first element represents the tab stop alignment, the second one is the tab position.

Glib::ArrayHandle<std::pair<TabAlign,int>> Pango::TabArray::get_tabs | ( |  | ) |

Gets an array of std::pairs containing the tab stop alignments and tab positions.

Returns:
  An array of std::pair<TabAlign, int>. The first element in each pair represents the tab stop alignment, the second one is the tab position.

const PangoTabArray* Pango::TabArray::gobj | ( |  | ) | const`[inline]`

PangoTabArray* Pango::TabArray::gobj | ( |  | ) | `[inline]`

PangoTabArray* Pango::TabArray::gobj_copy | ( |  | ) |

TabArray& Pango::TabArray::operator= | ( | const TabArray& | src | ) |

void Pango::TabArray::resize | ( | int | new_size | ) |

Resizes a tab array.

You must subsequently initialize any tabs that were added as a result of growing the array.

Parameters:

  new_size | New size of the array.

void Pango::TabArray::set_tab | ( | int | tab_index,
|  | TabAlign | alignment,
|  | int | location
| ) |

Sets the alignment and location of a tab stop.

alignment must always be Pango::TAB_LEFT in the current implementation.

Parameters:

  tab_index | The index of a tab stop.
  alignment | Tab alignment.
  location | Tab location in pango units.

## Friends And Related Function Documentation

Pango::TabArray wrap | ( | PangoTabArray* | object,
|  | bool | take_copy = false
| ) | `[related]`

## Member Data Documentation

PangoTabArray* Pango::TabArray::gobject_`[protected]`

The documentation for this class was generated from the following file:

- tabarray.h