diff options
author | Carl Hetherington <carl@carlh.net> | 2011-09-19 21:14:59 +0000 |
---|---|---|
committer | Carl Hetherington <carl@carlh.net> | 2011-09-19 21:14:59 +0000 |
commit | 3f6ec53ba3f30d4dc8ceeb0b44752eec0d4a2d21 (patch) | |
tree | 5873be33e533ac4b25ed7a27869373a145106576 | |
parent | 6ab6ad5bb732512d04593b1a5d566d5e787d45ed (diff) |
Tidy up style of a few toggle buttons (#4319).
git-svn-id: svn://localhost/ardour2/branches/3.0@10097 d708f5d6-7413-0410-9779-e7cbd77b26cf
-rw-r--r-- | gtk2_ardour/ardour3_styles.rc.in | 5 | ||||
-rw-r--r-- | gtk2_ardour/ardour3_widget_list.rc | 4 | ||||
-rw-r--r-- | gtk2_ardour/editor.cc | 1 | ||||
-rw-r--r-- | gtk2_ardour/editor.h | 2 | ||||
-rw-r--r-- | gtk2_ardour/editor_route_groups.cc | 3 | ||||
-rw-r--r-- | gtk2_ardour/editor_route_groups.h | 5 | ||||
-rw-r--r-- | gtk2_ardour/port_insert_ui.cc | 2 | ||||
-rw-r--r-- | gtk2_ardour/port_insert_ui.h | 3 |
8 files changed, 21 insertions, 4 deletions
diff --git a/gtk2_ardour/ardour3_styles.rc.in b/gtk2_ardour/ardour3_styles.rc.in index 0a9f14d809..5607e7c7df 100644 --- a/gtk2_ardour/ardour3_styles.rc.in +++ b/gtk2_ardour/ardour3_styles.rc.in @@ -1082,3 +1082,8 @@ style "tooltip" = "medium_text" bg[NORMAL] = @@COLPREFIX@_bg_tooltip } +style "default_toggle_button" +{ + bg[ACTIVE] = @@COLPREFIX@_contrasting_indicator + fg[ACTIVE] = @@COLPREFIX@_darkest +} diff --git a/gtk2_ardour/ardour3_widget_list.rc b/gtk2_ardour/ardour3_widget_list.rc index c8fa928e9d..d6d5ec8c03 100644 --- a/gtk2_ardour/ardour3_widget_list.rc +++ b/gtk2_ardour/ardour3_widget_list.rc @@ -318,6 +318,7 @@ widget "*PluginSaveButton*" style:highest "small_button" widget "*PluginEditButton*" style:highest "small_button" widget "*PluginLoadButton" style:highest "small_button" widget "*PluginLoadButton*" style:highest "small_button" +widget "*PluginEditorButton" style:highest "default_toggle_button" widget "*MetricDialogFrame" style:highest "base_frame" widget "*MetricEntry" style:highest "medium_bold_entry" @@ -403,3 +404,6 @@ widget "*RouteNameEditorEntry" style:highest "text_cell_entry" widget "*RegionNameEditorEntry" style:highest "text_cell_entry" widget "*MixerMidiInputEnableButton" style:highest "mouse_mode_button" widget "*InsertTimeClock" style:highest "default_clock_display" +widget "*EditorRouteGroupsAllGroupButton" style:highest "default_toggle_button" +widget "*MidiSoundNotesButton" style:highest "default_toggle_button" +widget "*MeasureLatencyButton" style:highest "default_toggle_button" diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc index 5be3f245c7..c6164a707f 100644 --- a/gtk2_ardour/editor.cc +++ b/gtk2_ardour/editor.cc @@ -3016,6 +3016,7 @@ Editor::setup_midi_toolbar () /* Midi sound notes */ midi_sound_notes.add (*(manage (new Image (::get_icon("midi_sound_notes"))))); midi_sound_notes.unset_flags (CAN_FOCUS); + midi_sound_notes.set_name (X_("MidiSoundNotesButton")); /* Panic */ diff --git a/gtk2_ardour/editor.h b/gtk2_ardour/editor.h index b3dac8c49a..ffc9534809 100644 --- a/gtk2_ardour/editor.h +++ b/gtk2_ardour/editor.h @@ -1603,7 +1603,7 @@ class Editor : public PublicEditor, public PBD::ScopedConnectionList, public ARD Gtk::HBox panic_box; Gtk::Button midi_panic_button; - Gtk::ToggleButton midi_sound_notes; + Gtkmm2ext::StatefulToggleButton midi_sound_notes; void midi_panic (); bool sound_notes () const { return midi_sound_notes.get_active(); } diff --git a/gtk2_ardour/editor_route_groups.cc b/gtk2_ardour/editor_route_groups.cc index 7bcf5008ee..613f140a8e 100644 --- a/gtk2_ardour/editor_route_groups.cc +++ b/gtk2_ardour/editor_route_groups.cc @@ -38,6 +38,7 @@ #include "route_time_axis.h" #include "editor_routes.h" #include "editor_route_groups.h" +#include "ardour_ui.h" #include "ardour/route.h" #include "ardour/session.h" @@ -146,6 +147,8 @@ EditorRouteGroups::EditorRouteGroups (Editor* e) _display_packer.pack_start (*button_box, false, false); _all_group_active_button.signal_toggled().connect (sigc::mem_fun (*this, &EditorRouteGroups::all_group_toggled)); + _all_group_active_button.set_name (X_("EditorRouteGroupsAllGroupButton")); + ARDOUR_UI::instance()->set_tip (_all_group_active_button, _("Activate this button to operate on all tracks when none are selected.")); } void diff --git a/gtk2_ardour/editor_route_groups.h b/gtk2_ardour/editor_route_groups.h index ea3a7f2b85..e413565e35 100644 --- a/gtk2_ardour/editor_route_groups.h +++ b/gtk2_ardour/editor_route_groups.h @@ -17,6 +17,7 @@ */ +#include "gtkmm2ext/stateful_button.h" #include "editor_component.h" class EditorRouteGroups : public EditorComponent, public ARDOUR::SessionHandlePtr @@ -31,7 +32,7 @@ public: } void clear (); - Gtk::ToggleButton& all_group_active_button() { return _all_group_active_button; } + Gtkmm2ext::StatefulToggleButton& all_group_active_button() { return _all_group_active_button; } private: @@ -84,7 +85,7 @@ private: Gtk::TreeView _display; Gtk::ScrolledWindow _scroller; Gtk::VBox _display_packer; - Gtk::ToggleButton _all_group_active_button; + Gtkmm2ext::StatefulToggleButton _all_group_active_button; bool _in_row_change; bool _in_rebuild; PBD::ScopedConnectionList _property_changed_connections; diff --git a/gtk2_ardour/port_insert_ui.cc b/gtk2_ardour/port_insert_ui.cc index 24b94f9bdd..8379d1a4ed 100644 --- a/gtk2_ardour/port_insert_ui.cc +++ b/gtk2_ardour/port_insert_ui.cc @@ -50,6 +50,7 @@ PortInsertUI::PortInsertUI (Gtk::Window* parent, ARDOUR::Session* sess, boost::s { latency_hbox.pack_start (latency_button, false, false); latency_hbox.pack_start (latency_display, false, false); + latency_hbox.set_spacing (4); output_selector.set_min_height_divisor (2); input_selector.set_min_height_divisor (2); @@ -66,6 +67,7 @@ PortInsertUI::PortInsertUI (Gtk::Window* parent, ARDOUR::Session* sess, boost::s update_latency_display (); latency_button.signal_toggled().connect (mem_fun (*this, &PortInsertUI::latency_button_toggled)); + latency_button.set_name (X_("MeasureLatencyButton")); } void diff --git a/gtk2_ardour/port_insert_ui.h b/gtk2_ardour/port_insert_ui.h index 820fd75629..d130ea16be 100644 --- a/gtk2_ardour/port_insert_ui.h +++ b/gtk2_ardour/port_insert_ui.h @@ -20,6 +20,7 @@ #ifndef __gtkardour_port_insert_ui_h__ #define __gtkardour_port_insert_ui_h__ +#include "gtkmm2ext/stateful_button.h" #include "ardour_dialog.h" #include "io_selector.h" @@ -39,7 +40,7 @@ class PortInsertUI : public Gtk::VBox boost::shared_ptr<ARDOUR::PortInsert> _pi; Gtk::Notebook notebook; - Gtk::ToggleButton latency_button; + Gtkmm2ext::StatefulToggleButton latency_button; IOSelector input_selector; IOSelector output_selector; Gtk::Label latency_display; |