1 /* GTK - The GIMP Toolkit
2 * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
5 * Copyright (C) 1998 Shawn T. Amundson, James S. Mitchell, Michael L. Staiger
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version.
12 * This library is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 * Library General Public License for more details.
17 * You should have received a copy of the GNU Library General Public
18 * License along with this library; if not, write to the
19 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20 * Boston, MA 02111-1307, USA.
24 * Modified by the GTK+ Team and others 1997-1999. See the AUTHORS
25 * file for a list of people on the GTK+ Team. See the ChangeLog
26 * files for a list of changes. These files are distributed with
27 * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
30 #ifndef __GTK_PACKER_H__
31 #define __GTK_PACKER_H__
33 #include <gtk/gtkcontainer.h>
37 #endif /* __cplusplus */
40 #define GTK_TYPE_PACKER (gtk_packer_get_type ())
41 #define GTK_PACKER(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_PACKER, GtkPacker))
42 #define GTK_PACKER_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_PACKER, GtkPackerClass))
43 #define GTK_IS_PACKER(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_PACKER))
44 #define GTK_IS_PACKER_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GTK_TYPE_PACKER))
48 typedef struct _GtkPacker GtkPacker;
49 typedef struct _GtkPackerClass GtkPackerClass;
50 typedef struct _GtkPackerChild GtkPackerChild;
54 GTK_PACK_EXPAND = 1 << 0, /*< nick=expand >*/
71 GTK_ANCHOR_NORTH_WEST,
72 GTK_ANCHOR_NORTH_EAST,
74 GTK_ANCHOR_SOUTH_WEST,
75 GTK_ANCHOR_SOUTH_EAST,
78 GTK_ANCHOR_N = GTK_ANCHOR_NORTH,
79 GTK_ANCHOR_NW = GTK_ANCHOR_NORTH_WEST,
80 GTK_ANCHOR_NE = GTK_ANCHOR_NORTH_EAST,
81 GTK_ANCHOR_S = GTK_ANCHOR_SOUTH,
82 GTK_ANCHOR_SW = GTK_ANCHOR_SOUTH_WEST,
83 GTK_ANCHOR_SE = GTK_ANCHOR_SOUTH_EAST,
84 GTK_ANCHOR_W = GTK_ANCHOR_WEST,
85 GTK_ANCHOR_E = GTK_ANCHOR_EAST
88 struct _GtkPackerChild
94 GtkPackerOptions options;
96 guint use_default : 1;
98 guint border_width : 16;
113 guint default_border_width : 16;
114 guint default_pad_x : 16;
115 guint default_pad_y : 16;
116 guint default_i_pad_x : 16;
117 guint default_i_pad_y : 16;
120 struct _GtkPackerClass
122 GtkContainerClass parent_class;
126 GtkType gtk_packer_get_type (void);
127 GtkWidget* gtk_packer_new (void);
128 void gtk_packer_add_defaults (GtkPacker *packer,
131 GtkAnchorType anchor,
132 GtkPackerOptions options);
133 void gtk_packer_add (GtkPacker *packer,
136 GtkAnchorType anchor,
137 GtkPackerOptions options,
143 void gtk_packer_set_child_packing (GtkPacker *packer,
146 GtkAnchorType anchor,
147 GtkPackerOptions options,
153 void gtk_packer_reorder_child (GtkPacker *packer,
156 void gtk_packer_set_spacing (GtkPacker *packer,
158 void gtk_packer_set_default_border_width (GtkPacker *packer,
160 void gtk_packer_set_default_pad (GtkPacker *packer,
163 void gtk_packer_set_default_ipad (GtkPacker *packer,
170 #endif /* __cplusplus */
173 #endif /* __GTK_PACKER_H__ */