| 1 | /* Pango |
| 2 | * pango-tabs.h: Tab-related stuff |
| 3 | * |
| 4 | * Copyright (C) 2000 Red Hat Software |
| 5 | * |
| 6 | * This library is free software; you can redistribute it and/or |
| 7 | * modify it under the terms of the GNU Library General Public |
| 8 | * License as published by the Free Software Foundation; either |
| 9 | * version 2 of the License, or (at your option) any later version. |
| 10 | * |
| 11 | * This library is distributed in the hope that it will be useful, |
| 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 14 | * Library General Public License for more details. |
| 15 | * |
| 16 | * You should have received a copy of the GNU Library General Public |
| 17 | * License along with this library; if not, write to the |
| 18 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
| 19 | * Boston, MA 02111-1307, USA. |
| 20 | */ |
| 21 | |
| 22 | #ifndef __PANGO_TABS_H__ |
| 23 | #define __PANGO_TABS_H__ |
| 24 | |
| 25 | #include <pango/pango-types.h> |
| 26 | |
| 27 | G_BEGIN_DECLS |
| 28 | |
| 29 | typedef struct _PangoTabArray PangoTabArray; |
| 30 | |
| 31 | /** |
| 32 | * PangoTabAlign: |
| 33 | * @PANGO_TAB_LEFT: the tab stop appears to the left of the text. |
| 34 | * |
| 35 | * A #PangoTabAlign specifies where a tab stop appears relative to the text. |
| 36 | */ |
| 37 | typedef enum |
| 38 | { |
| 39 | PANGO_TAB_LEFT |
| 40 | |
| 41 | /* These are not supported now, but may be in the |
| 42 | * future. |
| 43 | * |
| 44 | * PANGO_TAB_RIGHT, |
| 45 | * PANGO_TAB_CENTER, |
| 46 | * PANGO_TAB_NUMERIC |
| 47 | */ |
| 48 | } PangoTabAlign; |
| 49 | |
| 50 | /** |
| 51 | * PANGO_TYPE_TAB_ARRAY: |
| 52 | * |
| 53 | * The #GObject type for #PangoTabArray. |
| 54 | */ |
| 55 | #define PANGO_TYPE_TAB_ARRAY (pango_tab_array_get_type ()) |
| 56 | |
| 57 | PANGO_AVAILABLE_IN_ALL |
| 58 | PangoTabArray *pango_tab_array_new (gint initial_size, |
| 59 | gboolean positions_in_pixels); |
| 60 | PANGO_AVAILABLE_IN_ALL |
| 61 | PangoTabArray *pango_tab_array_new_with_positions (gint size, |
| 62 | gboolean positions_in_pixels, |
| 63 | PangoTabAlign first_alignment, |
| 64 | gint first_position, |
| 65 | ...); |
| 66 | PANGO_AVAILABLE_IN_ALL |
| 67 | GType pango_tab_array_get_type (void) G_GNUC_CONST; |
| 68 | PANGO_AVAILABLE_IN_ALL |
| 69 | PangoTabArray *pango_tab_array_copy (PangoTabArray *src); |
| 70 | PANGO_AVAILABLE_IN_ALL |
| 71 | void pango_tab_array_free (PangoTabArray *tab_array); |
| 72 | PANGO_AVAILABLE_IN_ALL |
| 73 | gint pango_tab_array_get_size (PangoTabArray *tab_array); |
| 74 | PANGO_AVAILABLE_IN_ALL |
| 75 | void pango_tab_array_resize (PangoTabArray *tab_array, |
| 76 | gint new_size); |
| 77 | PANGO_AVAILABLE_IN_ALL |
| 78 | void pango_tab_array_set_tab (PangoTabArray *tab_array, |
| 79 | gint tab_index, |
| 80 | PangoTabAlign alignment, |
| 81 | gint location); |
| 82 | PANGO_AVAILABLE_IN_ALL |
| 83 | void pango_tab_array_get_tab (PangoTabArray *tab_array, |
| 84 | gint tab_index, |
| 85 | PangoTabAlign *alignment, |
| 86 | gint *location); |
| 87 | PANGO_AVAILABLE_IN_ALL |
| 88 | void pango_tab_array_get_tabs (PangoTabArray *tab_array, |
| 89 | PangoTabAlign **alignments, |
| 90 | gint **locations); |
| 91 | |
| 92 | PANGO_AVAILABLE_IN_ALL |
| 93 | gboolean pango_tab_array_get_positions_in_pixels (PangoTabArray *tab_array); |
| 94 | |
| 95 | |
| 96 | G_END_DECLS |
| 97 | |
| 98 | #endif /* __PANGO_TABS_H__ */ |
| 99 | |