View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0005331 | ardour | bugs | public | 2013-02-07 13:56 | 2013-02-07 13:58 |
Reporter | PeterN | Assigned To | |||
Priority | normal | Severity | minor | Reproducibility | always |
Status | new | Resolution | open | ||
Summary | 0005331: An open/close cycle on an LV2 UI results in an increasing gap in the window. | ||||
Description | An open/close cycle on an LV2 UI results in an increasing gap in the window caused by Ardour repacking the button widgets and box every time the window is opened. The attached patch fixes this by removing the widgets when the window is closed. | ||||
Tags | No tags attached. | ||||
2013-02-07 13:56
|
lv2ui_fix1.diff (752 bytes)
Index: gtk2_ardour/lv2_plugin_ui.cc =================================================================== --- gtk2_ardour/lv2_plugin_ui.cc (revision 14055) +++ gtk2_ardour/lv2_plugin_ui.cc (working copy) @@ -332,6 +332,18 @@ { stop_updating (0); + if (_ardour_buttons_box) { + _ardour_buttons_box->remove (focus_button); + _ardour_buttons_box->remove (bypass_button); + _ardour_buttons_box->remove (delete_button); + _ardour_buttons_box->remove (save_button); + _ardour_buttons_box->remove (add_button); + _ardour_buttons_box->remove (_preset_combo); + _ardour_buttons_box->remove (_preset_modified); + remove (*_ardour_buttons_box); + _ardour_buttons_box = NULL; + } + if (_gui_widget) { remove (*_gui_widget); _gui_widget = NULL; |
2013-02-07 13:57
|
lv2ui_fix2.diff (1,833 bytes)
Index: gtk2_ardour/lv2_plugin_ui.cc =================================================================== --- gtk2_ardour/lv2_plugin_ui.cc (revision 14055) +++ gtk2_ardour/lv2_plugin_ui.cc (working copy) @@ -219,18 +219,20 @@ features[features_count - 1] = &_external_ui_feature; features[features_count] = NULL; } else { - _ardour_buttons_box = manage (new Gtk::HBox); - _ardour_buttons_box->set_spacing (6); - _ardour_buttons_box->set_border_width (6); - _ardour_buttons_box->pack_end (focus_button, false, false); - _ardour_buttons_box->pack_end (bypass_button, false, false, 10); - _ardour_buttons_box->pack_end (delete_button, false, false); - _ardour_buttons_box->pack_end (save_button, false, false); - _ardour_buttons_box->pack_end (add_button, false, false); - _ardour_buttons_box->pack_end (_preset_combo, false, false); - _ardour_buttons_box->pack_end (_preset_modified, false, false); - _ardour_buttons_box->show_all(); - pack_start(*_ardour_buttons_box, false, false); + if (!_ardour_buttons_box) { + _ardour_buttons_box = manage (new Gtk::HBox); + _ardour_buttons_box->set_spacing (6); + _ardour_buttons_box->set_border_width (6); + _ardour_buttons_box->pack_end (focus_button, false, false); + _ardour_buttons_box->pack_end (bypass_button, false, false, 10); + _ardour_buttons_box->pack_end (delete_button, false, false); + _ardour_buttons_box->pack_end (save_button, false, false); + _ardour_buttons_box->pack_end (add_button, false, false); + _ardour_buttons_box->pack_end (_preset_combo, false, false); + _ardour_buttons_box->pack_end (_preset_modified, false, false); + _ardour_buttons_box->show_all(); + pack_start(*_ardour_buttons_box, false, false); + } _gui_widget = Gtk::manage((container = new Gtk::Alignment())); pack_start(*_gui_widget, true, true); |
|
Alternatively, the second patch fixes the issue by only packing the widgets on the first open. Both patches fix the issue individually so don't need to be applied together. |