2
// Generated by gtkmmproc -- DO NOT MODIFY!
3
#ifndef _GTKMM_HANDLEBOX_H
4
#define _GTKMM_HANDLEBOX_H
9
/* $Id: handlebox.hg,v 1.1 2003/01/21 13:40:26 murrayc Exp $ */
13
* Copyright (C) 1998-2002 The gtkmm Development Team
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.
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.
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.
30
#include <gtkmm/eventbox.h>
33
#ifndef DOXYGEN_SHOULD_SKIP_THIS
34
typedef struct _GtkHandleBox GtkHandleBox;
35
typedef struct _GtkHandleBoxClass GtkHandleBoxClass;
36
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
40
{ class HandleBox_Class; } // namespace Gtk
44
/** A widget for detachable window portions.
46
* The Gtk::HandleBox widget allows a portion of a window to be "torn off".
47
* It displays its child and a handle that the user can drag to tear off a separate window (the float window) containing the child widget. A thin ghost is drawn in the original location of the handlebox. By dragging the separate window back to its original location, it can be reattached.
48
* When reattaching, the ghost and float window must be aligned along one of the edges, the snap edge. This can be specified by the application programmer explicitely, or GTK+ will pick a reasonable default based on the handle position.
49
* To make detaching and reattaching the handlebox as minimally confusing as possible to the user, it is important to set the snap edge so that the snap edge does not move when the handlebox is deattached.
50
* For instance, if the handlebox is packed at the bottom of a VBox, then when the handlebox is detached, the bottom edge of the handlebox's allocation will remain fixed as the height of the handlebox shrinks, so the snap edge should be set to GTK_POS_BOTTOM.
56
class HandleBox : public Bin
59
#ifndef DOXYGEN_SHOULD_SKIP_THIS
60
typedef HandleBox CppObjectType;
61
typedef HandleBox_Class CppClassType;
62
typedef GtkHandleBox BaseObjectType;
63
typedef GtkHandleBoxClass BaseClassType;
64
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
68
#ifndef DOXYGEN_SHOULD_SKIP_THIS
71
friend class HandleBox_Class;
72
static CppClassType handlebox_class_;
75
HandleBox(const HandleBox&);
76
HandleBox& operator=(const HandleBox&);
79
explicit HandleBox(const Glib::ConstructParams& construct_params);
80
explicit HandleBox(GtkHandleBox* castitem);
82
#endif /* DOXYGEN_SHOULD_SKIP_THIS */
85
#ifndef DOXYGEN_SHOULD_SKIP_THIS
86
static GType get_type() G_GNUC_CONST;
89
static GType get_base_type() G_GNUC_CONST;
92
///Provides access to the underlying C GtkObject.
93
GtkHandleBox* gobj() { return reinterpret_cast<GtkHandleBox*>(gobject_); }
95
///Provides access to the underlying C GtkObject.
96
const GtkHandleBox* gobj() const { return reinterpret_cast<GtkHandleBox*>(gobject_); }
100
//C++ methods used to invoke GTK+ virtual functions:
103
//GTK+ Virtual Functions (override these to change behaviour):
105
//Default Signal Handlers::
106
virtual void on_child_attached(Widget* child);
107
virtual void on_child_detached(Widget* child);
116
void set_shadow_type(ShadowType type);
118
/** Gets the type of shadow drawn around the handle box. See
120
* @return The type of shadow currently drawn around the handle box.
122
ShadowType get_shadow_type() const;
124
void set_handle_position(PositionType position);
126
/** Gets the handle position of the handle box. See
127
* set_handle_position().
128
* @return The current handle position.
130
PositionType get_handle_position() const;
132
void set_snap_edge(PositionType edge);
134
/** Gets the edge used for determining reattachment of the handle box. See
136
* @return The edge used for determining reattachment, or (GtkPositionType)-1 if this
137
* is determined (as per default) from the handle position.
139
PositionType get_snap_edge() const;
142
/** Whether the handlebox's child is currently detached.
145
* @return <tt>true</tt> if the child is currently detached, otherwise <tt>false</tt>.
147
bool is_child_detached() const;
152
* <tt>void on_my_%child_attached(Widget* child)</tt>
155
Glib::SignalProxy1< void,Widget* > signal_child_attached();
160
* <tt>void on_my_%child_detached(Widget* child)</tt>
163
Glib::SignalProxy1< void,Widget* > signal_child_detached();
166
#ifndef GTKMM_DISABLE_DEPRECATED
168
/** @deprecated You should not need to call this method.
170
Glib::RefPtr<Gdk::Window> get_bin_window();
171
Glib::RefPtr<const Gdk::Window> get_bin_window() const;
173
/** @deprecated You should not need to call this method.
175
Glib::RefPtr<Gdk::Window> get_float_window();
176
Glib::RefPtr<const Gdk::Window> get_float_window() const;
178
/** @deprecated This method does not seem to be useful and will be removed from a future version of gtkmm, due to changes in GTK+.
180
bool is_float_window_mapped() const;
182
/** @deprecated This method does not seem to be useful and will be removed from a future version of gtkmm, due to changes in GTK+.
184
bool is_in_drag() const;
186
/** @deprecated This method does not seem to be useful and will be removed from a future version of gtkmm, due to changes in GTK+.
188
bool shrinks_on_detach() const;
189
#endif // GTKMM_DISABLE_DEPRECATED
192
//_WRAP_PROPERTY("shadow", ShadowType); //deprecated.
193
#ifdef GLIBMM_PROPERTIES_ENABLED
194
/** Appearance of the shadow that surrounds the container.
196
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
197
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
198
* the value of the property changes.
200
Glib::PropertyProxy<ShadowType> property_shadow_type() ;
201
#endif //#GLIBMM_PROPERTIES_ENABLED
203
#ifdef GLIBMM_PROPERTIES_ENABLED
204
/** Appearance of the shadow that surrounds the container.
206
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
207
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
208
* the value of the property changes.
210
Glib::PropertyProxy_ReadOnly<ShadowType> property_shadow_type() const;
211
#endif //#GLIBMM_PROPERTIES_ENABLED
213
#ifdef GLIBMM_PROPERTIES_ENABLED
214
/** Position of the handle relative to the child widget.
216
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
217
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
218
* the value of the property changes.
220
Glib::PropertyProxy<PositionType> property_handle_position() ;
221
#endif //#GLIBMM_PROPERTIES_ENABLED
223
#ifdef GLIBMM_PROPERTIES_ENABLED
224
/** Position of the handle relative to the child widget.
226
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
227
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
228
* the value of the property changes.
230
Glib::PropertyProxy_ReadOnly<PositionType> property_handle_position() const;
231
#endif //#GLIBMM_PROPERTIES_ENABLED
233
#ifdef GLIBMM_PROPERTIES_ENABLED
234
/** Side of the handlebox that's lined up with the docking point to dock the handlebox.
236
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
237
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
238
* the value of the property changes.
240
Glib::PropertyProxy<PositionType> property_snap_edge() ;
241
#endif //#GLIBMM_PROPERTIES_ENABLED
243
#ifdef GLIBMM_PROPERTIES_ENABLED
244
/** Side of the handlebox that's lined up with the docking point to dock the handlebox.
246
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
247
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
248
* the value of the property changes.
250
Glib::PropertyProxy_ReadOnly<PositionType> property_snap_edge() const;
251
#endif //#GLIBMM_PROPERTIES_ENABLED
253
#ifdef GLIBMM_PROPERTIES_ENABLED
254
/** Whether to use the value from the snap_edge property or a value derived from handle_position.
256
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
257
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
258
* the value of the property changes.
260
Glib::PropertyProxy<bool> property_snap_edge_set() ;
261
#endif //#GLIBMM_PROPERTIES_ENABLED
263
#ifdef GLIBMM_PROPERTIES_ENABLED
264
/** Whether to use the value from the snap_edge property or a value derived from handle_position.
266
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
267
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
268
* the value of the property changes.
270
Glib::PropertyProxy_ReadOnly<bool> property_snap_edge_set() const;
271
#endif //#GLIBMM_PROPERTIES_ENABLED
273
#ifdef GLIBMM_PROPERTIES_ENABLED
274
/** A boolean value indicating whether the handlebox's child is attached or detached.
276
* You rarely need to use properties because there are get_ and set_ methods for almost all of them.
277
* @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
278
* the value of the property changes.
280
Glib::PropertyProxy_ReadOnly<bool> property_child_detached() const;
281
#endif //#GLIBMM_PROPERTIES_ENABLED
286
} /* namespace Gtk */
291
/** A Glib::wrap() method for this object.
293
* @param object The C instance.
294
* @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
295
* @result A C++ instance that wraps this C instance.
297
* @relates Gtk::HandleBox
299
Gtk::HandleBox* wrap(GtkHandleBox* object, bool take_copy = false);
303
#endif /* _GTKMM_HANDLEBOX_H */