Reference Manual
Inti Logo
Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

handlebox.h

Go to the documentation of this file.
00001 /*  Inti: Integrated Foundation Classes
00002  *  Copyright (C) 2002-2003 The Inti Development Team.
00003  *  Copyright (C) 2000 Red Hat, Inc.
00004  *
00005  *  This program is free software; you can redistribute it and/or modify
00006  *  it under the terms of the GNU General Public License as published by
00007  *  the Free Software Foundation; either version 2 of the License, or
00008  *  (at your option) any later version.
00009  *
00010  *  This program is distributed in the hope that it will be useful,
00011  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  *  GNU Library General Public License for more details.
00014  *
00015  *  You should have received a copy of the GNU Library General Public License
00016  *  along with this program; if not, write to the Free Software
00017  *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
00018  */
00019  
00026 
00027 #ifndef INTI_GTK_HANDLE_BOX_H
00028 #define INTI_GTK_HANDLE_BOX_H
00029 
00030 #ifndef INTI_GTK_BIN_H
00031 #include <inti/gtk/bin.h>
00032 #endif
00033 
00034 #ifndef __GTK_HANDLE_BOX_H__
00035 #include <gtk/gtkhandlebox.h>
00036 #endif
00037 
00038 namespace Inti {
00039 
00040 namespace Gtk {
00041 
00042 class HandleBoxClass;
00043 
00060 
00061 class HandleBox : public Bin
00062 {
00063         friend class G::Object;
00064         friend class HandleBoxClass;
00065 
00066         HandleBox(const HandleBox&);
00067         HandleBox& operator=(const HandleBox&);
00068 
00069 protected:
00072 
00073         explicit HandleBox(GtkHandleBox *handle_box, bool reference = false);
00080 
00084 
00085         virtual void on_child_attached(Widget& child);
00091 
00092         virtual void on_child_detached(Widget& child);
00098 
00100 //  Properties
00101 
00102         typedef G::Property<ShadowType, int> ShadowTypePropertyType;
00103         typedef G::PropertyProxy<G::Object, ShadowTypePropertyType> ShadowTypePropertyProxy;
00104         static const ShadowTypePropertyType shadow_type_property;
00105 
00106         typedef G::Property<PositionType, int> HandlePositionPropertyType;
00107         typedef G::PropertyProxy<G::Object, HandlePositionPropertyType> HandlePositionPropertyProxy;
00108         static const HandlePositionPropertyType handle_position_property;
00109 
00110         typedef G::Property<PositionType, int> SnapEdgePropertyType;
00111         typedef G::PropertyProxy<G::Object, SnapEdgePropertyType> SnapEdgePropertyProxy;
00112         static const SnapEdgePropertyType snap_edge_property;
00113 
00114         typedef G::Property<bool> SnapEdgeSetPropertyType;
00115         typedef G::PropertyProxy<G::Object, SnapEdgeSetPropertyType> SnapEdgeSetPropertyProxy;
00116         static const SnapEdgeSetPropertyType snap_edge_set_property;
00117 
00118 //  Signals
00119 
00120         typedef G::Signal1<void, GtkWidget*> ChildAttachedSignalType;
00121         typedef G::SignalProxy<TypeInstance, ChildAttachedSignalType> ChildAttachedSignalProxy;
00122         static const ChildAttachedSignalType child_attached_signal;
00123 
00124         typedef G::Signal1<void, GtkWidget*> ChildDetachedSignalType;
00125         typedef G::SignalProxy<TypeInstance, ChildDetachedSignalType> ChildDetachedSignalProxy;
00126         static const ChildDetachedSignalType child_detached_signal;
00127 
00128 public:
00131 
00132         explicit HandleBox(ShadowType shadow_type = SHADOW_OUT);
00135 
00136         virtual ~HandleBox();
00138         
00142 
00143         GtkHandleBox* gtk_handle_box() const { return (GtkHandleBox*)instance; }
00145 
00146         GtkHandleBoxClass* gtk_handle_box_class() const;
00148 
00149         operator GtkHandleBox* () const;
00151 
00152         bool is_child_detached() const;
00154 
00155         Gdk::Window* get_bin_window() const;
00157 
00158         Gdk::Window* get_float_window() const;
00160 
00161         ShadowType get_shadow_type() const;
00163 
00164         PositionType get_handle_position() const;
00166 
00167         PositionType get_snap_edge() const;
00169 
00173         
00174         void set_shadow_type(ShadowType type);
00177 
00178         void set_handle_position(PositionType position);
00181 
00182         void set_snap_edge(PositionType edge);
00193 
00194         void unset_snap_edge();
00197 
00201 
00202         const ShadowTypePropertyProxy prop_shadow_type()
00203         {
00204                 return ShadowTypePropertyProxy(this, &shadow_type_property);
00205         }
00207 
00208         const HandlePositionPropertyProxy prop_handle_position()
00209         {
00210                 return HandlePositionPropertyProxy(this, &handle_position_property);
00211         }
00213 
00214         const SnapEdgePropertyProxy prop_snap_edge()
00215         {
00216                 return SnapEdgePropertyProxy(this, &snap_edge_property);
00217         }
00220 
00221         const SnapEdgeSetPropertyProxy prop_snap_edge_set()
00222         {
00223                 return SnapEdgeSetPropertyProxy(this, &snap_edge_set_property);
00224         }
00227 
00231         
00232         const ChildAttachedSignalProxy sig_child_attached()
00233         {
00234                 return ChildAttachedSignalProxy(this, &child_attached_signal);
00235         }
00238 
00239         const ChildDetachedSignalProxy sig_child_detached()
00240         {
00241                 return ChildDetachedSignalProxy(this, &child_detached_signal);
00242         }
00245 
00247 };
00248 
00249 } // namespace Gtk
00250 
00251 } // namespace Inti
00252 
00253 #endif // INTI_GTK_HANDLE_BOX_H
00254 
Main Page - Footer


Generated on Sun Sep 14 20:08:03 2003 for Inti by doxygen 1.3.2 written by Dimitri van Heesch, © 1997-2002