diff options
| author | Marc Jeanmougin <marc@jeanmougin.fr> | 2017-07-28 22:05:28 +0000 |
|---|---|---|
| committer | Marc Jeanmougin <marc@jeanmougin.fr> | 2017-07-28 22:05:28 +0000 |
| commit | 3eb67b103fe69a3b42ec16d085a2cb3a58a596b7 (patch) | |
| tree | 986b33696b0a7f229589b85bd13e6fdb2cbd022a /src/ui/dialog/document-properties.cpp | |
| parent | fix typo, update CI (diff) | |
| parent | Show a control point for the center of a spiral (diff) | |
| download | inkscape-3eb67b103fe69a3b42ec16d085a2cb3a58a596b7.tar.gz inkscape-3eb67b103fe69a3b42ec16d085a2cb3a58a596b7.zip | |
Merge gitlab.com:inkscape/inkscape
Diffstat (limited to 'src/ui/dialog/document-properties.cpp')
| -rw-r--r-- | src/ui/dialog/document-properties.cpp | 58 |
1 files changed, 38 insertions, 20 deletions
diff --git a/src/ui/dialog/document-properties.cpp b/src/ui/dialog/document-properties.cpp index 7d51653db..2765e63f4 100644 --- a/src/ui/dialog/document-properties.cpp +++ b/src/ui/dialog/document-properties.cpp @@ -207,7 +207,7 @@ DocumentProperties::~DocumentProperties() * widget in columns 2-3; (non-0, 0) means label in columns 1-3; and * (non-0, non-0) means two widgets in columns 2 and 3. */ -inline void attach_all(Gtk::Grid &table, Gtk::Widget *const arr[], unsigned const n, int start = 0, int docum_prop_flag = 0) +inline void attach_all(Gtk::Grid &table, Gtk::Widget *const arr[], unsigned const n, int start = 0, int docum_prop_flag = 0, bool indent = false) { for (unsigned i = 0, r = start; i < n; i += 2) { if (arr[i] && arr[i+1]) { @@ -226,7 +226,7 @@ inline void attach_all(Gtk::Grid &table, Gtk::Widget *const arr[], unsigned cons } if (docum_prop_flag) { // this sets the padding for subordinate widgets on the "Page" page - if( i==(n-8) || i==(n-10) ) { + if( indent && (i==(n-6) || i==(n-4) || i==(n-2)) ) { arr[i+1]->set_hexpand(); #if WITH_GTKMM_3_12 arr[i+1]->set_margin_start(20); @@ -305,29 +305,47 @@ void DocumentProperties::build_page() Gtk::Widget *const widget_array[] = { - label_gen, 0, - 0, &_rum_deflt, - //label_col, 0, - //_rcp_bg._label, &_rcp_bg, - 0, 0, - label_for, 0, - 0, &_page_sizer, - 0, 0, - label_bkg, 0, - 0, &_rcb_checkerboard, - _rcp_bg._label, &_rcp_bg, - label_bdr, 0, - 0, &_rcb_canb, - 0, &_rcb_bord, - 0, &_rcb_shad, - _rcp_bord._label, &_rcp_bord, - label_dsp, 0, - 0, &_rcb_antialias, + label_gen, 0, + 0, &_rum_deflt, + //label_col, 0, + //_rcp_bg._label, &_rcp_bg, + 0, 0, + label_for, 0, + 0, &_page_sizer, + 0, 0, + &_rcb_doc_props_left, &_rcb_doc_props_right, }; + attach_all(_page_page->table(), widget_array, G_N_ELEMENTS(widget_array),0,1); + _rcp_bg_col.pack_start(*_rcp_bg._label, false, false, 2); + _rcp_bg_col.pack_start(_rcp_bg, false, false, 2); + Gtk::Widget *const widget_array_left[] = + { + label_bkg, 0, + 0, &_rcb_checkerboard, + 0, &_rcp_bg_col, + label_dsp, 0, + 0, &_rcb_antialias, + }; + + attach_all(_rcb_doc_props_left, widget_array_left, G_N_ELEMENTS(widget_array_left),0,1); + _rcp_bord_col.pack_start(*_rcp_bord._label, false, false, 2); + _rcp_bord_col.pack_start(_rcp_bord, false, false, 2); + Gtk::Widget *const widget_array_right[] = + { + label_bdr, 0, + 0, &_rcb_canb, + 0, &_rcb_bord, + 0, &_rcb_shad, + 0, &_rcp_bord_col, + }; + + attach_all(_rcb_doc_props_right, widget_array_right, G_N_ELEMENTS(widget_array_right),0,1, true); + std::list<Gtk::Widget*> _slaveList; _slaveList.push_back(&_rcb_bord); _slaveList.push_back(&_rcb_shad); + _slaveList.push_back(&_rcp_bord_col); _rcb_canb.setSlaveWidgets(_slaveList); attach_all(_page_page->table(), widget_array, G_N_ELEMENTS(widget_array),0,1); |
