GFC Logo GFC Title Logo
Reference Manual
Main Page  |  Namespace List  |  Alphabetical List  |  Class List  |  File List

buttonbox.hh

Go to the documentation of this file.
00001 /* GFC-UI: GTK+ Foundation Classes (User Interface Library) 00002 * Copyright (C) 2002-2004 The GFC Development Team. 00003 * 00004 * This program is free software; you can redistribute it and/or modify 00005 * it under the terms of the GNU General Public License as published by 00006 * the Free Software Foundation; either version 2 of the License, or 00007 * (at your option) any later version. 00008 * 00009 * This program is distributed in the hope that it will be useful, 00010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00012 * GNU Library General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU Library General Public License 00015 * along with this program; if not, write to the Free Software 00016 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00017 */ 00018 00024 00025 #ifndef GFC_GTK_BUTTON_BOX_HH 00026 #define GFC_GTK_BUTTON_BOX_HH 00027 00028 #ifndef GFC_GTK_BOX_HH 00029 #include <gfc/gtk/box.hh> 00030 #endif 00031 00032 #ifndef __GTK_HBUTTON_BOX_H__ 00033 #include <gtk/gtkhbbox.h> 00034 #endif 00035 00036 #ifndef __GTK_VBUTTON_BOX_H__ 00037 #include <gtk/gtkvbbox.h> 00038 #endif 00039 00040 namespace GFC { 00041 00042 namespace Gtk { 00043 00047 00048 enum ButtonBoxStyle 00049 { 00050 BUTTONBOX_DEFAULT_STYLE = GTK_BUTTONBOX_DEFAULT_STYLE, 00051 BUTTONBOX_SPREAD = GTK_BUTTONBOX_SPREAD, 00052 BUTTONBOX_EDGE = GTK_BUTTONBOX_EDGE, 00053 BUTTONBOX_START = GTK_BUTTONBOX_START, 00054 BUTTONBOX_END = GTK_BUTTONBOX_END 00055 }; 00056 00067 00068 class ButtonBox : public Box 00069 { 00070 friend class G::Object; 00071 00072 ButtonBox(const ButtonBox&); 00073 ButtonBox& operator=(const ButtonBox&); 00074 00075 protected: 00078 00079 explicit ButtonBox(GtkButtonBox *button_box, bool owns_reference = false); 00086 00087 virtual ~ButtonBox() = 0; 00089 00091 00092 public: 00095 00096 GtkButtonBox* gtk_button_box() const; 00098 00099 operator GtkButtonBox* () const; 00101 00102 ButtonBoxStyle get_layout() const; 00105 00106 bool get_child_secondary(const Widget& child) const; 00110 00114 00115 void set_layout(ButtonBoxStyle layout_style); 00118 00119 void set_child_secondary(Widget& child, bool is_secondary); 00132 00134 }; 00135 00149 00150 class HButtonBox : public ButtonBox 00151 { 00152 friend class G::Object; 00153 00154 HButtonBox(const HButtonBox&); 00155 HButtonBox& operator=(const HButtonBox&); 00156 00157 protected: 00160 00161 explicit HButtonBox(GtkHButtonBox *hbutton_box, bool owns_reference = false); 00168 00170 00171 public: 00174 00175 explicit HButtonBox(ButtonBoxStyle layout = BUTTONBOX_DEFAULT_STYLE, int spacing = 0); 00179 00180 virtual ~HButtonBox(); 00182 00186 00187 GtkHButtonBox* gtk_hbutton_box() const; 00189 00190 operator GtkHButtonBox* () const; 00192 00194 }; 00195 00209 00210 class VButtonBox : public ButtonBox 00211 { 00212 friend class G::Object; 00213 00214 VButtonBox(const VButtonBox&); 00215 VButtonBox& operator=(const VButtonBox&); 00216 00217 protected: 00220 00221 explicit VButtonBox(GtkVButtonBox *vbutton_box, bool owns_reference = false); 00228 00230 00231 public: 00234 explicit VButtonBox(ButtonBoxStyle layout = BUTTONBOX_DEFAULT_STYLE, int spacing = 0); 00238 00239 00240 virtual ~VButtonBox(); 00242 00246 00247 GtkVButtonBox* gtk_vbutton_box() const; 00249 00250 operator GtkVButtonBox* () const; 00252 00254 }; 00255 00256 } // namespace Gtk 00257 00258 } // namespace GFC 00259 00260 #include <gfc/gtk/inline/buttonbox.inl> 00261 00262 #endif // GFC_GTK_BUTTON_BOX_HH 00263

Generated on Tue Aug 24 00:34:30 2004 for GFC-UI by doxygen 1.3.8