gtklayout.h 4.01 KB
Newer Older
Cody Russell's avatar
Cody Russell committed
1
/* GTK - The GIMP Toolkit
2
 * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
3
 *
4
 * This library is free software; you can redistribute it and/or
5
 * modify it under the terms of the GNU Lesser General Public
6 7 8 9 10 11
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the GNU
12
 * Lesser General Public License for more details.
13
 *
14
 * You should have received a copy of the GNU Lesser General Public
15 16 17 18 19 20 21
 * License along with this library; if not, write to the
 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
 * Boston, MA 02111-1307, USA.
 *
 * GtkLayout: Widget for scrolling of arbitrary-sized areas.
 *
 * Copyright Owen Taylor, 1998
22 23
 */

24
/*
25
 * Modified by the GTK+ Team and others 1997-2000.  See the AUTHORS
26 27
 * file for a list of people on the GTK+ Team.  See the ChangeLog
 * files for a list of changes.  These files are distributed with
28
 * GTK+ at ftp://ftp.gtk.org/pub/gtk/.
29 30
 */

31
#if !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
32 33 34
#error "Only <gtk/gtk.h> can be included directly."
#endif

35 36
#ifndef __GTK_LAYOUT_H__
#define __GTK_LAYOUT_H__
37

38

39 40 41
#include <gtk/gtkcontainer.h>
#include <gtk/gtkadjustment.h>

42

43
G_BEGIN_DECLS
Tim Janik's avatar
Tim Janik committed
44

45
#define GTK_TYPE_LAYOUT            (gtk_layout_get_type ())
Manish Singh's avatar
Manish Singh committed
46 47 48 49 50
#define GTK_LAYOUT(obj)            (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_LAYOUT, GtkLayout))
#define GTK_LAYOUT_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_LAYOUT, GtkLayoutClass))
#define GTK_IS_LAYOUT(obj)         (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_LAYOUT))
#define GTK_IS_LAYOUT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_LAYOUT))
#define GTK_LAYOUT_GET_CLASS(obj)  (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_LAYOUT, GtkLayoutClass))
Tim Janik's avatar
Tim Janik committed
51

52

53 54 55
typedef struct _GtkLayout              GtkLayout;
typedef struct _GtkLayoutPrivate       GtkLayoutPrivate;
typedef struct _GtkLayoutClass         GtkLayoutClass;
56

57 58
struct _GtkLayout
{
59
  GtkContainer container;
60

61
  /*< private >*/
62
  GtkLayoutPrivate *priv;
63 64
};

65 66
struct _GtkLayoutClass
{
67 68
  GtkContainerClass parent_class;

69 70 71 72 73
  /* Padding for future expansion */
  void (*_gtk_reserved1) (void);
  void (*_gtk_reserved2) (void);
  void (*_gtk_reserved3) (void);
  void (*_gtk_reserved4) (void);
74 75
};

Manish Singh's avatar
Manish Singh committed
76
GType          gtk_layout_get_type        (void) G_GNUC_CONST;
77 78
GtkWidget*     gtk_layout_new             (GtkAdjustment *hadjustment,
				           GtkAdjustment *vadjustment);
Tim Janik's avatar
Tim Janik committed
79
GdkWindow*     gtk_layout_get_bin_window  (GtkLayout     *layout);
80 81 82
void           gtk_layout_put             (GtkLayout     *layout,
		                           GtkWidget     *child_widget,
		                           gint           x,
83
		                           gint           y);
84 85 86 87

void           gtk_layout_move            (GtkLayout     *layout,
		                           GtkWidget     *child_widget,
		                           gint           x,
88
		                           gint           y);
89 90

void           gtk_layout_set_size        (GtkLayout     *layout,
91 92
			                   guint          width,
			                   guint          height);
93 94 95
void           gtk_layout_get_size        (GtkLayout     *layout,
					   guint         *width,
					   guint         *height);
96

97
GDK_DEPRECATED_FOR(gtk_scrollable_get_hadjustment)
98
GtkAdjustment* gtk_layout_get_hadjustment (GtkLayout     *layout);
99
GDK_DEPRECATED_FOR(gtk_scrollable_get_vadjustment)
100
GtkAdjustment* gtk_layout_get_vadjustment (GtkLayout     *layout);
101
GDK_DEPRECATED_FOR(gtk_scrollable_set_hadjustment)
102
void           gtk_layout_set_hadjustment (GtkLayout     *layout,
103 104
                                           GtkAdjustment *adjustment);
GDK_DEPRECATED_FOR(gtk_scrollable_set_vadjustment)
105
void           gtk_layout_set_vadjustment (GtkLayout     *layout,
106
                                           GtkAdjustment *adjustment);
107

108

109
G_END_DECLS
110

111
#endif /* __GTK_LAYOUT_H__ */