Install ardour as a binary, a script and a set of shared
[ardour.git] / libs / gtkmm2 / gtk / gtkmm / misc.cc
1 // Generated by gtkmmproc -- DO NOT MODIFY!
2
3 #include <gtkmm/misc.h>
4 #include <gtkmm/private/misc_p.h>
5
6 // -*- c++ -*-
7 /* $Id$ */
8
9 /* 
10  *
11  * Copyright 1998-2002 The gtkmm Development Team
12  *
13  * This library is free software; you can redistribute it and/or
14  * modify it under the terms of the GNU Library General Public
15  * License as published by the Free Software Foundation; either
16  * version 2 of the License, or (at your option) any later version.
17  *
18  * This library is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
21  * Library General Public License for more details.
22  *
23  * You should have received a copy of the GNU Library General Public
24  * License along with this library; if not, write to the Free
25  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
26  */
27
28 #include <gtk/gtkmisc.h>
29
30 namespace Gtk
31 {
32
33 } //namespace Gtk
34
35
36 namespace
37 {
38 } // anonymous namespace
39
40
41 namespace Glib
42 {
43
44 Gtk::Misc* wrap(GtkMisc* object, bool take_copy)
45 {
46   return dynamic_cast<Gtk::Misc *> (Glib::wrap_auto ((GObject*)(object), take_copy));
47 }
48
49 } /* namespace Glib */
50
51 namespace Gtk
52 {
53
54
55 /* The *_Class implementation: */
56
57 const Glib::Class& Misc_Class::init()
58 {
59   if(!gtype_) // create the GType if necessary
60   {
61     // Glib::Class has to know the class init function to clone custom types.
62     class_init_func_ = &Misc_Class::class_init_function;
63
64     // This is actually just optimized away, apparently with no harm.
65     // Make sure that the parent type has been created.
66     //CppClassParent::CppObjectType::get_type();
67
68     // Create the wrapper type, with the same class/instance size as the base type.
69     register_derived_type(gtk_misc_get_type());
70
71     // Add derived versions of interfaces, if the C type implements any interfaces:
72   }
73
74   return *this;
75 }
76
77 void Misc_Class::class_init_function(void* g_class, void* class_data)
78 {
79   BaseClassType *const klass = static_cast<BaseClassType*>(g_class);
80   CppClassParent::class_init_function(klass, class_data);
81
82 }
83
84
85 Glib::ObjectBase* Misc_Class::wrap_new(GObject* o)
86 {
87   return manage(new Misc((GtkMisc*)(o)));
88
89 }
90
91
92 /* The implementation: */
93
94 Misc::Misc(const Glib::ConstructParams& construct_params)
95 :
96   Gtk::Widget(construct_params)
97 {
98   }
99
100 Misc::Misc(GtkMisc* castitem)
101 :
102   Gtk::Widget((GtkWidget*)(castitem))
103 {
104   }
105
106 Misc::~Misc()
107 {
108   destroy_();
109 }
110
111 Misc::CppClassType Misc::misc_class_; // initialize static member
112
113 GType Misc::get_type()
114 {
115   return misc_class_.init().get_type();
116 }
117
118 GType Misc::get_base_type()
119 {
120   return gtk_misc_get_type();
121 }
122
123
124 Misc::Misc()
125 :
126   Glib::ObjectBase(0), //Mark this class as gtkmmproc-generated, rather than a custom class, to allow vfunc optimisations.
127   Gtk::Widget(Glib::ConstructParams(misc_class_.init()))
128 {
129   }
130
131 void Misc::set_alignment(float xalign, float yalign)
132 {
133   gtk_misc_set_alignment(gobj(), xalign, yalign);
134 }
135
136 void Misc::set_alignment(AlignmentEnum xalign, AlignmentEnum yalign)
137 {
138   gtk_misc_set_alignment(gobj(), _gtkmm_align_float_from_enum(xalign), _gtkmm_align_float_from_enum(yalign));
139 }
140
141 void Misc::get_alignment(float& xalign, float& yalign) const
142 {
143   gtk_misc_get_alignment(const_cast<GtkMisc*>(gobj()), &(xalign), &(yalign));
144 }
145
146 void Misc::set_padding(int xpad, int ypad)
147 {
148   gtk_misc_set_padding(gobj(), xpad, ypad);
149 }
150
151 void Misc::get_padding(int& xpad, int& ypad) const
152 {
153   gtk_misc_get_padding(const_cast<GtkMisc*>(gobj()), &xpad, &ypad);
154 }
155
156
157 Glib::PropertyProxy<float> Misc::property_xalign() 
158 {
159   return Glib::PropertyProxy<float>(this, "xalign");
160 }
161
162 Glib::PropertyProxy_ReadOnly<float> Misc::property_xalign() const
163 {
164   return Glib::PropertyProxy_ReadOnly<float>(this, "xalign");
165 }
166
167 Glib::PropertyProxy<float> Misc::property_yalign() 
168 {
169   return Glib::PropertyProxy<float>(this, "yalign");
170 }
171
172 Glib::PropertyProxy_ReadOnly<float> Misc::property_yalign() const
173 {
174   return Glib::PropertyProxy_ReadOnly<float>(this, "yalign");
175 }
176
177 Glib::PropertyProxy<int> Misc::property_xpad() 
178 {
179   return Glib::PropertyProxy<int>(this, "xpad");
180 }
181
182 Glib::PropertyProxy_ReadOnly<int> Misc::property_xpad() const
183 {
184   return Glib::PropertyProxy_ReadOnly<int>(this, "xpad");
185 }
186
187 Glib::PropertyProxy<int> Misc::property_ypad() 
188 {
189   return Glib::PropertyProxy<int>(this, "ypad");
190 }
191
192 Glib::PropertyProxy_ReadOnly<int> Misc::property_ypad() const
193 {
194   return Glib::PropertyProxy_ReadOnly<int>(this, "ypad");
195 }
196
197
198 } // namespace Gtk
199
200