CEBL  2.1
CEBLGtkWidget.cpp
Go to the documentation of this file.
1 /* CEBLGtkWidget.hpp
2  * \author Jeshua Bratman
3  *
4  * Simple C++ gtk widget class.
5  *
6  */
7 
8 #include "CEBLGtkWidget.hpp"
9 
10 //-----------------------------------------------------------
11 // Constructors / Destructors
12 
14 {
15  cebl_gtk_widget_container = gtk_vbox_new(false, 0);
16  g_object_ref(cebl_gtk_widget_container);
17 }
19 {
20  g_object_unref(cebl_gtk_widget_container);
21 }
22 
23 //-----------------------------------------------------------
24 // Widget Controls
25 
27 {
29 }
30 CEBLGtkWidget::operator GtkWidget*()
31 {
32  return cebl_gtk_widget_container;
33 }
34 // remove a widget from the container
35 void CEBLGtkWidget::removeWidget(GtkWidget* widget)
36 {
37  gtk_container_remove(GTK_CONTAINER(this->cebl_gtk_widget_container),widget);
38 }
39 
40 // hide the widget
42 {
43  gtk_widget_hide(this->cebl_gtk_widget_container);
44 }
45 
46 
47 // show the widget
49 {
50  gtk_widget_show_all(this->cebl_gtk_widget_container);
51 }
52