~inkscape.dev/inkscape-devlibs/devlibs-gtk3

« back to all changes in this revision

Viewing changes to include/gtkmm-2.4/gtkmm/alignment.h

  • Committer: JazzyNico
  • Date: 2013-01-21 10:11:05 UTC
  • Revision ID: nicoduf@yahoo.fr-20130121101105-i8d8slkq9ng4olx8
Adding gtk2 libraries.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// -*- c++ -*-
 
2
// Generated by gtkmmproc -- DO NOT MODIFY!
 
3
#ifndef _GTKMM_ALIGNMENT_H
 
4
#define _GTKMM_ALIGNMENT_H
 
5
 
 
6
 
 
7
#include <glibmm.h>
 
8
 
 
9
/* $Id: alignment.hg,v 1.5 2004/04/29 19:58:02 murrayc Exp $ */
 
10
 
 
11
/* alignment.h
 
12
 * 
 
13
 * Copyright (C) 1998-2002 The gtkmm Development Team
 
14
 *
 
15
 * This library is free software; you can redistribute it and/or
 
16
 * modify it under the terms of the GNU Lesser General Public
 
17
 * License as published by the Free Software Foundation; either
 
18
 * version 2.1 of the License, or (at your option) any later version.
 
19
 *
 
20
 * This library is distributed in the hope that it will be useful,
 
21
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
22
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
23
 * Lesser General Public License for more details.
 
24
 *
 
25
 * You should have received a copy of the GNU Lesser General Public
 
26
 * License along with this library; if not, write to the Free
 
27
 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 
28
 */
 
29
 
 
30
#include <gtkmm/bin.h>
 
31
 
 
32
 
 
33
#ifndef DOXYGEN_SHOULD_SKIP_THIS
 
34
typedef struct _GtkAlignment GtkAlignment;
 
35
typedef struct _GtkAlignmentClass GtkAlignmentClass;
 
36
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
 
37
 
 
38
 
 
39
namespace Gtk
 
40
{ class Alignment_Class; } // namespace Gtk
 
41
namespace Gtk
 
42
{
 
43
 
 
44
/** A widget which controls the alignment and size of its child.
 
45
 *
 
46
 * Normally, a widget is allocated at least as much size as it requests, and,
 
47
 * most widgets expand to fill any extra allocated space, but sometimes
 
48
 * this behavior is not desired. The alignment widget allows the
 
49
 * programmer to specify how a widget should expand and position itself
 
50
 * to fill the area it is allocated.
 
51
 *
 
52
 * It has four settings: xscale, yscale, xalign, and yalign:
 
53
 * The scale settings specify how much the child widget should expand to fill the space allocated to the Gtk::Alignment. The values can range from 0 (meaning the child doesn't expand at all) to 1 (meaning the child expands to fill all of the available space).
 
54
 * The align settings place the child widget within the available area. The values range from 0 (top or left) to 1 (bottom or right). Of course, if the scale settings are both set to 1, the alignment settings have no effect.
 
55
 *
 
56
 * @ingroup Widgets
 
57
 * @ingroup Containers
 
58
 */
 
59
 
 
60
class Alignment : public Bin
 
61
{
 
62
  public:
 
63
#ifndef DOXYGEN_SHOULD_SKIP_THIS
 
64
  typedef Alignment CppObjectType;
 
65
  typedef Alignment_Class CppClassType;
 
66
  typedef GtkAlignment BaseObjectType;
 
67
  typedef GtkAlignmentClass BaseClassType;
 
68
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
 
69
 
 
70
  virtual ~Alignment();
 
71
 
 
72
#ifndef DOXYGEN_SHOULD_SKIP_THIS
 
73
 
 
74
private:
 
75
  friend class Alignment_Class;
 
76
  static CppClassType alignment_class_;
 
77
 
 
78
  // noncopyable
 
79
  Alignment(const Alignment&);
 
80
  Alignment& operator=(const Alignment&);
 
81
 
 
82
protected:
 
83
  explicit Alignment(const Glib::ConstructParams& construct_params);
 
84
  explicit Alignment(GtkAlignment* castitem);
 
85
 
 
86
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
 
87
 
 
88
public:
 
89
#ifndef DOXYGEN_SHOULD_SKIP_THIS
 
90
  static GType get_type()      G_GNUC_CONST;
 
91
 
 
92
 
 
93
  static GType get_base_type() G_GNUC_CONST;
 
94
#endif
 
95
 
 
96
  ///Provides access to the underlying C GtkObject.
 
97
  GtkAlignment*       gobj()       { return reinterpret_cast<GtkAlignment*>(gobject_); }
 
98
 
 
99
  ///Provides access to the underlying C GtkObject.
 
100
  const GtkAlignment* gobj() const { return reinterpret_cast<GtkAlignment*>(gobject_); }
 
101
 
 
102
 
 
103
public:
 
104
  //C++ methods used to invoke GTK+ virtual functions:
 
105
 
 
106
protected:
 
107
  //GTK+ Virtual Functions (override these to change behaviour):
 
108
 
 
109
  //Default Signal Handlers::
 
110
 
 
111
 
 
112
private:
 
113
 
 
114
public:
 
115
 
 
116
  /** Constructor to create an Alignment object.
 
117
   * @param xalign The initial horizontal alignment of the child.
 
118
   * @param yalign The initial vertical alignment of the child.
 
119
   * @param xscale The initial amount that the child expands horizontally to fill up unused space.
 
120
   * @param yscale The initial amount that the child expands vertically to fill up unused space.
 
121
   */
 
122
    explicit Alignment(float xalign =  0.5, float yalign =  0.5, float xscale =  1.0, float yscale =  1.0);
 
123
 
 
124
 
 
125
  /** Constructor to create an Alignment object.
 
126
   * @param xalign A Gtk::AlignmentEnum describing the initial horizontal alignment of the child.
 
127
   * @param yalign A Gtk::AlignmentEnum describing the initial vertical alignment of the child.
 
128
   * @param xscale The initial amount that the child expands horizontally to fill up unused space.
 
129
   * @param yscale The initial amount that the child expands vertically to fill up unused space.
 
130
   */
 
131
    explicit Alignment(AlignmentEnum xalign, AlignmentEnum yalign =  Gtk::ALIGN_CENTER, float xscale =  1.0, float yscale =  1.0);
 
132
 
 
133
 
 
134
  /** Sets the Alignment values.
 
135
   * @param xalign The horizontal alignment of the child of this Alignment, from 0 (left) to 1 (right).
 
136
   * @param yalign The vertical alignment of the child of this Alignment, from 0 (top) to 1 (bottom).
 
137
   * @param xscale The amount that the child expands horizontally to fill up unused space, from 0 to 1.  A value of 0 indicates that the child widget should never expand.  A value of 1 indicates that the child widget will expand to fill all the space allocated for the Alignment.
 
138
   * @param yscale The amount that the child widget expands vertically to fill up unused space from 0 to 1.  The values are similar to @a xscale.
 
139
   */
 
140
  void set(float xalign =  0.5, float yalign =  0.5, float xscale =  1.0, float yscale =  1.0);
 
141
  
 
142
  /** Sets the Alignment values.
 
143
   * @param xalign The horizontal alignment of the child of this Alignment, from 0 (left) to 1 (right).
 
144
   * @param yalign The vertical alignment of the child of this Alignment, from 0 (top) to 1 (bottom).
 
145
   * @param xscale The amount that the child expands horizontally to fill up unused space, from 0 to 1.  A value of 0 indicates that the child widget should never expand.  A value of 1 indicates that the child widget will expand to fill all the space allocated for the Alignment.
 
146
   * @param yscale The amount that the child widget expands vertically to fill up unused space from 0 to 1.  The values are similar to @a xscale.
 
147
   */
 
148
  void set(AlignmentEnum xalign, AlignmentEnum yalign =  Gtk::ALIGN_CENTER, float xscale =  1.0, float yscale =  1.0);
 
149
 
 
150
  //New in GTK+ 2.4
 
151
  
 
152
  /** Sets the padding on the different sides of the widget.
 
153
   * The padding adds blank space to the sides of the widget. For instance,
 
154
   * this can be used to indent the child widget towards the right by adding
 
155
   * padding on the left.
 
156
   * 
 
157
   * @newin{2,4}
 
158
   * @param padding_top The padding at the top of the widget.
 
159
   * @param padding_bottom The padding at the bottom of the widget.
 
160
   * @param padding_left The padding at the left of the widget.
 
161
   * @param padding_right The padding at the right of the widget.
 
162
   */
 
163
  void set_padding(guint padding_top, guint padding_bottom, guint padding_left, guint padding_right);
 
164
  
 
165
  /** Gets the padding on the different sides of the widget.
 
166
   * See set_padding().
 
167
   * 
 
168
   * @newin{2,4}
 
169
   * @param padding_top Location to store the padding for the top of the widget, or <tt>0</tt>.
 
170
   * @param padding_bottom Location to store the padding for the bottom of the widget, or <tt>0</tt>.
 
171
   * @param padding_left Location to store the padding for the left of the widget, or <tt>0</tt>.
 
172
   * @param padding_right Location to store the padding for the right of the widget, or <tt>0</tt>.
 
173
   */
 
174
  void get_padding(guint& padding_top, guint& padding_bottom, guint& padding_left, guint& padding_right);
 
175
              
 
176
  #ifdef GLIBMM_PROPERTIES_ENABLED
 
177
/** Horizontal position of child in available space. 0.0 is left aligned, 1.0 is right aligned.
 
178
   *
 
179
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
180
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
181
   * the value of the property changes.
 
182
   */
 
183
  Glib::PropertyProxy<float> property_xalign() ;
 
184
#endif //#GLIBMM_PROPERTIES_ENABLED
 
185
 
 
186
#ifdef GLIBMM_PROPERTIES_ENABLED
 
187
/** Horizontal position of child in available space. 0.0 is left aligned, 1.0 is right aligned.
 
188
   *
 
189
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
190
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
191
   * the value of the property changes.
 
192
   */
 
193
  Glib::PropertyProxy_ReadOnly<float> property_xalign() const;
 
194
#endif //#GLIBMM_PROPERTIES_ENABLED
 
195
 
 
196
  #ifdef GLIBMM_PROPERTIES_ENABLED
 
197
/** Vertical position of child in available space. 0.0 is top aligned, 1.0 is bottom aligned.
 
198
   *
 
199
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
200
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
201
   * the value of the property changes.
 
202
   */
 
203
  Glib::PropertyProxy<float> property_yalign() ;
 
204
#endif //#GLIBMM_PROPERTIES_ENABLED
 
205
 
 
206
#ifdef GLIBMM_PROPERTIES_ENABLED
 
207
/** Vertical position of child in available space. 0.0 is top aligned, 1.0 is bottom aligned.
 
208
   *
 
209
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
210
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
211
   * the value of the property changes.
 
212
   */
 
213
  Glib::PropertyProxy_ReadOnly<float> property_yalign() const;
 
214
#endif //#GLIBMM_PROPERTIES_ENABLED
 
215
 
 
216
  #ifdef GLIBMM_PROPERTIES_ENABLED
 
217
/** If available horizontal space is bigger than needed for the child, how much of it to use for the child. 0.0 means none, 1.0 means all.
 
218
   *
 
219
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
220
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
221
   * the value of the property changes.
 
222
   */
 
223
  Glib::PropertyProxy<float> property_xscale() ;
 
224
#endif //#GLIBMM_PROPERTIES_ENABLED
 
225
 
 
226
#ifdef GLIBMM_PROPERTIES_ENABLED
 
227
/** If available horizontal space is bigger than needed for the child, how much of it to use for the child. 0.0 means none, 1.0 means all.
 
228
   *
 
229
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
230
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
231
   * the value of the property changes.
 
232
   */
 
233
  Glib::PropertyProxy_ReadOnly<float> property_xscale() const;
 
234
#endif //#GLIBMM_PROPERTIES_ENABLED
 
235
 
 
236
  #ifdef GLIBMM_PROPERTIES_ENABLED
 
237
/** If available vertical space is bigger than needed for the child, how much of it to use for the child. 0.0 means none, 1.0 means all.
 
238
   *
 
239
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
240
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
241
   * the value of the property changes.
 
242
   */
 
243
  Glib::PropertyProxy<float> property_yscale() ;
 
244
#endif //#GLIBMM_PROPERTIES_ENABLED
 
245
 
 
246
#ifdef GLIBMM_PROPERTIES_ENABLED
 
247
/** If available vertical space is bigger than needed for the child, how much of it to use for the child. 0.0 means none, 1.0 means all.
 
248
   *
 
249
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
250
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
251
   * the value of the property changes.
 
252
   */
 
253
  Glib::PropertyProxy_ReadOnly<float> property_yscale() const;
 
254
#endif //#GLIBMM_PROPERTIES_ENABLED
 
255
 
 
256
 
 
257
  //New in GTK+ 2.4
 
258
  #ifdef GLIBMM_PROPERTIES_ENABLED
 
259
/** The padding to insert at the top of the widget.
 
260
   *
 
261
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
262
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
263
   * the value of the property changes.
 
264
   */
 
265
  Glib::PropertyProxy<guint> property_top_padding() ;
 
266
#endif //#GLIBMM_PROPERTIES_ENABLED
 
267
 
 
268
#ifdef GLIBMM_PROPERTIES_ENABLED
 
269
/** The padding to insert at the top of the widget.
 
270
   *
 
271
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
272
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
273
   * the value of the property changes.
 
274
   */
 
275
  Glib::PropertyProxy_ReadOnly<guint> property_top_padding() const;
 
276
#endif //#GLIBMM_PROPERTIES_ENABLED
 
277
 
 
278
  #ifdef GLIBMM_PROPERTIES_ENABLED
 
279
/** The padding to insert at the bottom of the widget.
 
280
   *
 
281
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
282
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
283
   * the value of the property changes.
 
284
   */
 
285
  Glib::PropertyProxy<guint> property_bottom_padding() ;
 
286
#endif //#GLIBMM_PROPERTIES_ENABLED
 
287
 
 
288
#ifdef GLIBMM_PROPERTIES_ENABLED
 
289
/** The padding to insert at the bottom of the widget.
 
290
   *
 
291
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
292
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
293
   * the value of the property changes.
 
294
   */
 
295
  Glib::PropertyProxy_ReadOnly<guint> property_bottom_padding() const;
 
296
#endif //#GLIBMM_PROPERTIES_ENABLED
 
297
 
 
298
  #ifdef GLIBMM_PROPERTIES_ENABLED
 
299
/** The padding to insert at the left of the widget.
 
300
   *
 
301
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
302
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
303
   * the value of the property changes.
 
304
   */
 
305
  Glib::PropertyProxy<guint> property_left_padding() ;
 
306
#endif //#GLIBMM_PROPERTIES_ENABLED
 
307
 
 
308
#ifdef GLIBMM_PROPERTIES_ENABLED
 
309
/** The padding to insert at the left of the widget.
 
310
   *
 
311
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
312
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
313
   * the value of the property changes.
 
314
   */
 
315
  Glib::PropertyProxy_ReadOnly<guint> property_left_padding() const;
 
316
#endif //#GLIBMM_PROPERTIES_ENABLED
 
317
 
 
318
  #ifdef GLIBMM_PROPERTIES_ENABLED
 
319
/** The padding to insert at the right of the widget.
 
320
   *
 
321
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
322
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
323
   * the value of the property changes.
 
324
   */
 
325
  Glib::PropertyProxy<guint> property_right_padding() ;
 
326
#endif //#GLIBMM_PROPERTIES_ENABLED
 
327
 
 
328
#ifdef GLIBMM_PROPERTIES_ENABLED
 
329
/** The padding to insert at the right of the widget.
 
330
   *
 
331
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
 
332
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
 
333
   * the value of the property changes.
 
334
   */
 
335
  Glib::PropertyProxy_ReadOnly<guint> property_right_padding() const;
 
336
#endif //#GLIBMM_PROPERTIES_ENABLED
 
337
 
 
338
 
 
339
};
 
340
 
 
341
} /* namespace Gtk */
 
342
 
 
343
 
 
344
namespace Glib
 
345
{
 
346
  /** A Glib::wrap() method for this object.
 
347
   * 
 
348
   * @param object The C instance.
 
349
   * @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
 
350
   * @result A C++ instance that wraps this C instance.
 
351
   *
 
352
   * @relates Gtk::Alignment
 
353
   */
 
354
  Gtk::Alignment* wrap(GtkAlignment* object, bool take_copy = false);
 
355
} //namespace Glib
 
356
 
 
357
 
 
358
#endif /* _GTKMM_ALIGNMENT_H */
 
359