Reference Manual

Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

# tabs.h

Go to the documentation of this file.

    00001 /*  Inti: Integrated Foundation Classes
    00002  *  Copyright (C) 2002-2003 The Inti Development Team.
    00003  *
    00004  *  This program is free software; you can redistribute it and/or modify
    00005  *  it under the terms of the GNU General Public License as published by
    00006  *  the Free Software Foundation; either version 2 of the License, or
    00007  *  (at your option) any later version.
    00008  *
    00009  *  This program is distributed in the hope that it will be useful,
    00010  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
    00011  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    00012  *  GNU Library General Public License for more details.
    00013  *
    00014  *  You should have received a copy of the GNU Library General Public License
    00015  *  along with this program; if not, write to the Free Software
    00016  *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
    00017  */
    00018
    00023
    00024 #ifndef INTI_PANGO_TABS_H
    00025 #define INTI_PANGO_TABS_H
    00026
    00027 #ifndef INTI_G_BOXED_H
    00028 #include <inti/glib/boxed.h>
    00029 #endif
    00030
    00031 #ifndef __PANGO_TABS_H__
    00032 #include <pango/pango-tabs.h>
    00033 #endif
    00034
    00035 #ifndef _CPP_VECTOR
    00036 #include <vector>
    00037 #endif
    00038
    00039 namespace Inti {
    00040
    00041 namespace Pango {
    00042
    00047
    00048 enum TabAlign
    00049 {
    00050         TAB_LEFT = PANGO_TAB_LEFT
    00051 };
    00052
    00057
    00058 class TabArray : public G::Boxed
    00059 {
    00060 public:
    00063
    00064         TabArray(int initial_size, bool positions_in_pixels = true);
    00071
    00072         TabArray(int size, bool positions_in_pixels, int first_position, ...);
    00082
    00083         TabArray(int size, bool positions_in_pixels, TabAlign first_alignment, int first_position, ...);
    00093
    00094         TabArray(const std::vector<std::pair<TabAlign , int> >& tabs, bool positions_in_pixels = true);
    00100
    00101         explicit TabArray(PangoTabArray *tab_array);
    00109
    00110         TabArray(PangoTabArray *tab_array, bool copy);
    00121
    00122         TabArray(const TabArray& src);
    00125
    00126         virtual ~TabArray();
    00128
    00129         TabArray& operator=(const TabArray& src);
    00132
    00136
    00137         PangoTabArray* pango_tab_array() const { return (PangoTabArray*)boxed_; }
    00139
    00140         operator PangoTabArray* () const;
    00142
    00143         int get_size() const;
    00146
    00147         int get_tab(int tab_index, TabAlign *alignment = 0) const;
    00154
    00155         std::vector<std::pair<TabAlign, int> > get_tabs() const;
    00161
    00162         bool get_positions_in_pixels() const;
    00165
    00169
    00170         void resize(int new_size);
    00176
    00177         void set_tab(int tab_index, int location, TabAlign alignment = TAB_LEFT);
    00184
    00186 };
    00187
    00188 } // namespace Pango
    00189
    00190 } // namespace Inti
    00191
    00192 #endif // INTI_PANGO_TABS_H
    00193
    00194

Main Page - Footer