[gtkmm] Gtk: Remove API which has been removed in gtk+-4



commit bb8fc483ad771d5a686b3d0ea79895159f0df8d7
Author: Kjell Ahlstedt <kjell ahlstedt bredband net>
Date:   Sun Jan 22 16:23:51 2017 +0100

    Gtk: Remove API which has been removed in gtk+-4
    
    gtk_init() does not take argc and argv parameters any more.
    The visible property has default value true. Therefore gtk_widget_show_all()
    and friends have become unnecessary and have been removed.
    
    * gtk/src/application.ccg: Remove parameters from calls to gtk_init().
    * gtk/src/bin.ccg: add_pixlabel(): Remove call to Gtk::Widget::show_all().
    * gtk/src/combobox.[ccg|hg]: Remove property_cell_area() and the constructor
    that takes a CellArea parameter-
    * gtk/src/container.[ccg|hg]: Remove show_all_children().
    * gtk/src/main.[ccg|hg]: Remove constructors that take (argc,argv) parameters.
    Remove add_gtk_option_group() because gtk_get_option_group() has been removed.
    * gtk/src/widget.hg: Remove show_all(), set/get_no_show_all(),
    show_all_vfunc(), property_no_show_all().
    * demos/gtk-demo/*.cc:
    * tests/*/*.cc: Remove all calls to Container::show_all_children() and
    Widget::show_all().
    * tests/object_move/main.cc: Remove the (argc,argv) parameters from the call
    to gtk_init().

 demos/gtk-demo/demowindow.cc                      |    2 -
 demos/gtk-demo/example_appwindow.cc               |    2 -
 demos/gtk-demo/example_builder.cc                 |    2 -
 demos/gtk-demo/example_buttonbox.cc               |    2 -
 demos/gtk-demo/example_change_display.cc          |    6 --
 demos/gtk-demo/example_colorsel.cc                |    2 -
 demos/gtk-demo/example_dialog.cc                  |    4 -
 demos/gtk-demo/example_drawingarea.cc             |    1 -
 demos/gtk-demo/example_flowbox.cc                 |    2 -
 demos/gtk-demo/example_gestures.cc                |    2 -
 demos/gtk-demo/example_glarea.cc                  |    2 -
 demos/gtk-demo/example_headerbar.cc               |    2 -
 demos/gtk-demo/example_iconbrowser.cc             |    4 -
 demos/gtk-demo/example_iconview.cc                |    2 -
 demos/gtk-demo/example_images.cc                  |    2 -
 demos/gtk-demo/example_menus.cc                   |    2 -
 demos/gtk-demo/example_overlay.cc                 |    2 -
 demos/gtk-demo/example_panes.cc                   |    2 -
 demos/gtk-demo/example_pixbufs.cc                 |    2 -
 demos/gtk-demo/example_shortcuts.cc               |    2 -
 demos/gtk-demo/example_sizegroup.cc               |    2 -
 demos/gtk-demo/example_stack.cc                   |    2 -
 demos/gtk-demo/example_stacksidebar.cc            |    2 -
 demos/gtk-demo/example_textview.cc                |    7 +-
 demos/gtk-demo/example_treeview_editable_cells.cc |    2 -
 demos/gtk-demo/example_treeview_liststore.cc      |    2 -
 demos/gtk-demo/example_treeview_treestore.cc      |    2 -
 gtk/src/application.ccg                           |    4 +-
 gtk/src/bin.ccg                                   |    1 -
 gtk/src/combobox.ccg                              |    6 --
 gtk/src/combobox.hg                               |   10 ---
 gtk/src/container.ccg                             |   14 ----
 gtk/src/container.hg                              |    2 -
 gtk/src/main.ccg                                  |   50 +------------
 gtk/src/main.hg                                   |   78 +--------------------
 gtk/src/widget.hg                                 |    6 --
 tests/child_widget/testwindow.cc                  |    4 -
 tests/child_widget2/main.cc                       |    1 -
 tests/child_widget_managed/main.cc                |    2 -
 tests/delete_cpp_child/main.cc                    |    2 -
 tests/dialog/main.cc                              |    2 -
 tests/dialog_deletethis/main.cc                   |    1 -
 tests/object_move/main.cc                         |    4 +-
 tests/refcount_dialog/main.cc                     |    2 -
 44 files changed, 12 insertions(+), 243 deletions(-)
---
diff --git a/demos/gtk-demo/demowindow.cc b/demos/gtk-demo/demowindow.cc
index dbca1fa..b94900f 100644
--- a/demos/gtk-demo/demowindow.cc
+++ b/demos/gtk-demo/demowindow.cc
@@ -98,7 +98,6 @@ DemoWindow::DemoWindow()
   set_default_size (800, 600);
 
   load_file (testgtk_demos[0].filename);
-  show_all();
 }
 
 void DemoWindow::configure_header_bar()
@@ -425,7 +424,6 @@ void DemoWindow::add_data_tabs(const std::string& filename)
         continue;
       }
     }
-    widget->show_all();
     m_Notebook.append_page(*Gtk::manage(widget), resources[i]);
     m_Notebook.child_property_tab_expand(*widget) = true;
   }
diff --git a/demos/gtk-demo/example_appwindow.cc b/demos/gtk-demo/example_appwindow.cc
index be6c4e5..21c0290 100644
--- a/demos/gtk-demo/example_appwindow.cc
+++ b/demos/gtk-demo/example_appwindow.cc
@@ -124,8 +124,6 @@ Example_AppWindow::Example_AppWindow()
   refTextBuffer->signal_changed().connect(sigc::mem_fun(*this, &Example_AppWindow::on_text_changed));
   refTextBuffer->signal_mark_set().connect(sigc::mem_fun(*this, &Example_AppWindow::on_text_mark_set));
   on_text_changed();
-
-  show_all();
 }
 
 Example_AppWindow::~Example_AppWindow()
diff --git a/demos/gtk-demo/example_builder.cc b/demos/gtk-demo/example_builder.cc
index e5eb975..3eee4ce 100644
--- a/demos/gtk-demo/example_builder.cc
+++ b/demos/gtk-demo/example_builder.cc
@@ -112,8 +112,6 @@ Example_Builder::Example_Builder(
   if (pMenuItem)
     pMenuItem->add_accelerator("activate", refAccelGroup,
       GDK_KEY_F7, (Gdk::ModifierType)0, Gtk::ACCEL_VISIBLE);
-
-  show_all();
 }
 
 Example_Builder::~Example_Builder()
diff --git a/demos/gtk-demo/example_buttonbox.cc b/demos/gtk-demo/example_buttonbox.cc
index 0f9a7ac..6e401db 100644
--- a/demos/gtk-demo/example_buttonbox.cc
+++ b/demos/gtk-demo/example_buttonbox.cc
@@ -61,8 +61,6 @@ Example_ButtonBox::Example_ButtonBox()
   m_HBox.pack_start( *(create_button_box(false, "Edge", 30, Gtk::BUTTONBOX_EDGE)) );
   m_HBox.pack_start( *(create_button_box(false, "Start", 30, Gtk::BUTTONBOX_START)) );
   m_HBox.pack_start( *(create_button_box(false, "End", 30, Gtk::BUTTONBOX_END)) );
-
-  show_all();
 }
 
 Example_ButtonBox::~Example_ButtonBox()
diff --git a/demos/gtk-demo/example_change_display.cc b/demos/gtk-demo/example_change_display.cc
index 43ac50d..1f3e44c 100644
--- a/demos/gtk-demo/example_change_display.cc
+++ b/demos/gtk-demo/example_change_display.cc
@@ -140,8 +140,6 @@ Example_ChangeDisplay::Example_ChangeDisplay()
   }
 
   initialize_displays();
-
-  show_all();
 }
 
 Example_ChangeDisplay::~Example_ChangeDisplay()
@@ -223,8 +221,6 @@ void Example_ChangeDisplay::on_button_display_open()
 
   entry.grab_focus();
 
-  dialog.show_all_children();
-
   Glib::RefPtr<Gdk::Display> refResult;
   while (!refResult)
   {
@@ -383,8 +379,6 @@ Popup::Popup(const Glib::RefPtr<Gdk::Screen>& screen, const Glib::ustring& promp
 
   m_Label.property_margin() = 10;
   m_Frame.add(m_Label);
-
-  show_all_children();
 }
 
 Popup::~Popup()
diff --git a/demos/gtk-demo/example_colorsel.cc b/demos/gtk-demo/example_colorsel.cc
index ac29ad9..877e726 100644
--- a/demos/gtk-demo/example_colorsel.cc
+++ b/demos/gtk-demo/example_colorsel.cc
@@ -62,8 +62,6 @@ Example_ColorSel::Example_ColorSel()
   m_VBox.pack_start(m_Button, Gtk::PACK_SHRINK);
 
   m_Button.signal_clicked().connect(sigc::mem_fun(*this, &Example_ColorSel::on_button_clicked));
-
-  show_all();
 }
 
 Example_ColorSel::~Example_ColorSel()
diff --git a/demos/gtk-demo/example_dialog.cc b/demos/gtk-demo/example_dialog.cc
index 2273207..48bc7be 100644
--- a/demos/gtk-demo/example_dialog.cc
+++ b/demos/gtk-demo/example_dialog.cc
@@ -100,8 +100,6 @@ Example_Dialog::Example_Dialog()
   m_Grid.attach(m_Label2, 0, 1, 1, 1);
   m_Grid.attach(m_Entry2, 1, 1, 1, 1);
   m_Label2.set_mnemonic_widget(m_Entry2);
-
-  show_all();
 }
 
 Example_Dialog::~Example_Dialog()
@@ -158,8 +156,6 @@ Dialog_Interactive::Dialog_Interactive(Gtk::Window& parent, const Glib::ustring&
   m_Entry2.set_text(entry2);
   m_Grid.attach(m_Entry2, 1, 1, 1, 1);
   m_Label2.set_mnemonic_widget(m_Entry2);
-
-  show_all();
 }
 
 Glib::ustring Dialog_Interactive::get_entry1() const
diff --git a/demos/gtk-demo/example_drawingarea.cc b/demos/gtk-demo/example_drawingarea.cc
index 83d5f74..1045337 100644
--- a/demos/gtk-demo/example_drawingarea.cc
+++ b/demos/gtk-demo/example_drawingarea.cc
@@ -108,7 +108,6 @@ Example_DrawingArea::Example_DrawingArea()
                                     Gdk::BUTTON_PRESS_MASK |
                                     Gdk::POINTER_MOTION_MASK |
                                     Gdk::STRUCTURE_MASK);
-  show_all();
 }
 
 Example_DrawingArea::~Example_DrawingArea()
diff --git a/demos/gtk-demo/example_flowbox.cc b/demos/gtk-demo/example_flowbox.cc
index 49570c4..ef33b31 100644
--- a/demos/gtk-demo/example_flowbox.cc
+++ b/demos/gtk-demo/example_flowbox.cc
@@ -62,8 +62,6 @@ Example_FlowBox::Example_FlowBox()
   // Layout
   m_scrolled_window.add(m_flow_box);
   add(m_scrolled_window);
-
-  show_all_children();
 }
 
 Example_FlowBox::~Example_FlowBox()
diff --git a/demos/gtk-demo/example_gestures.cc b/demos/gtk-demo/example_gestures.cc
index c4b9a26..effd923 100644
--- a/demos/gtk-demo/example_gestures.cc
+++ b/demos/gtk-demo/example_gestures.cc
@@ -75,8 +75,6 @@ Example_Gestures::Example_Gestures()
   m_GestureZoom = Gtk::GestureZoom::create(m_DrawingArea);
   m_GestureZoom->set_propagation_phase(Gtk::PHASE_BUBBLE);
   m_GestureZoom->signal_scale_changed().connect(sigc::mem_fun(*this, 
&Example_Gestures::on_gesture_zoom_scale_changed));
-
-  show_all();
 }
 
 Example_Gestures::~Example_Gestures()
diff --git a/demos/gtk-demo/example_glarea.cc b/demos/gtk-demo/example_glarea.cc
index ac960e6..e39c518 100644
--- a/demos/gtk-demo/example_glarea.cc
+++ b/demos/gtk-demo/example_glarea.cc
@@ -100,8 +100,6 @@ Example_GLArea::Example_GLArea() : m_RotationAngles(N_AXIS, 0.0f)
   m_VBox.add(m_Button);
   // Connect clicked to close of window
   m_Button.signal_clicked().connect(sigc::mem_fun(*this, &Gtk::Window::close));
-
-  show_all();
 }
 
 Example_GLArea::~Example_GLArea()
diff --git a/demos/gtk-demo/example_headerbar.cc b/demos/gtk-demo/example_headerbar.cc
index 44022dc..50d1217 100644
--- a/demos/gtk-demo/example_headerbar.cc
+++ b/demos/gtk-demo/example_headerbar.cc
@@ -69,8 +69,6 @@ Example_HeaderBar::Example_HeaderBar()
   // Layout
   set_titlebar(m_header_bar);
   add(m_text_view);
-
-  show_all_children();
 }
 
 Example_HeaderBar::~Example_HeaderBar()
diff --git a/demos/gtk-demo/example_iconbrowser.cc b/demos/gtk-demo/example_iconbrowser.cc
index fa14ba9..76ef850 100644
--- a/demos/gtk-demo/example_iconbrowser.cc
+++ b/demos/gtk-demo/example_iconbrowser.cc
@@ -262,8 +262,6 @@ Example_IconBrowser::Example_IconBrowser()
 
   on_symbolic_radio_toggled();
   populate();
-
-  show_all_children();
 }
 
 Example_IconBrowser::~Example_IconBrowser()
@@ -929,8 +927,6 @@ DetailDialog::DetailDialog(Gtk::Window& parent)
   m_description.set_max_width_chars(60);
   m_description.set_halign(Gtk::ALIGN_START);
   m_description.set_valign(Gtk::ALIGN_START);
-
-  show_all_children();
 }
 
 DetailDialog::~DetailDialog()
diff --git a/demos/gtk-demo/example_iconview.cc b/demos/gtk-demo/example_iconview.cc
index 6a14bce..b089801 100644
--- a/demos/gtk-demo/example_iconview.cc
+++ b/demos/gtk-demo/example_iconview.cc
@@ -124,8 +124,6 @@ Example_IconView::Example_IconView()
   m_IconView.grab_focus();
 
   add(m_VBox);
-
-  show_all();
 }
 
 int Example_IconView::on_model_sort(const Gtk::TreeModel::const_iterator& a, const 
Gtk::TreeModel::const_iterator& b)
diff --git a/demos/gtk-demo/example_images.cc b/demos/gtk-demo/example_images.cc
index 42c7335..c19173f 100644
--- a/demos/gtk-demo/example_images.cc
+++ b/demos/gtk-demo/example_images.cc
@@ -99,8 +99,6 @@ Example_Images::Example_Images()
   m_Frame_Progressive.add(m_Image_Progressive);
 
   start_progressive_loading();
-
-  show_all();
 }
 
 Example_Images::~Example_Images()
diff --git a/demos/gtk-demo/example_menus.cc b/demos/gtk-demo/example_menus.cc
index 72edcb1..61fb7d2 100644
--- a/demos/gtk-demo/example_menus.cc
+++ b/demos/gtk-demo/example_menus.cc
@@ -122,8 +122,6 @@ Example_Menus::Example_Menus()
   m_VBox_Sub2.pack_start(m_Button);
   m_Button.property_can_default() = true;
   m_Button.grab_default();
-
-  show_all();
 }
 
 Example_Menus::~Example_Menus()
diff --git a/demos/gtk-demo/example_overlay.cc b/demos/gtk-demo/example_overlay.cc
index d3a1665..f0f9dce 100644
--- a/demos/gtk-demo/example_overlay.cc
+++ b/demos/gtk-demo/example_overlay.cc
@@ -48,8 +48,6 @@ Example_Overlay::Example_Overlay()
   // Layout
   m_overlay.add(m_scrolled_window);
   add(m_overlay);
-
-  show_all_children();
 }
 
 Example_Overlay::~Example_Overlay()
diff --git a/demos/gtk-demo/example_panes.cc b/demos/gtk-demo/example_panes.cc
index 294381f..037ebef 100644
--- a/demos/gtk-demo/example_panes.cc
+++ b/demos/gtk-demo/example_panes.cc
@@ -77,8 +77,6 @@ Example_Panes::Example_Panes()
   // Now create check buttons to control sizing
   pVBox->pack_start(*Gtk::manage(new PaneOptions(*pHPaned, "Horizontal", "Left", "Right")), 
Gtk::PACK_SHRINK);
   pVBox->pack_start(*Gtk::manage(new PaneOptions(*pVPaned, "Vertical", "Top", "Bottom")),   
Gtk::PACK_SHRINK);
-
-  show_all();
 }
 
 Example_Panes::~Example_Panes()
diff --git a/demos/gtk-demo/example_pixbufs.cc b/demos/gtk-demo/example_pixbufs.cc
index 38008a7..dfd7822 100644
--- a/demos/gtk-demo/example_pixbufs.cc
+++ b/demos/gtk-demo/example_pixbufs.cc
@@ -98,8 +98,6 @@ Example_Pixbufs::Example_Pixbufs()
     Gtk::MessageDialog dialog(strMsg, false, Gtk::MESSAGE_ERROR, Gtk::BUTTONS_CLOSE);
     dialog.run();
   }
-
-  show_all();
 }
 
 Example_Pixbufs::~Example_Pixbufs()
diff --git a/demos/gtk-demo/example_shortcuts.cc b/demos/gtk-demo/example_shortcuts.cc
index ca12a1c..e73008c 100644
--- a/demos/gtk-demo/example_shortcuts.cc
+++ b/demos/gtk-demo/example_shortcuts.cc
@@ -94,8 +94,6 @@ Example_Shortcuts::Example_Shortcuts(
   if (pButton)
     pButton->signal_clicked().connect(sigc::bind(sigc::mem_fun(
       *this, &Example_Shortcuts::on_button_clicked), "shortcuts_boxes", "display"));
-
-  show_all();
 }
 
 Example_Shortcuts::~Example_Shortcuts()
diff --git a/demos/gtk-demo/example_sizegroup.cc b/demos/gtk-demo/example_sizegroup.cc
index f4d1ef0..ca993c3 100644
--- a/demos/gtk-demo/example_sizegroup.cc
+++ b/demos/gtk-demo/example_sizegroup.cc
@@ -108,8 +108,6 @@ Example_SizeGroup::Example_SizeGroup()
   m_VBox.pack_start(m_CheckButton, Gtk::PACK_SHRINK);
   m_CheckButton.set_active();
   m_CheckButton.signal_toggled().connect(sigc::mem_fun(*this, &Example_SizeGroup::on_checkbutton_toggled));
-
-  show_all();
 }
 
 Example_SizeGroup::~Example_SizeGroup()
diff --git a/demos/gtk-demo/example_stack.cc b/demos/gtk-demo/example_stack.cc
index 42b0542..ede1667 100644
--- a/demos/gtk-demo/example_stack.cc
+++ b/demos/gtk-demo/example_stack.cc
@@ -64,8 +64,6 @@ Example_Stack::Example_Stack()
   m_grid.attach(m_stack_switcher, 0, 0, 1, 1);
   m_grid.attach(m_stack, 0, 1, 1, 1);
   add(m_grid);
-
-  show_all_children();
 }
 
 Example_Stack::~Example_Stack()
diff --git a/demos/gtk-demo/example_stacksidebar.cc b/demos/gtk-demo/example_stacksidebar.cc
index 8fca65a..7c642e2 100644
--- a/demos/gtk-demo/example_stacksidebar.cc
+++ b/demos/gtk-demo/example_stacksidebar.cc
@@ -75,8 +75,6 @@ Example_StackSidebar::Example_StackSidebar()
     }
     m_Stack.add(*widget, m_page_names[i], m_page_names[i]);
   }
-
-  show_all();
 }
 
 Example_StackSidebar::~Example_StackSidebar()
diff --git a/demos/gtk-demo/example_textview.cc b/demos/gtk-demo/example_textview.cc
index 26f8876..55c7adf 100644
--- a/demos/gtk-demo/example_textview.cc
+++ b/demos/gtk-demo/example_textview.cc
@@ -91,8 +91,6 @@ Example_TextView::Example_TextView()
 
   attach_widgets(m_View1);
   attach_widgets(*m_pView2);
-
-  show_all();
 }
 
 Example_TextView::~Example_TextView()
@@ -427,7 +425,6 @@ void Example_TextView::attach_widgets(Gtk::TextView& text_view)
     if(pWidget)
     {
       text_view.add_child_at_anchor(*pWidget, refAnchor);
-      pWidget->show_all();
     }
 
     ++i;
@@ -436,7 +433,7 @@ void Example_TextView::attach_widgets(Gtk::TextView& text_view)
 
 void Example_TextView::on_button_clicked()
 {
-  m_WindowEasterEgg.show_all();
+  m_WindowEasterEgg.present();
 }
 
 Window_EasterEgg::Window_EasterEgg()
@@ -457,6 +454,8 @@ Window_EasterEgg::Window_EasterEgg()
   m_ScrolledWindow.set_policy(Gtk::POLICY_AUTOMATIC, Gtk::POLICY_AUTOMATIC);
   add(m_ScrolledWindow);
   m_ScrolledWindow.add(*m_pTextView);
+
+  hide();
 }
 
 Window_EasterEgg::~Window_EasterEgg()
diff --git a/demos/gtk-demo/example_treeview_editable_cells.cc 
b/demos/gtk-demo/example_treeview_editable_cells.cc
index aff59a2..8fda091 100644
--- a/demos/gtk-demo/example_treeview_editable_cells.cc
+++ b/demos/gtk-demo/example_treeview_editable_cells.cc
@@ -135,8 +135,6 @@ Example_TreeView_EditableCells::Example_TreeView_EditableCells()
   m_HBox.pack_start(m_Button_Remove);
   m_Button_Remove.signal_clicked().connect(
     sigc::mem_fun(*this, &Example_TreeView_EditableCells::on_button_remove_clicked));
-
-  show_all();
 }
 
 Example_TreeView_EditableCells::~Example_TreeView_EditableCells()
diff --git a/demos/gtk-demo/example_treeview_liststore.cc b/demos/gtk-demo/example_treeview_liststore.cc
index f40c75d..615b588 100644
--- a/demos/gtk-demo/example_treeview_liststore.cc
+++ b/demos/gtk-demo/example_treeview_liststore.cc
@@ -122,8 +122,6 @@ Example_TreeView_ListStore::Example_TreeView_ListStore()
 
   add_columns();
   m_ScrolledWindow.add(m_TreeView);
-
-  show_all();
 }
 
 Example_TreeView_ListStore::~Example_TreeView_ListStore()
diff --git a/demos/gtk-demo/example_treeview_treestore.cc b/demos/gtk-demo/example_treeview_treestore.cc
index 13646d0..de50dd0 100644
--- a/demos/gtk-demo/example_treeview_treestore.cc
+++ b/demos/gtk-demo/example_treeview_treestore.cc
@@ -170,8 +170,6 @@ Example_TreeView_TreeStore::Example_TreeView_TreeStore()
 
   add_columns();
   m_ScrolledWindow.add(m_TreeView);
-
-  show_all();
 }
 
 Example_TreeView_TreeStore::~Example_TreeView_TreeStore()
diff --git a/gtk/src/application.ccg b/gtk/src/application.ccg
index e4f4be7..2af7342 100644
--- a/gtk/src/application.ccg
+++ b/gtk/src/application.ccg
@@ -97,7 +97,7 @@ Application::Application(const Glib::ustring& application_id, Gio::ApplicationFl
   m_argc(0),
   m_argv(nullptr)
 {
-  gtk_init(nullptr, nullptr);
+  gtk_init();
   set_cxx_locale_to_c_locale();
 }
 
@@ -110,7 +110,7 @@ Application::Application(int& argc, char**& argv, const Glib::ustring& applicati
   m_argc(argc),
   m_argv(argv)
 {
-  gtk_init(&argc, &argv);
+  gtk_init();
   set_cxx_locale_to_c_locale();
 }
 
diff --git a/gtk/src/bin.ccg b/gtk/src/bin.ccg
index 50d6b3b..7e256d5 100644
--- a/gtk/src/bin.ccg
+++ b/gtk/src/bin.ccg
@@ -55,7 +55,6 @@ Bin::add_pixlabel(const std::string& pixfile,
   auto hbox = manage(new Box(ORIENTATION_HORIZONTAL, 5));
   hbox->pack_start(*pmap, PACK_SHRINK);
   hbox->pack_start(*label);
-  hbox->show_all();
 
   //And put that Box in this:
   add(*hbox);
diff --git a/gtk/src/combobox.ccg b/gtk/src/combobox.ccg
index 30ba714..4cc31b9 100644
--- a/gtk/src/combobox.ccg
+++ b/gtk/src/combobox.ccg
@@ -17,7 +17,6 @@
  */
 
 #include <gtkmm/liststore.h>
-#include <gtkmm/cellrenderertext.h>
 #include <gtkmm/treeview_private.h> //For SignalProxy_RowSeparator.
 #include <gtk/gtk.h>
 
@@ -34,11 +33,6 @@ ComboBox::ComboBox(const Glib::RefPtr<TreeModel>& model, bool has_entry)
   _CONSTRUCT("model", Glib::unwrap(model), "has-entry", gboolean(has_entry))
 {}
 
-ComboBox::ComboBox(const Glib::RefPtr<CellArea>& cell_area, bool has_entry)
-:
-  _CONSTRUCT("cell-area", Glib::unwrap(cell_area), "has-entry", gboolean(has_entry))
-{}
-
 void ComboBox::unset_active()
 {
   gtk_combo_box_set_active(gobj(), -1 /* see GTK+ docs */);
diff --git a/gtk/src/combobox.hg b/gtk/src/combobox.hg
index f8ddc13..7bac1f6 100644
--- a/gtk/src/combobox.hg
+++ b/gtk/src/combobox.hg
@@ -20,8 +20,6 @@
 #include <gtkmm/celllayout.h>
 #include <gtkmm/celleditable.h>
 #include <gtkmm/treemodel.h>
-#include <gtkmm/cellarea.h>
-#include <gtkmm/cellrenderer.h>
 #include <gtkmm/treeview.h>
 #include <gtkmm/enums.h> //For SensitivityType.
 
@@ -81,13 +79,6 @@ public:
    */
   explicit ComboBox(const Glib::RefPtr<TreeModel>& model, bool has_entry = false);
   _IGNORE(gtk_combo_box_new_with_model, gtk_combo_box_new_with_model_and_entry)
-
-  /** Creates a new empty ComboBox using @a cell_area to layout cells, optionally with an entry.
-   * @param cell_area The CellArea to use to layout cell renderers.
-   * @param has_entry If this is true then this will have an Entry widget.
-   */
-  explicit ComboBox(const Glib::RefPtr<CellArea>& cell_area, bool has_entry = false);
-  _IGNORE(gtk_combo_box_new_with_area, gtk_combo_box_new_with_area_and_entry)
   _IGNORE(gtk_combo_box_new)
 
   _WRAP_METHOD(void set_wrap_width(int width), gtk_combo_box_set_wrap_width)
@@ -211,7 +202,6 @@ public:
   _WRAP_PROPERTY("popup-shown", bool)
   _WRAP_PROPERTY("button-sensitivity", SensitivityType)
   _WRAP_PROPERTY("popup-fixed-width", bool)
-  _WRAP_PROPERTY("cell-area", Glib::RefPtr<CellArea>)
   _WRAP_PROPERTY("has-entry", bool)
   _WRAP_PROPERTY("entry-text-column", int)
   _WRAP_PROPERTY("id-column", int)
diff --git a/gtk/src/container.ccg b/gtk/src/container.ccg
index c705d35..1d525c7 100644
--- a/gtk/src/container.ccg
+++ b/gtk/src/container.ccg
@@ -283,20 +283,6 @@ std::vector<const Widget*> Container::get_focus_chain() const
   return Glib::ListHandler<const Widget*>::list_to_vector(list, Glib::OWNERSHIP_SHALLOW);
 }
 
-
-void Container::show_all_children(bool recursive)
-{
-  // Plain C version if this turns out to be performance-critical:
-  //GtkCallback callback = (GtkCallback) ((recursive) ? &gtk_widget_show_all : &gtk_widget_show);
-  //gtk_container_foreach(gobj(), callback, 0);
-
-  // This could also be done with get_children() and an explicit loop,
-  // if any problems should arise.  In gtkmm-1.2, foreach() is known to
-  // cause segfaults eventually, but it seems to work now.
-
-  foreach(sigc::mem_fun((recursive) ? &Widget::show_all : &Widget::show));
-}
-
 void Container::remove(Widget& widget)
 {
   auto child_to_float = &widget;
diff --git a/gtk/src/container.hg b/gtk/src/container.hg
index 47436ee..17d38ce 100644
--- a/gtk/src/container.hg
+++ b/gtk/src/container.hg
@@ -169,8 +169,6 @@ public:
   _WRAP_SIGNAL(void check_resize(), "check_resize")
   _WRAP_SIGNAL(void set_focus_child(Widget* widget), "set_focus_child")
 
-  void show_all_children(bool recursive = true);
-
 protected:
   _CTOR_DEFAULT()
 
diff --git a/gtk/src/main.ccg b/gtk/src/main.ccg
index 797b388..e87723c 100644
--- a/gtk/src/main.ccg
+++ b/gtk/src/main.ccg
@@ -40,24 +40,9 @@ Main*         Main::instance_ = nullptr;
 
 /**** Gtk::Main -- construction/destruction ********************************/
 
-Main::Main(int& argc, char**& argv, bool set_locale)
-{
-  init(&argc, &argv, set_locale);
-}
-
-Main::Main(int* argc, char*** argv, bool set_locale)
-{
-  init(argc, argv, set_locale);
-}
-
-/*Main::Main(int* argc, char*** argv, const std::string& parameter_string, const std::vector<const 
Glib::OptionEntry&>& entries, const std::string& translation_domain)
-{
-  init(argc, argv, parameter_string, entries, translation_domain);
-}*/
-
 Main::Main(bool set_locale)
 {
-  init(nullptr, nullptr, set_locale);
+  init(set_locale);
 }
 
 Main::~Main()
@@ -76,7 +61,7 @@ Main::~Main()
 }
 
 // protected
-void Main::init(int* argc, char*** argv, bool set_locale)
+void Main::init(bool set_locale)
 {
   if(instance_)
   {
@@ -88,33 +73,13 @@ void Main::init(int* argc, char*** argv, bool set_locale)
       gtk_disable_setlocale();
 
     //TODO: Add support for gtk_init_check().
-    gtk_init(argc, argv);
+    gtk_init();
 
     init_gtkmm_internals();
     instance_ = this;
   }
 }
 
-Main::Main(int& argc, char**& argv, Glib::OptionContext& option_context)
-{
-  if(instance_)
-  {
-    g_warning("Gtk::Main::init() called twice");
-  }
-  else
-  {
-    init_gtkmm_internals();
-    instance_ = this;
-
-    //This reimplements some stuff from gtk_init_with_options(),
-    //without calling check_setugid(), because that is not public API.
-
-    add_gtk_option_group(option_context);
-
-    option_context.parse(argc, argv);
-  }
-}
-
 _DEPRECATE_IFDEF_END
 
 // This is a static method so that it can be used before Main is instantiated,
@@ -144,15 +109,6 @@ void Main::init_gtkmm_internals()
   }
 }
 
-void Main::add_gtk_option_group(Glib::OptionContext& option_context, bool open_default_display)
-{
-  //Get the option group:
-  Glib::OptionGroup gtkgroup( gtk_get_option_group(open_default_display) ); //Takes ownership of the 
GOptionGroup.
-
-  //Give it to the option_context, which will also then own the underlying GOptionGroup, deleting it when 
necessary:
-  option_context.add_group(gtkgroup);
-}
-
 _DEPRECATE_IFDEF_START
 
 /**** Gtk::Main -- static forwarder methods ********************************/
diff --git a/gtk/src/main.hg b/gtk/src/main.hg
index cbd163d..a528c18 100644
--- a/gtk/src/main.hg
+++ b/gtk/src/main.hg
@@ -53,7 +53,7 @@ class Window;
  * @code
  * int main(int argc, char *argv[])
  * {
- *   Gtk::Main kit(argc, argv);
+ *   Gtk::Main kit();
  *   ... create some widgets and windows...
  *   kit.run(window);
  * }
@@ -66,62 +66,6 @@ class Main : public sigc::trackable
 public:
 
 _DEPRECATE_IFDEF_START
-  //This offers the same functionality as gtk_init_with_args():
-  /** Scans the argument vector, and strips off all parameters parsed by GTK+ or your @a option_context.
-   * Add a Glib::OptionGroup to the Glib::OptionContext to parse your own command-line arguments.
-   *
-   * Note:  The argument strings themself won't be modified, although the
-   * pointers to them might change.  This makes it possible to create your
-   * own argv of string literals, which have the type 'const char[]' in
-   * standard C++.  (You might need to use const_cast<>, though.)
-   *
-   * This function automatically generates nicely formatted
-   * <tt>--help</tt> output. Note that your program will
-   * be terminated after writing out the help output.
-   *
-   * @param argc a reference to the number of command line arguments.
-   * @param argv a reference to the array of command line arguments.
-   * @param option_context A Glib::OptionContext containing Glib::OptionGroups which described the 
command-line arguments taken by your program.
-   *
-   * @throw Glib::OptionError
-   *
-   * @deprecated Use Gtk::Application instead.
-   */
-  Main(int& argc, char**& argv, Glib::OptionContext& option_context);
-
-  /** Scans the argument vector, and strips off all parameters known to GTK+.
-   * Your application may then handle the remaining arguments.
-   *
-   * Note:  The argument strings themself won't be modified, although the
-   * pointers to them might change.  This makes it possible to create your
-   * own argv of string literals, which have the type 'const char[]' in
-   * standard C++.  (You might need to use const_cast<>, though.)
-   *
-   * @param argc a pointer to the number of command line arguments.
-   * @param argv a pointer to the array of command line arguments.
-   * @param set_locale Passing false prevents GTK+ from automatically calling
-   * setlocale(LC_ALL, ""). You would want to pass false if you wanted to set
-   * the locale for your program to something other than the user's locale, or
-   * if you wanted to set different values for different locale categories.
-   *
-   * @deprecated Use Gtk::Application instead.
-   */
-  Main(int* argc, char*** argv, bool set_locale = true);
-
-  /** Scans the argument vector, and strips off all parameters known to GTK+.
-   * Your application may then handle the remaining arguments.
-   *
-   * @param argc a reference to the number of command line arguments.
-   * @param argv a reference to the array of command line arguments.
-   * @param set_locale Passing false prevents GTK+ from automatically calling
-   * setlocale(LC_ALL, ""). You would want to pass false if you wanted to set
-   * the locale for your program to something other than the user's locale, or
-   * if you wanted to set different values for different locale categories.
-   *
-   * @deprecated Use Gtk::Application instead.
-   */
-  Main(int& argc, char**& argv, bool set_locale = true);
-
   /** Initialization without command-line arguments.
    *
    * @param set_locale Passing false prevents GTK+ from automatically calling
@@ -180,22 +124,6 @@ _DEPRECATE_IFDEF_END
   //one day when Gtk::Application can really do everything, which should probably
   //include handling OptionContext properly. murrayc.
 
-  //This attempts to provide the same functionality as gtk_get_option_group():
-  /** Add a Glib::OptionGroup, for the commandline arguments recognized
-   * by GTK+ and GDK, to a Glib::OptionContext, so that these commandline arguments will
-   * be processed in addition to the existing commandline arguments specified by the Glib::OptionContext.
-   *
-   * You do not need to use this method if you pass your Glib::OptionContext to the Main constructor, because
-   * it adds the gtk option group automatically.
-   *
-   * @param option_context Option Context to which the group will be added.
-   * @param open_default_display Whether to open the default display when parsing the commandline arguments.
-   *
-   * @deprecated Use Gtk::Application instead.
-   */
-  static void add_gtk_option_group(Glib::OptionContext& option_context, bool open_default_display = true);
-
-
   /** Runs a single iteration of the main loop.
    * If no events are waiting to be processed GTK+ will block until the next event is noticed.
    * If you don't want to block then pass false for @a blocking or check if any events are pending with
@@ -230,9 +158,7 @@ _DEPRECATE_IFDEF_END
 protected:
 
 _DEPRECATE_IFDEF_START
-  void init(int* argc, char*** argv, bool set_locale);
-  // TODO: implement this to use the new Glib::OptionEntry argument parsing classes.
-  //void init(int* argc, char*** argv, const std::string& parameter_string, const std::vector<const 
Glib::OptionEntry&>& entries, const std::string& translation_domain);
+  void init(bool set_locale);
 
   virtual void run_impl();
   virtual void quit_impl();
diff --git a/gtk/src/widget.hg b/gtk/src/widget.hg
index c8bf4c6..6f10920 100644
--- a/gtk/src/widget.hg
+++ b/gtk/src/widget.hg
@@ -114,8 +114,6 @@ public:
   _WRAP_METHOD(void show_now(), gtk_widget_show_now)
   _WRAP_METHOD(void hide(), gtk_widget_hide)
 
-  _WRAP_METHOD(void show_all(), gtk_widget_show_all)
-
 /* QUEUE DRAWS */
 
   _WRAP_METHOD(void queue_draw(), gtk_widget_queue_draw)
@@ -464,8 +462,6 @@ public:
 
   _WRAP_METHOD(void queue_resize_no_redraw(), gtk_widget_queue_resize_no_redraw)
   //TODO: _WRAP_METHOD(GdkFrameClock* get_frame_clock(), gtk_widget_get_frame_clock)
-  _WRAP_METHOD(bool get_no_show_all() const, gtk_widget_get_no_show_all)
-  _WRAP_METHOD(void set_no_show_all(bool no_show_all = true), gtk_widget_set_no_show_all)
 
   //Used when implementing containers:
   _WRAP_METHOD(void set_parent(Widget& parent), gtk_widget_set_parent)
@@ -696,7 +692,6 @@ _CONVERSION(`GdkScreen*',`const Glib::RefPtr<Gdk::Screen>&',`Glib::wrap($3, true
   _WRAP_PROPERTY("tooltip_markup", Glib::ustring)
   _WRAP_PROPERTY("tooltip_text", Glib::ustring)
   _WRAP_PROPERTY("window", Glib::RefPtr<Gdk::Window>)
-  _WRAP_PROPERTY("no-show-all", bool)
 
   _WRAP_PROPERTY("halign", Align)
   _WRAP_PROPERTY("valign", Align)
@@ -718,7 +713,6 @@ protected:
   //comment in GTK+ header: "seldomly overidden"
   _WRAP_VFUNC(void dispatch_child_properties_changed(guint, GParamSpec**), 
"dispatch_child_properties_changed")
 
-  _WRAP_VFUNC(void show_all(), "show_all")
   _WRAP_VFUNC(Glib::RefPtr<Atk::Object> get_accessible(), "get_accessible", refreturn, ifdef 
GTKMM_ATKMM_ENABLED)
 
   _WRAP_VFUNC(SizeRequestMode get_request_mode() const, get_request_mode)
diff --git a/tests/child_widget/testwindow.cc b/tests/child_widget/testwindow.cc
index 6d7b0c0..6c06596 100644
--- a/tests/child_widget/testwindow.cc
+++ b/tests/child_widget/testwindow.cc
@@ -1,5 +1,3 @@
-//$Id$ -*- c++ -*-
-
 /* gtkmm example Copyright (C) 2002 gtkmm development team
  *
  * This program is free software; you can redistribute it and/or modify
@@ -23,8 +21,6 @@ TestWindow::TestWindow()
 {
   add(m_Button);
 
-  show_all_children();
-
   //This seems to be 2, and then 3 during destruction. Looks like unref-ing isn't enough - we'll have to 
gtk_object_destroy() it instead of just unrefing.
   g_warning("m_Button -> refcount = %d\n", G_OBJECT(m_Button.gobj())->ref_count);
 }
diff --git a/tests/child_widget2/main.cc b/tests/child_widget2/main.cc
index e92951f..d678ea2 100644
--- a/tests/child_widget2/main.cc
+++ b/tests/child_widget2/main.cc
@@ -15,7 +15,6 @@ MyWindow::MyWindow() :
 {
   add(vbox);
   vbox.pack_start(b);
-  show_all_children();
 }
 
 int main (int argc, char *argv[])
diff --git a/tests/child_widget_managed/main.cc b/tests/child_widget_managed/main.cc
index 04895ce..cf5ecd5 100644
--- a/tests/child_widget_managed/main.cc
+++ b/tests/child_widget_managed/main.cc
@@ -33,8 +33,6 @@ ExampleWindow::ExampleWindow()
 
     m_button = manage(new MyButton);
     add(*m_button);
-
-    show_all_children();
 }
 
 ExampleWindow::~ExampleWindow()
diff --git a/tests/delete_cpp_child/main.cc b/tests/delete_cpp_child/main.cc
index 72ae7fb..dc7daf2 100644
--- a/tests/delete_cpp_child/main.cc
+++ b/tests/delete_cpp_child/main.cc
@@ -34,8 +34,6 @@ AppWindow::AppWindow()
     g_warning("m_label -> ref_count: %d\n", G_OBJECT(m_label->gobj())->ref_count);
 
     button->signal_clicked().connect( sigc::mem_fun(*this, &AppWindow::on_button_clicked));
-
-    show_all_children();
 }
 
 void AppWindow::on_button_clicked()
diff --git a/tests/dialog/main.cc b/tests/dialog/main.cc
index 9d2e097..4ece208 100644
--- a/tests/dialog/main.cc
+++ b/tests/dialog/main.cc
@@ -34,8 +34,6 @@ AppWindow::AppWindow()
     g_warning("m_label -> ref_count: %d\n", G_OBJECT(m_label->gobj())->ref_count);
 
     button->signal_clicked ().connect( sigc::mem_fun(*this, &AppWindow::on_button_clicked) );
-
-    show_all_children();
 }
 
 void AppWindow::on_button_clicked()
diff --git a/tests/dialog_deletethis/main.cc b/tests/dialog_deletethis/main.cc
index ad0f39c..99fce4c 100644
--- a/tests/dialog_deletethis/main.cc
+++ b/tests/dialog_deletethis/main.cc
@@ -15,7 +15,6 @@ class Dlg : public sigc::trackable
       dlg_->get_content_area()->pack_start(*btn);
       dlg_->add_button("_OK", Gtk::RESPONSE_OK);
       dlg_->signal_response().connect(sigc::mem_fun(*this, &Dlg::on_response));
-      dlg_->show_all();
     }
 
     ~Dlg()
diff --git a/tests/object_move/main.cc b/tests/object_move/main.cc
index ad7e246..ff44db7 100644
--- a/tests/object_move/main.cc
+++ b/tests/object_move/main.cc
@@ -63,9 +63,9 @@ void test_object_move_assignment_operator()
   g_assert(derived.gobj() == nullptr);
 }
 
-int main(int argc, char** argv)
+int main(int /* argc */, char** /* argv */)
 {
-  gtk_init(&argc, &argv);
+  gtk_init();
   Gtk::Main::init_gtkmm_internals();
 
   test_object_move_constructor();
diff --git a/tests/refcount_dialog/main.cc b/tests/refcount_dialog/main.cc
index 49a37ef..f821f45 100644
--- a/tests/refcount_dialog/main.cc
+++ b/tests/refcount_dialog/main.cc
@@ -33,8 +33,6 @@ MyWindow::MyWindow()
   m_Button.signal_clicked().connect( sigc::mem_fun(*this, &MyWindow::on_button_clicked) );
   m_Box.pack_start(m_Button);
   add(m_Box);
-
-  show_all_children();
 }
 
 void MyWindow::on_button_clicked()


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]