diff options
| author | Alex Valavanis <valavanisalex@gmail.com> | 2013-03-08 01:44:43 +0000 |
|---|---|---|
| committer | Alex Valavanis <valavanisalex@gmail.com> | 2013-03-08 01:44:43 +0000 |
| commit | 1d3f07d09370bf8fefa7968706375ae3669dbd1c (patch) | |
| tree | 04210cdc85a6f90f3db35e45b06aeb8d2435b550 /src | |
| parent | Drop more Gtk::Table usage (diff) | |
| download | inkscape-1d3f07d09370bf8fefa7968706375ae3669dbd1c.tar.gz inkscape-1d3f07d09370bf8fefa7968706375ae3669dbd1c.zip | |
Drop deprecated get_vbox method in Gtk::Dialog
(bzr r12181)
Diffstat (limited to 'src')
| -rw-r--r-- | src/extension/error-file.cpp | 4 | ||||
| -rw-r--r-- | src/extension/implementation/script.cpp | 4 | ||||
| -rw-r--r-- | src/extension/internal/pdf-input-cairo.cpp | 8 | ||||
| -rw-r--r-- | src/extension/internal/pdfinput/pdf-input.cpp | 8 | ||||
| -rw-r--r-- | src/extension/prefdialog.cpp | 15 | ||||
| -rw-r--r-- | src/ui/dialog/aboutbox.cpp | 9 | ||||
| -rw-r--r-- | src/ui/dialog/calligraphic-profile-rename.cpp | 5 | ||||
| -rw-r--r-- | src/ui/dialog/debug.cpp | 4 | ||||
| -rw-r--r-- | src/ui/dialog/floating-behavior.cpp | 8 | ||||
| -rw-r--r-- | src/ui/dialog/guides.cpp | 4 | ||||
| -rw-r--r-- | src/ui/dialog/layer-properties.cpp | 4 | ||||
| -rw-r--r-- | src/ui/dialog/livepatheffect-add.cpp | 5 | ||||
| -rw-r--r-- | src/ui/widget/color-picker.cpp | 6 |
13 files changed, 79 insertions, 5 deletions
diff --git a/src/extension/error-file.cpp b/src/extension/error-file.cpp index 2a56f55e8..778295f47 100644 --- a/src/extension/error-file.cpp +++ b/src/extension/error-file.cpp @@ -56,7 +56,11 @@ ErrorFileNotice::ErrorFileNotice (void) : g_free(ext_error_file); set_message(dialog_text, true); +#if WITH_GTKMM_3_0 + Gtk::Box * vbox = get_content_area(); +#else Gtk::Box * vbox = get_vbox(); +#endif /* This is some filler text, needs to change before relase */ Inkscape::Preferences *prefs = Inkscape::Preferences::get(); diff --git a/src/extension/implementation/script.cpp b/src/extension/implementation/script.cpp index fa46569e2..3ac1e06ab 100644 --- a/src/extension/implementation/script.cpp +++ b/src/extension/implementation/script.cpp @@ -854,7 +854,11 @@ void Script::checkStderr (const Glib::ustring &data, GtkWidget *dlg = GTK_WIDGET(warning.gobj()); sp_transientize(dlg); +#if WITH_GTKMM_3_0 + Gtk::Box * vbox = warning.get_content_area(); +#else Gtk::Box * vbox = warning.get_vbox(); +#endif /* Gtk::TextView * textview = new Gtk::TextView(Gtk::TextBuffer::create()); */ Gtk::TextView * textview = new Gtk::TextView(); diff --git a/src/extension/internal/pdf-input-cairo.cpp b/src/extension/internal/pdf-input-cairo.cpp index d3c6c5931..c83ebad82 100644 --- a/src/extension/internal/pdf-input-cairo.cpp +++ b/src/extension/internal/pdf-input-cairo.cpp @@ -224,9 +224,17 @@ PdfImportCairoDialog::PdfImportCairoDialog(PopplerDocument *doc) vbox1->pack_start(*_importSettingsFrame, Gtk::PACK_EXPAND_PADDING, 0); hbox1->pack_start(*vbox1); hbox1->pack_start(*_previewArea, Gtk::PACK_EXPAND_WIDGET, 4); + +#if WITH_GTKMM_3_0 + get_content_area()->set_homogeneous(false); + get_content_area()->set_spacing(0); + get_content_area()->pack_start(*hbox1); +#else this->get_vbox()->set_homogeneous(false); this->get_vbox()->set_spacing(0); this->get_vbox()->pack_start(*hbox1); +#endif + this->set_title(_("PDF Import Settings")); this->set_modal(true); sp_transientize(GTK_WIDGET(this->gobj())); //Make transient diff --git a/src/extension/internal/pdfinput/pdf-input.cpp b/src/extension/internal/pdfinput/pdf-input.cpp index 535deafce..531cda20a 100644 --- a/src/extension/internal/pdfinput/pdf-input.cpp +++ b/src/extension/internal/pdfinput/pdf-input.cpp @@ -240,9 +240,17 @@ PdfImportDialog::PdfImportDialog(PDFDoc *doc, const gchar */*uri*/) vbox1->pack_start(*_importSettingsFrame, Gtk::PACK_EXPAND_PADDING, 0); hbox1->pack_start(*vbox1); hbox1->pack_start(*_previewArea, Gtk::PACK_EXPAND_WIDGET, 4); + +#if WITH_GTKMM_3_0 + get_content_area()->set_homogeneous(false); + get_content_area()->set_spacing(0); + get_content_area()->pack_start(*hbox1); +#else this->get_vbox()->set_homogeneous(false); this->get_vbox()->set_spacing(0); this->get_vbox()->pack_start(*hbox1); +#endif + this->set_title(_("PDF Import Settings")); this->set_modal(true); sp_transientize(GTK_WIDGET(this->gobj())); //Make transient diff --git a/src/extension/prefdialog.cpp b/src/extension/prefdialog.cpp index 649dc398a..f3c6508af 100644 --- a/src/extension/prefdialog.cpp +++ b/src/extension/prefdialog.cpp @@ -67,7 +67,12 @@ PrefDialog::PrefDialog (Glib::ustring name, gchar const * help, Gtk::Widget * co hbox->pack_start(*controls, true, true, 6); hbox->show(); + +#if WITH_GTKMM_3_0 + this->get_content_area()->pack_start(*hbox, true, true, 6); +#else this->get_vbox()->pack_start(*hbox, true, true, 6); +#endif /* Gtk::Button * help_button = add_button(Gtk::Stock::HELP, Gtk::RESPONSE_HELP); @@ -95,14 +100,24 @@ PrefDialog::PrefDialog (Glib::ustring name, gchar const * help, Gtk::Widget * co #endif sep->show(); + +#if WITH_GTKMM_3_0 + this->get_content_area()->pack_start(*sep, true, true, 4); +#else this->get_vbox()->pack_start(*sep, true, true, 4); +#endif hbox = Gtk::manage(new Gtk::HBox()); _button_preview = _param_preview->get_widget(NULL, NULL, &_signal_preview); _button_preview->show(); hbox->pack_start(*_button_preview, true, true,6); hbox->show(); + +#if WITH_GTKMM_3_0 + this->get_content_area()->pack_start(*hbox, true, true, 6); +#else this->get_vbox()->pack_start(*hbox, true, true, 6); +#endif Gtk::Box * hbox = dynamic_cast<Gtk::Box *>(_button_preview); if (hbox != NULL) { diff --git a/src/ui/dialog/aboutbox.cpp b/src/ui/dialog/aboutbox.cpp index 0c0027c15..d4928d25d 100644 --- a/src/ui/dialog/aboutbox.cpp +++ b/src/ui/dialog/aboutbox.cpp @@ -97,7 +97,12 @@ AboutBox::AboutBox() : Gtk::Dialog(_("About Inkscape")) { tabs->append_page(*manage( make_scrolled_text(license_text)), _("_License"), true); +#if WITH_GTKMM_3_0 + get_content_area()->pack_end(*manage(tabs), true, true); +#else get_vbox()->pack_end(*manage(tabs), true, true); +#endif + tabs->show_all(); add_button(Gtk::Stock::CLOSE, Gtk::RESPONSE_CLOSE); @@ -114,7 +119,11 @@ AboutBox::AboutBox() : Gtk::Dialog(_("About Inkscape")) { label->set_selectable(true); label->show(); +#if WITH_GTKMM_3_0 + get_content_area()->pack_start(*manage(label), false, false); +#else get_vbox()->pack_start(*manage(label), false, false); +#endif Gtk::Requisition requisition; #if GTK_CHECK_VERSION(3,0,0) diff --git a/src/ui/dialog/calligraphic-profile-rename.cpp b/src/ui/dialog/calligraphic-profile-rename.cpp index 77a4f4f03..da43763c8 100644 --- a/src/ui/dialog/calligraphic-profile-rename.cpp +++ b/src/ui/dialog/calligraphic-profile-rename.cpp @@ -32,7 +32,12 @@ CalligraphicProfileRename::CalligraphicProfileRename() : { set_title(_("Edit profile")); +#if WITH_GTKMM_3_0 + Gtk::Box *mainVBox = get_content_area(); +#else Gtk::Box *mainVBox = get_vbox(); +#endif + _layout_table.set_spacings(4); _layout_table.resize (1, 2); diff --git a/src/ui/dialog/debug.cpp b/src/ui/dialog/debug.cpp index 429ed57bf..e61f8e389 100644 --- a/src/ui/dialog/debug.cpp +++ b/src/ui/dialog/debug.cpp @@ -69,7 +69,11 @@ DebugDialogImpl::DebugDialogImpl() set_title(_("Messages")); set_size_request(300, 400); +#if WITH_GTKMM_3_0 + Gtk::Box *mainVBox = get_content_area(); +#else Gtk::Box *mainVBox = get_vbox(); +#endif //## Add a menu for clear() Gtk::MenuItem* item = Gtk::manage(new Gtk::MenuItem(_("_File"), true)); diff --git a/src/ui/dialog/floating-behavior.cpp b/src/ui/dialog/floating-behavior.cpp index eab5f9d8f..d70c5f187 100644 --- a/src/ui/dialog/floating-behavior.cpp +++ b/src/ui/dialog/floating-behavior.cpp @@ -135,7 +135,13 @@ FloatingBehavior::create(Dialog &dialog) inline FloatingBehavior::operator Gtk::Widget &() { return *_d; } inline GtkWidget *FloatingBehavior::gobj() { return GTK_WIDGET(_d->gobj()); } -inline Gtk::Box* FloatingBehavior::get_vbox() { return _d->get_vbox(); } +inline Gtk::Box* FloatingBehavior::get_vbox() { +#if WITH_GTKMM_3_0 + return _d->get_content_area(); +#else + return _d->get_vbox(); +#endif +} inline void FloatingBehavior::present() { _d->present(); } inline void FloatingBehavior::hide() { _d->hide(); } inline void FloatingBehavior::show() { _d->show(); } diff --git a/src/ui/dialog/guides.cpp b/src/ui/dialog/guides.cpp index d8bbb5539..06671393d 100644 --- a/src/ui/dialog/guides.cpp +++ b/src/ui/dialog/guides.cpp @@ -166,12 +166,12 @@ void GuidelinePropertiesDialog::_setup() { add_button(Gtk::Stock::DELETE, -12); add_button(Gtk::Stock::CANCEL, Gtk::RESPONSE_CANCEL); - Gtk::Box *mainVBox = get_vbox(); - #if WITH_GTKMM_3_0 + Gtk::Box *mainVBox = get_content_area(); _layout_table.set_row_spacing(4); _layout_table.set_column_spacing(4); #else + Gtk::Box *mainVBox = get_vbox(); _layout_table.set_spacings(4); _layout_table.resize (3, 4); #endif diff --git a/src/ui/dialog/layer-properties.cpp b/src/ui/dialog/layer-properties.cpp index 6a1bc829e..3feed2afe 100644 --- a/src/ui/dialog/layer-properties.cpp +++ b/src/ui/dialog/layer-properties.cpp @@ -40,12 +40,12 @@ namespace Dialogs { LayerPropertiesDialog::LayerPropertiesDialog() : _strategy(NULL), _desktop(NULL), _layer(NULL), _position_visible(false) { - Gtk::Box *mainVBox = get_vbox(); - #if WITH_GTKMM_3_0 + Gtk::Box *mainVBox = get_content_area(); _layout_table.set_row_spacing(4); _layout_table.set_column_spacing(4); #else + Gtk::Box *mainVBox = get_vbox(); _layout_table.set_spacings(4); _layout_table.resize (1, 2); #endif diff --git a/src/ui/dialog/livepatheffect-add.cpp b/src/ui/dialog/livepatheffect-add.cpp index e899dbcfc..b5f51d81d 100644 --- a/src/ui/dialog/livepatheffect-add.cpp +++ b/src/ui/dialog/livepatheffect-add.cpp @@ -73,7 +73,12 @@ LivePathEffectAdd::LivePathEffectAdd() : add_button.set_use_underline(true); add_button.set_can_default(); +#if WITH_GTKMM_3_0 + Gtk::Box *mainVBox = get_content_area(); +#else Gtk::Box *mainVBox = get_vbox(); +#endif + mainVBox->pack_start(scrolled_window, true, true); add_action_widget(close_button, Gtk::RESPONSE_CLOSE); add_action_widget(add_button, Gtk::RESPONSE_APPLY); diff --git a/src/ui/widget/color-picker.cpp b/src/ui/widget/color-picker.cpp index 31fb3096c..5585f2db4 100644 --- a/src/ui/widget/color-picker.cpp +++ b/src/ui/widget/color-picker.cpp @@ -56,8 +56,14 @@ void ColorPicker::setupDialog(const Glib::ustring &title) _colorSelectorDialog.set_title (title); _colorSelectorDialog.set_border_width (4); _colorSelector = SP_COLOR_SELECTOR(sp_color_selector_new(SP_TYPE_COLOR_NOTEBOOK)); + +#if WITH_GTKMM_3_0 + _colorSelectorDialog.get_content_area()->pack_start ( + *Glib::wrap(&_colorSelector->vbox), true, true, 0); +#else _colorSelectorDialog.get_vbox()->pack_start ( *Glib::wrap(&_colorSelector->vbox), true, true, 0); +#endif g_signal_connect(G_OBJECT(_colorSelector), "dragged", G_CALLBACK(sp_color_picker_color_mod), (void *)this); |
