Ardour  9.0-pre0-582-g084a23a80d
tk/ytkmm/ytkmm/gtkmm/container.h
Go to the documentation of this file.
1 // -*- c++ -*-
2 // Generated by gmmproc 2.45.3 -- DO NOT MODIFY!
3 #ifndef _GTKMM_CONTAINER_H
4 #define _GTKMM_CONTAINER_H
5 
6 
7 #include <glibmm/ustring.h>
8 #include <sigc++/sigc++.h>
9 
10 /* $Id: container.hg,v 1.11 2006/04/12 11:11:25 murrayc Exp $ */
11 
12 /* Copyright (C) 1998-2002 The gtkmm Development Team
13  *
14  * This library is free software; you can redistribute it and/or
15  * modify it under the terms of the GNU Lesser General Public
16  * License as published by the Free Software Foundation; either
17  * version 2.1 of the License, or (at your option) any later version.
18  *
19  * This library is distributed in the hope that it will be useful,
20  * but WITHOUT ANY WARRANTY; without even the implied warranty of
21  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
22  * Lesser General Public License for more details.
23  *
24  * You should have received a copy of the GNU Lesser General Public
25  * License along with this library; if not, write to the Free
26  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
27  */
28 
29 #include <glibmm/listhandle.h>
30 #include <gtkmm/widget.h>
31 
32 
37 /* we'll include gtkfeatures because we dont want to include the whole
38  gtk/gtk.h - this file is used by almost ALL our widgets, so dependencies
39  in minimum - adding things here will increase compile times ALOT */
40 
41 
42 #ifndef DOXYGEN_SHOULD_SKIP_THIS
43 typedef struct _GtkContainer GtkContainer;
45 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
46 
47 
48 namespace Gtk
49 { class Container_Class; } // namespace Gtk
50 namespace Gtk
51 {
52 
53 class Adjustment;
54 class Label;
55 
71 class Container : public Widget
72 {
73  public:
74 #ifndef DOXYGEN_SHOULD_SKIP_THIS
75  typedef Container CppObjectType;
76  typedef Container_Class CppClassType;
77  typedef GtkContainer BaseObjectType;
78  typedef GtkContainerClass BaseClassType;
79 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
80 
81  virtual ~Container();
82 
83 #ifndef DOXYGEN_SHOULD_SKIP_THIS
84 
85 private:
86  friend class Container_Class;
87  static CppClassType container_class_;
88 
89  // noncopyable
90  Container(const Container&);
91  Container& operator=(const Container&);
92 
93 protected:
94  explicit Container(const Glib::ConstructParams& construct_params);
95  explicit Container(GtkContainer* castitem);
96 
97 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
98 
99 public:
100 #ifndef DOXYGEN_SHOULD_SKIP_THIS
101  static GType get_type() G_GNUC_CONST;
102 
103 
104  static GType get_base_type() G_GNUC_CONST;
105 #endif
106 
108  GtkContainer* gobj() { return reinterpret_cast<GtkContainer*>(gobject_); }
109 
111  const GtkContainer* gobj() const { return reinterpret_cast<GtkContainer*>(gobject_); }
112 
113 
114 public:
115  //C++ methods used to invoke GTK+ virtual functions:
116 
117 protected:
118  //GTK+ Virtual Functions (override these to change behaviour):
119 
120  //Default Signal Handlers::
122  virtual void on_add(Widget* widget);
124  virtual void on_remove(Widget* widget);
126  virtual void on_check_resize();
128  virtual void on_set_focus_child(Widget* widget);
129 
130 
131 private:
132 
133  //gtkmmproc error: gtk_container_children : ignored method defs lookup failed//gtkmmproc error: gtk_container_border_width : ignored method defs lookup failed
134 public:
135 
136 /* Application-level methods */
137 
138 
153  void set_border_width(guint border_width);
154 
155 
161  guint get_border_width() const;
162 
163  //This is virtual so that we can override it in Gtk::ScrolledWindow:
164  virtual void add(Widget& widget);
165 
166 
175  void remove(Widget& widget);
176 
177 
186  void set_resize_mode(ResizeMode resize_mode);
187 
188 
195 
196 
199  void check_resize();
200 
204  typedef sigc::slot<void, Widget&> ForeachSlot;
205 
215  void foreach(const ForeachSlot& slot);
216 
218  //_WRAP_METHOD(void foreach_(GtkCallback callback,gpointer data),gtk_container_foreach)
219 
221  //_WRAP_METHOD(void foreach_full_(GtkCallback callback,GtkCallbackMarshal marshal, gpointer data,GDestroyNotify notify),gtk_container_foreach_full)
222 
223 
229  Glib::ListHandle<Widget*> get_children();
230 
236  Glib::ListHandle<const Widget*> get_children() const;
237 
238 
257 
258 
269  void set_focus_chain(const Glib::ListHandle<Widget*>& focusable_widgets);
270 
271  // gtk_container_get_focus_chain() has been split up into two
272  // functions in order to make implicit container conversion possible.
273  bool has_focus_chain() const;
274  Glib::ListHandle<Widget*> get_focus_chain();
275  Glib::ListHandle<const Widget*> get_focus_chain() const;
276 
277 
281 
282 
283 /* Widget-level methods */
284 
285 
293  void set_reallocate_redraws(bool needs_redraws = true);
294 
295 
298  void set_focus_child(Widget& widget);
299 
300 
315 
316 
324 
332 
333 
348 
349 
357 
365 
366 
368 
369 
378  GType child_type() const;
379 
380  // Ignore functions such as gtk_container_class_install_child_property(), which I think are for themes, like the GtkWidget style properties.
381 
382 
389  Glib::SignalProxy1< void,Widget* > signal_add();
390 
391 
392  //We use the optional custom_c_callback parameter with _WRAP_SIGNAL() here,
393  //so that we can write special code to check for deleted child widget parameters:
394 
401  Glib::SignalProxy1< void,Widget* > signal_remove();
402 
403 
410  Glib::SignalProxy0< void > signal_check_resize();
411 
412 
419  Glib::SignalProxy1< void,Widget* > signal_set_focus_child();
420 
421 
422  void show_all_children(bool recursive = true);
423 
424 protected:
426 
427  virtual GType child_type_vfunc() const;
428 
429  virtual void forall_vfunc(gboolean include_internals, GtkCallback callback, gpointer callback_data);
430 
431  //TODO: What is this?
432  virtual char* composite_name_vfunc(GtkWidget* child);
433 
434  virtual void set_child_property_vfunc(GtkWidget* child, guint property_id, const GValue* value, GParamSpec* pspec);
435 
436  virtual void get_child_property_vfunc(GtkWidget* child, guint property_id, GValue* value, GParamSpec* pspec) const;
437 
438 
444  Glib::PropertyProxy< guint > property_border_width() ;
445 
451  Glib::PropertyProxy_ReadOnly< guint > property_border_width() const;
452 
458  Glib::PropertyProxy< ResizeMode > property_resize_mode() ;
459 
465  Glib::PropertyProxy_ReadOnly< ResizeMode > property_resize_mode() const;
466 
472  Glib::PropertyProxy_WriteOnly< Widget* > property_child() ;
473 
474 
475 };
476 
477 } // namespace Gtk
478 
479 
480 namespace Glib
481 {
490  Gtk::Container* wrap(GtkContainer* object, bool take_copy = false);
491 } //namespace Glib
492 
493 
494 #endif /* _GTKMM_CONTAINER_H */
495 
void resize_children()
void show_all_children(bool recursive=true)
Glib::PropertyProxy< ResizeMode > property_resize_mode()
bool has_focus_chain() const
Glib::PropertyProxy_ReadOnly< guint > property_border_width() const
Glib::SignalProxy1< void, Widget * > signal_add()
void set_border_width(guint border_width)
virtual void get_child_property_vfunc(GtkWidget *child, guint property_id, GValue *value, GParamSpec *pspec) const
sigc::slot< void, Widget & > ForeachSlot
GtkContainer * gobj()
Provides access to the underlying C GtkObject.
virtual void set_child_property_vfunc(GtkWidget *child, guint property_id, const GValue *value, GParamSpec *pspec)
Glib::ListHandle< Widget * > get_focus_chain()
guint get_border_width() const
virtual ~Container()
Adjustment * get_focus_vadjustment()
virtual void forall_vfunc(gboolean include_internals, GtkCallback callback, gpointer callback_data)
GType child_type() const
virtual void on_add(Widget *widget)
This is a default handler for the signal signal_add().
virtual char * composite_name_vfunc(GtkWidget *child)
Glib::SignalProxy1< void, Widget * > signal_set_focus_child()
virtual GType child_type_vfunc() const
Glib::PropertyProxy< guint > property_border_width()
void set_resize_mode(ResizeMode resize_mode)
Glib::PropertyProxy_WriteOnly< Widget * > property_child()
void set_reallocate_redraws(bool needs_redraws=true)
Adjustment * get_focus_hadjustment()
const Adjustment * get_focus_hadjustment() const
Gtk::Container * wrap(GtkContainer *object, bool take_copy=false)
Glib::SignalProxy0< void > signal_check_resize()
Glib::PropertyProxy_ReadOnly< ResizeMode > property_resize_mode() const
void remove(Widget &widget)
const GtkContainer * gobj() const
Provides access to the underlying C GtkObject.
Glib::SignalProxy1< void, Widget * > signal_remove()
void set_focus_vadjustment(Adjustment &adjustment)
void propagate_expose(Widget &child, GdkEventExpose *event)
void set_focus_child(Widget &widget)
const Adjustment * get_focus_vadjustment() const
ResizeMode get_resize_mode() const
Glib::ListHandle< Widget * > get_children()
(internal) Operate on contained items (see foreach())
Glib::ListHandle< const Widget * > get_focus_chain() const
void unset_focus_chain()
Glib::ListHandle< const Widget * > get_children() const
void check_resize()
void set_focus_hadjustment(Adjustment &adjustment)
virtual void add(Widget &widget)
virtual void on_check_resize()
This is a default handler for the signal signal_check_resize().
virtual void on_remove(Widget *widget)
This is a default handler for the signal signal_remove().
void set_focus_chain(const Glib::ListHandle< Widget * > &focusable_widgets)
virtual void on_set_focus_child(Widget *widget)
This is a default handler for the signal signal_set_focus_child().
bool event(GdkEvent *event)
void(* GtkCallback)(GtkWidget *widget, gpointer data)
Definition: gtkwidget.h:508
Definition: ardour_ui.h:188