Complete edit toolbar overhaul
authorDavid Robillard <d@drobilla.net>
Fri, 30 Jun 2006 08:03:43 +0000 (08:03 +0000)
committerDavid Robillard <d@drobilla.net>
Fri, 30 Jun 2006 08:03:43 +0000 (08:03 +0000)
git-svn-id: svn://localhost/ardour2/branches/midi@657 d708f5d6-7413-0410-9779-e7cbd77b26cf

19 files changed:
gtk2_ardour/ardour.colors
gtk2_ardour/ardour2_ui.rc
gtk2_ardour/ardour_ui.h
gtk2_ardour/ardour_ui2.cc
gtk2_ardour/editor.cc
gtk2_ardour/editor.h
gtk2_ardour/fft_graph.cc
gtk2_ardour/fft_graph.h
gtk2_ardour/pixmaps/left_arrow.xpm
gtk2_ardour/pixmaps/right_arrow.xpm
gtk2_ardour/pixmaps/tool_audition.xpm [new file with mode: 0644]
gtk2_ardour/pixmaps/tool_gain.xpm [new file with mode: 0644]
gtk2_ardour/pixmaps/tool_object.xpm [new file with mode: 0644]
gtk2_ardour/pixmaps/tool_range.xpm [new file with mode: 0644]
gtk2_ardour/pixmaps/tool_stretch.xpm [new file with mode: 0644]
gtk2_ardour/pixmaps/tool_zoom.xpm [new file with mode: 0644]
gtk2_ardour/pixmaps/zoom_full.xpm [new file with mode: 0644]
gtk2_ardour/pixmaps/zoom_in.xpm [new file with mode: 0644]
gtk2_ardour/pixmaps/zoom_out.xpm [new file with mode: 0644]

index 1e26381de5121764334839bd0f97dc6313c4d0f2..c84b2738e72283397719ac1edd853c1507ba9fcb 100644 (file)
@@ -2,9 +2,9 @@ cWaveForm 0.0 0.0 0.0 0.80
 cMutedWaveForm 0.35 0.35 0.35 1.0
 cSelectedFrameBase 0.71 0.57 0.66 1.0
 cFrameBase 0.75 0.75 0.76 1.0
-cAudioTrackBase 0.75 0.80 0.75 0.41
+cAudioTrackBase 0.75 0.75 0.85 0.41
 cAudioTrackOutline 0.00 0.00 0.00 1.00
-cAudioBusBase 0.75 0.75 0.85 0.41
+cAudioBusBase 0.75 0.80 0.75 0.41
 cMeterBar 0.40 0.40 0.40 1.0
 cTempoBar 0.45 0.45 0.45 1.0
 cMarkerBar 0.50 0.50 0.50 1.0
index ebf7e59cd8a3f1f1decf1e15583871293c50ff4d..b276e98028428707cadc0e38ec68a5265d388342 100644 (file)
@@ -882,10 +882,6 @@ widget "*ExportFileDisplay" style "medium_entry"
 widget "*ExportFormatDisplay" style "medium_entry"
 widget "*ExportCheckbox" style "small_entry"
 widget "*ExportTrackSelector*" style "medium_entry_noselection_bg"
-widget "*EditModeSelector" style "medium_bold_entry"
-widget "*SnapTypeSelector" style "medium_bold_entry"
-widget "*SnapModeSelector" style "medium_bold_entry"
-widget "*ZoomFocusSelector" style "medium_bold_entry"
 widget "*ArdourContextMenu*" style "default_buttons_menus"
 widget "*EditGroupTitleButton*" style "default_buttons_menus"
 widget "*MixerGroupTitleButton*" style "default_buttons_menus"
index 9dad6086be6f3bb5cd32f7af195b4a0582ab12d3..c2f0aaac84779324102ae559b928906065c8d2c5 100644 (file)
@@ -433,7 +433,7 @@ class ARDOUR_UI : public Gtkmm2ext::UI
        Gtk::ToggleButton solo_alert_button;
 
        Gtk::VBox alert_box;
-       
+
        void solo_blink (bool);
        void audition_blink (bool);
 
index 2b94117724d7c693c33ab2b4bcfc623c7fbe004a..663f78301bdd2fa0756c34772404a823896cb110 100644 (file)
@@ -359,8 +359,8 @@ ARDOUR_UI::setup_transport ()
        auditioning_alert_button.set_name ("TransportAuditioningAlert");
        auditioning_alert_button.signal_pressed().connect (mem_fun(*this,&ARDOUR_UI::audition_alert_toggle));
 
-       alert_box.pack_start (solo_alert_button);
-       alert_box.pack_start (auditioning_alert_button);
+       alert_box.pack_start (solo_alert_button, false, false);
+       alert_box.pack_start (auditioning_alert_button, false, false);
 
        transport_tearoff_hbox.set_border_width (4);
 
index 0e45154717060078c88596b0af58d47ea5f25ba6..733ae3a3cef63fe7101ccd7c0b19d12fdf95f684 100644 (file)
@@ -131,17 +131,17 @@ static const gchar *snap_type_strings[] = {
 };
 
 static const gchar *snap_mode_strings[] = {
-       N_("Normal"),
-       N_("Magnetic"),
+       N_("Normal Snap"),
+       N_("Magnetic Snap"),
        0
 };
 
 static const gchar *zoom_focus_strings[] = {
-       N_("Left"),
-       N_("Right"),
-       N_("Center"),
-       N_("Playhead"),
-       N_("Edit Cursor"),
+       N_("Focus Left"),
+       N_("Focus Right"),
+       N_("Focus Center"),
+       N_("Focus Play"),
+       N_("Focus Edit"),
        0
 };
 
@@ -211,30 +211,24 @@ Editor::Editor (AudioEngine& eng)
          
          toolbar_selection_clock_table (2,3),
          
-         mouse_mode_button_table (2, 3),
+         //mouse_mode_button_table (2, 3),
 
-         mouse_select_button (_("range")),
+         /*mouse_select_button (_("range")),
          mouse_move_button (_("object")),
          mouse_gain_button (_("gain")),
          mouse_zoom_button (_("zoom")),
          mouse_timefx_button (_("timefx")),
-         mouse_audition_button (_("listen")),
+         mouse_audition_button (_("listen")),*/
 
          automation_mode_button (_("mode")),
          global_automation_button (_("automation")),
 
-         edit_mode_label (_("Edit Mode")),
-         snap_type_label (_("Snap To")),
-         snap_mode_label(_("Snap Mode")),
-         zoom_focus_label (_("Zoom Focus")),
-
          /* <CMT Additions> */
          image_socket_listener(0),
          /* </CMT Additions> */
 
          /* nudge */
 
-         nudge_label (_("Nudge")),
          nudge_clock (X_("NudgeClock"), true, true)
 
 {
@@ -465,36 +459,7 @@ Editor::Editor (AudioEngine& eng)
 
        edit_packer.attach (edit_hscrollbar,         2, 3, 2, 3,    FILL|EXPAND,  FILL, 0, 0);
 
-       zoom_in_button.set_name ("EditorTimeButton");
-       zoom_out_button.set_name ("EditorTimeButton");
-       ARDOUR_UI::instance()->tooltips().set_tip (zoom_in_button, _("Zoom in"));
-       ARDOUR_UI::instance()->tooltips().set_tip (zoom_out_button, _("Zoom out"));
-
-       zoom_out_full_button.set_name ("EditorTimeButton");
-       ARDOUR_UI::instance()->tooltips().set_tip (zoom_out_full_button, _("Zoom to session"));
-
-       zoom_in_button.add (*(manage (new Image (Stock::ZOOM_IN, ICON_SIZE_BUTTON))));
-       zoom_out_button.add (*(manage (new Image (Stock::ZOOM_OUT, ICON_SIZE_BUTTON))));
-       zoom_out_full_button.add (*(manage (new Image (Stock::ZOOM_FIT, ICON_SIZE_BUTTON))));
-       
-       zoom_in_button.signal_clicked().connect (bind (mem_fun(*this, &Editor::temporal_zoom_step), false));
-       zoom_out_button.signal_clicked().connect (bind (mem_fun(*this, &Editor::temporal_zoom_step), true));
-       zoom_out_full_button.signal_clicked().connect (mem_fun(*this, &Editor::temporal_zoom_session));
-       
-       zoom_indicator_box.pack_start (zoom_out_button, false, false);
-       zoom_indicator_box.pack_start (zoom_in_button, false, false);
-       zoom_indicator_box.pack_start (zoom_range_clock, false, false); 
-       zoom_indicator_box.pack_start (zoom_out_full_button, false, false);
-       
-       zoom_indicator_label.set_text (_("Zoom Span"));
-       zoom_indicator_label.set_name ("ToolBarLabel");
-
-       zoom_indicator_vbox.set_spacing (3);
-       zoom_indicator_vbox.set_border_width (3);
-       zoom_indicator_vbox.pack_start (zoom_indicator_label, false, false);
-       zoom_indicator_vbox.pack_start (zoom_indicator_box, false, false);
-
-       bottom_hbox.set_border_width (3);
+       bottom_hbox.set_border_width (2);
        bottom_hbox.set_spacing (3);
 
        route_display_model = ListStore::create(route_display_columns);
@@ -724,8 +689,8 @@ Editor::Editor (AudioEngine& eng)
        nudge_forward_button.add (*(manage (new Image (get_xpm("right_arrow.xpm")))));
        nudge_backward_button.add (*(manage (new Image (get_xpm("left_arrow.xpm")))));
 
-       ARDOUR_UI::instance()->tooltips().set_tip (nudge_forward_button, _("Nudge region/selection forwards"));
-       ARDOUR_UI::instance()->tooltips().set_tip (nudge_backward_button, _("Nudge region/selection backwards"));
+       ARDOUR_UI::instance()->tooltips().set_tip (nudge_forward_button, _("Nudge Region/Selection Forwards"));
+       ARDOUR_UI::instance()->tooltips().set_tip (nudge_backward_button, _("Nudge Region/Selection Backwards"));
 
        nudge_forward_button.set_name ("TransportButton");
        nudge_backward_button.set_name ("TransportButton");
@@ -2585,20 +2550,33 @@ void
 Editor::setup_toolbar ()
 {
        string pixmap_path;
+
+       const guint32 FUDGE = 18; // Combo's are stupid - they steal space from the entry for the button
+
+       /* Mode Buttons (tool selection) */
+
        vector<ToggleButton *> mouse_mode_buttons;
 
+       mouse_move_button.add (*(manage (new Image (get_xpm("tool_object.xpm")))));
        mouse_mode_buttons.push_back (&mouse_move_button);
+       mouse_select_button.add (*(manage (new Image (get_xpm("tool_range.xpm")))));
        mouse_mode_buttons.push_back (&mouse_select_button);
+       mouse_gain_button.add (*(manage (new Image (get_xpm("tool_gain.xpm")))));
        mouse_mode_buttons.push_back (&mouse_gain_button);
+       mouse_zoom_button.add (*(manage (new Image (get_xpm("tool_zoom.xpm")))));
        mouse_mode_buttons.push_back (&mouse_zoom_button);
+       mouse_timefx_button.add (*(manage (new Image (get_xpm("tool_stretch.xpm")))));
        mouse_mode_buttons.push_back (&mouse_timefx_button);
+       mouse_audition_button.add (*(manage (new Image (get_xpm("tool_audition.xpm")))));
        mouse_mode_buttons.push_back (&mouse_audition_button);
+       
        mouse_mode_button_set = new GroupedButtons (mouse_mode_buttons);
 
+       /*
        mouse_mode_button_table.set_homogeneous (true);
-       mouse_mode_button_table.set_col_spacings (2);
-       mouse_mode_button_table.set_row_spacings (2);
-       mouse_mode_button_table.set_border_width (5);
+       mouse_mode_button_table.set_col_spacings (1);
+       mouse_mode_button_table.set_row_spacings (1);
+       mouse_mode_button_table.set_border_width (2);
 
        mouse_mode_button_table.attach (mouse_move_button, 0, 1, 0, 1);
        mouse_mode_button_table.attach (mouse_select_button, 1, 2, 0, 1);
@@ -2607,8 +2585,31 @@ Editor::setup_toolbar ()
        mouse_mode_button_table.attach (mouse_gain_button, 0, 1, 1, 2);
        mouse_mode_button_table.attach (mouse_timefx_button, 1, 2, 1, 2);
        mouse_mode_button_table.attach (mouse_audition_button, 2, 3, 1, 2);
-
+       
        mouse_mode_tearoff = manage (new TearOff (mouse_mode_button_table));
+       */
+
+       HBox* mode_box = manage(new HBox);
+       mode_box->set_border_width (2);
+       mode_box->set_spacing(4);
+       mouse_mode_button_box.set_spacing(1);
+       mouse_mode_button_box.pack_start(mouse_move_button, true, true);
+       mouse_mode_button_box.pack_start(mouse_select_button, true, true);
+       mouse_mode_button_box.pack_start(mouse_zoom_button, true, true);
+       mouse_mode_button_box.pack_start(mouse_gain_button, true, true);
+       mouse_mode_button_box.pack_start(mouse_timefx_button, true, true);
+       mouse_mode_button_box.pack_start(mouse_audition_button, true, true);
+       mouse_mode_button_box.set_homogeneous(true);
+
+       edit_mode_selector.set_name ("EditModeSelector");
+       Gtkmm2ext::set_size_request_to_display_given_text (edit_mode_selector, "Splice", 2+FUDGE, 10);
+       set_popdown_strings (edit_mode_selector, internationalize (edit_mode_strings));
+       edit_mode_selector.signal_changed().connect (mem_fun(*this, &Editor::edit_mode_selection_done));
+
+       mode_box->pack_start(mouse_mode_button_box);
+       mode_box->pack_start(edit_mode_selector);
+       
+       mouse_mode_tearoff = manage (new TearOff (*mode_box));
        mouse_mode_tearoff->set_name ("MouseModeBase");
 
        mouse_mode_tearoff->Detach.connect (bind (mem_fun(*this, &Editor::detach_tearoff), static_cast<Box*>(&toolbar_hbox), 
@@ -2627,12 +2628,12 @@ Editor::setup_toolbar ()
        mouse_timefx_button.set_name ("MouseModeButton");
        mouse_audition_button.set_name ("MouseModeButton");
 
-       ARDOUR_UI::instance()->tooltips().set_tip (mouse_move_button, _("select/move objects"));
-       ARDOUR_UI::instance()->tooltips().set_tip (mouse_select_button, _("select/move ranges"));
-       ARDOUR_UI::instance()->tooltips().set_tip (mouse_gain_button, _("draw gain automation"));
-       ARDOUR_UI::instance()->tooltips().set_tip (mouse_zoom_button, _("select zoom range"));
-       ARDOUR_UI::instance()->tooltips().set_tip (mouse_timefx_button, _("stretch/shrink regions"));
-       ARDOUR_UI::instance()->tooltips().set_tip (mouse_audition_button, _("listen to specific regions"));
+       ARDOUR_UI::instance()->tooltips().set_tip (mouse_move_button, _("Select/Move Objects"));
+       ARDOUR_UI::instance()->tooltips().set_tip (mouse_select_button, _("Select/Move Ranges"));
+       ARDOUR_UI::instance()->tooltips().set_tip (mouse_gain_button, _("Draw Gain Automation"));
+       ARDOUR_UI::instance()->tooltips().set_tip (mouse_zoom_button, _("Select Zoom Range"));
+       ARDOUR_UI::instance()->tooltips().set_tip (mouse_timefx_button, _("Stretch/Shrink Regions"));
+       ARDOUR_UI::instance()->tooltips().set_tip (mouse_audition_button, _("Listen to Specific Regions"));
 
        mouse_move_button.unset_flags (CAN_FOCUS);
        mouse_select_button.unset_flags (CAN_FOCUS);
@@ -2651,101 +2652,81 @@ Editor::setup_toolbar ()
        mouse_audition_button.signal_toggled().connect (bind (mem_fun(*this, &Editor::mouse_mode_toggled), Editing::MouseAudition));
 
        // mouse_move_button.set_active (true);
+       
 
-       /* automation control */
-
-       global_automation_button.set_name ("MouseModeButton");
-       automation_mode_button.set_name ("MouseModeButton");
-
-       automation_box.set_spacing (2);
-       automation_box.set_border_width (2);
-       automation_box.pack_start (global_automation_button, false, false);
-       automation_box.pack_start (automation_mode_button, false, false);
-
-       /* Edit mode */
-
-       edit_mode_label.set_name ("ToolBarLabel");
-
-       edit_mode_selector.set_name ("EditModeSelector");
+       /* Zoom */
+       
+       zoom_box.set_spacing (1);
+       zoom_box.set_border_width (2);
 
-       edit_mode_box.set_spacing (3);
-       edit_mode_box.set_border_width (3);
+       zoom_in_button.set_name ("EditorTimeButton");
+       zoom_in_button.add (*(manage (new Image (get_xpm("zoom_in.xpm")))));
+       zoom_in_button.signal_clicked().connect (bind (mem_fun(*this, &Editor::temporal_zoom_step), false));
+       ARDOUR_UI::instance()->tooltips().set_tip (zoom_in_button, _("Zoom In"));
+       
+       zoom_out_button.set_name ("EditorTimeButton");
+       zoom_out_button.add (*(manage (new Image (get_xpm("zoom_out.xpm")))));
+       zoom_out_button.signal_clicked().connect (bind (mem_fun(*this, &Editor::temporal_zoom_step), true));
+       ARDOUR_UI::instance()->tooltips().set_tip (zoom_out_button, _("Zoom Out"));
 
-       /* XXX another disgusting hack because of the way combo boxes size themselves */
+       zoom_out_full_button.set_name ("EditorTimeButton");
+       zoom_out_full_button.add (*(manage (new Image (get_xpm("zoom_full.xpm")))));
+       zoom_out_full_button.signal_clicked().connect (mem_fun(*this, &Editor::temporal_zoom_session));
+       ARDOUR_UI::instance()->tooltips().set_tip (zoom_out_full_button, _("Zoom to Session"));
+       
+       zoom_box.pack_start (zoom_out_button, false, false);
+       zoom_box.pack_start (zoom_in_button, false, false);
+       zoom_box.pack_start (zoom_range_clock, false, false);   
+       zoom_box.pack_start (zoom_out_full_button, false, false);
+       
+       ARDOUR_UI::instance()->tooltips().set_tip (zoom_range_clock, _("Current Zoom Range\n(Width of visible area)"));
+       
+       zoom_focus_selector.set_name ("ZoomFocusSelector");
+       Gtkmm2ext::set_size_request_to_display_given_text (zoom_focus_selector, "Focus Center", 2+FUDGE, 0);
+       set_popdown_strings (zoom_focus_selector, internationalize (zoom_focus_strings));
+       zoom_focus_selector.signal_changed().connect (mem_fun(*this, &Editor::zoom_focus_selection_done));
 
-       const guint32 FUDGE = 20; // Combo's are stupid - they steal space from the entry for the button
-       Gtkmm2ext::set_size_request_to_display_given_text (edit_mode_selector, "EdgtMode", 2+FUDGE, 10);
-       set_popdown_strings (edit_mode_selector, internationalize (edit_mode_strings));
-       edit_mode_box.pack_start (edit_mode_label, false, false);
-       edit_mode_box.pack_start (edit_mode_selector, false, false);
+       zoom_box.pack_start (zoom_focus_selector, false, false);
 
-       edit_mode_selector.signal_changed().connect (mem_fun(*this, &Editor::edit_mode_selection_done));
 
-       /* Snap Type */
+       /* Edit Cursor / Snap */
 
-       snap_type_label.set_name ("ToolBarLabel");
+       snap_box.set_spacing (1);
+       snap_box.set_border_width (2);
 
        snap_type_selector.set_name ("SnapTypeSelector");
-
-       snap_type_box.set_spacing (3);
-       snap_type_box.set_border_width (3);
-
-       /* XXX another disgusting hack because of the way combo boxes size themselves */
-
        Gtkmm2ext::set_size_request_to_display_given_text (snap_type_selector, "SMPTE Seconds", 2+FUDGE, 10);
        set_popdown_strings (snap_type_selector, internationalize (snap_type_strings));
-
-       snap_type_box.pack_start (snap_type_label, false, false);
-       snap_type_box.pack_start (snap_type_selector, false, false);
-
        snap_type_selector.signal_changed().connect (mem_fun(*this, &Editor::snap_type_selection_done));
-
-       /* Snap mode, not snap type */
-
-       snap_mode_label.set_name ("ToolBarLabel");
+       ARDOUR_UI::instance()->tooltips().set_tip (snap_type_selector, _("Unit to snap cursors and ranges to"));
 
        snap_mode_selector.set_name ("SnapModeSelector");
-       
-       snap_mode_box.set_spacing (3);
-       snap_mode_box.set_border_width (3);
-
-       Gtkmm2ext::set_size_request_to_display_given_text (snap_mode_selector, "SngpMode", 2+FUDGE, 10);
+       Gtkmm2ext::set_size_request_to_display_given_text (snap_mode_selector, "Magnetic Snap", 2+FUDGE, 10);
        set_popdown_strings (snap_mode_selector, internationalize (snap_mode_strings));
-
-       snap_mode_box.pack_start (snap_mode_label, false, false);
-       snap_mode_box.pack_start (snap_mode_selector, false, false);
-
        snap_mode_selector.signal_changed().connect (mem_fun(*this, &Editor::snap_mode_selection_done));
 
-       /* Zoom focus mode */
-
-       zoom_focus_label.set_name ("ToolBarLabel");
-
-       zoom_focus_selector.set_name ("ZoomFocusSelector");
+       snap_box.pack_start (edit_cursor_clock, false, false);
+       snap_box.pack_start (snap_mode_selector, false, false);
+       snap_box.pack_start (snap_type_selector, false, false);
 
-       zoom_focus_box.set_spacing (3);
-       zoom_focus_box.set_border_width (3);
-
-       /* XXX another disgusting hack because of the way combo boxes size themselves */
-
-       Gtkmm2ext::set_size_request_to_display_given_text (zoom_focus_selector, "Edgt Cursor", 2+FUDGE, 10);
-       set_popdown_strings (zoom_focus_selector, internationalize (zoom_focus_strings));
+       /* automation control */
 
-       zoom_focus_box.pack_start (zoom_focus_label, false, false);
-       zoom_focus_box.pack_start (zoom_focus_selector, false, false);
+       /*global_automation_button.set_name ("MouseModeButton");
+       automation_mode_button.set_name ("MouseModeButton");
 
-       zoom_focus_selector.signal_changed().connect (mem_fun(*this, &Editor::zoom_focus_selection_done));
+       automation_box.set_spacing (2);
+       automation_box.set_border_width (2);
+       automation_box.pack_start (global_automation_button, false, false);
+       automation_box.pack_start (automation_mode_button, false, false);*/
 
-       /* selection/cursor clocks */
+       /* Selection/cursor clocks */
 
        toolbar_selection_cursor_label.set_name ("ToolBarLabel");
        selection_start_clock_label.set_name ("ToolBarLabel");
        selection_end_clock_label.set_name ("ToolBarLabel");
-       edit_cursor_clock_label.set_name ("ToolBarLabel");
-
+       
        selection_start_clock_label.set_text (_("Start:"));
        selection_end_clock_label.set_text (_("End:"));
-       edit_cursor_clock_label.set_text (_("Edit"));
 
        /* the zoom in/out buttons are generally taller than the clocks, so
           put all the toolbar clocks into a size group with one of the 
@@ -2754,57 +2735,17 @@ Editor::setup_toolbar ()
           this also applies to the various toolbar combos
        */
 
-       RefPtr<SizeGroup> toolbar_clock_size_group = SizeGroup::create (SIZE_GROUP_VERTICAL);
+       /*RefPtr<SizeGroup> toolbar_clock_size_group = SizeGroup::create (SIZE_GROUP_VERTICAL);
        toolbar_clock_size_group->add_widget (zoom_out_button);
        toolbar_clock_size_group->add_widget (edit_cursor_clock);
        toolbar_clock_size_group->add_widget (zoom_range_clock);
        toolbar_clock_size_group->add_widget (nudge_clock);
        toolbar_clock_size_group->add_widget (edit_mode_selector);
        toolbar_clock_size_group->add_widget (snap_type_selector);
-       toolbar_clock_size_group->add_widget (snap_mode_selector);
-       toolbar_clock_size_group->add_widget (zoom_focus_selector);
-
-       HBox* edit_clock_hbox = manage (new HBox());
-       VBox* edit_clock_vbox = manage (new VBox());
-
-       edit_clock_hbox->pack_start (edit_cursor_clock, false, false);
-
-       edit_clock_vbox->set_spacing (3);
-       edit_clock_vbox->set_border_width (3);
-       edit_clock_vbox->pack_start (edit_cursor_clock_label, false, false);
-       edit_clock_vbox->pack_start (*edit_clock_hbox, false, false);
+       toolbar_clock_size_group->add_widget (snap_mode_selector);*/
 
        HBox* hbox = new HBox;
-
-       hbox->pack_start (*edit_clock_vbox, false, false);
-       hbox->pack_start (zoom_indicator_vbox, false, false); 
-       hbox->pack_start (zoom_focus_box, false, false);
-       hbox->pack_start (snap_type_box, false, false);
-       hbox->pack_start (snap_mode_box, false, false);
-       hbox->pack_start (edit_mode_box, false, false);
-
-       VBox *vbox = manage (new VBox);
-
-       vbox->set_spacing (3);
-       vbox->set_border_width (3);
-
-       HBox *nbox = manage (new HBox);
-       
-       nudge_forward_button.signal_clicked().connect (bind (mem_fun(*this, &Editor::nudge_forward), false));
-       nudge_backward_button.signal_clicked().connect (bind (mem_fun(*this, &Editor::nudge_backward), false));
-
-       nbox->pack_start (nudge_backward_button, false, false);
-       nbox->pack_start (nudge_forward_button, false, false);
-       nbox->pack_start (nudge_clock, false, false, 5);
-
-       nudge_label.set_name ("ToolBarLabel");
-
-       vbox->pack_start (nudge_label, false, false);
-       vbox->pack_start (*nbox, false, false);
-
-       hbox->pack_start (*vbox, false, false);
-
-       hbox->show_all ();
+       hbox->set_spacing(10);
 
        tools_tearoff = new TearOff (*hbox);
        tools_tearoff->set_name ("MouseModeBase");
@@ -2818,11 +2759,36 @@ Editor::setup_toolbar ()
        tools_tearoff->Visible.connect (bind (mem_fun(*this, &Editor::reattach_tearoff), static_cast<Box*> (&toolbar_hbox), 
                                              &tools_tearoff->tearoff_window(), 0));
 
-       toolbar_hbox.set_spacing (8);
+       toolbar_hbox.set_spacing (10);
        toolbar_hbox.set_border_width (2);
 
-       toolbar_hbox.pack_start (*tools_tearoff, false, false);
        toolbar_hbox.pack_start (*mouse_mode_tearoff, false, false);
+       toolbar_hbox.pack_start (*tools_tearoff, false, false);
+
+       hbox->pack_start (snap_box, false, false);
+       hbox->pack_start (zoom_box, false, false); 
+       hbox->pack_start (edit_mode_box, false, false);
+
+       //VBox *nudge_vbox = manage (new VBox);
+
+       //nudge_vbox->set_border_width (2);
+
+       HBox *nudge_box = manage (new HBox);
+       nudge_box->set_spacing(1);
+       nudge_box->set_border_width (2);
+
+       nudge_forward_button.signal_clicked().connect (bind (mem_fun(*this, &Editor::nudge_forward), false));
+       nudge_backward_button.signal_clicked().connect (bind (mem_fun(*this, &Editor::nudge_backward), false));
+
+       nudge_box->pack_start (nudge_backward_button, false, false);
+       nudge_box->pack_start (nudge_forward_button, false, false);
+       nudge_box->pack_start (nudge_clock, false, false);
+
+       //nudge_vbox->pack_start (*nudge_box, false, false);
+
+       hbox->pack_start (*nudge_box, false, false);
+
+       hbox->show_all ();
        
        toolbar_base.set_name ("ToolBarBase");
        toolbar_base.add (toolbar_hbox);
@@ -3629,18 +3595,18 @@ Editor::snap_type_selection_done ()
 
        string choice = snap_type_selector.get_active_text();
        SnapType snaptype = SnapToFrame;
-       
+
        if (choice == _("Beats/3")) {
-                snaptype = SnapToAThirdBeat;
-        } else if (choice == _("Beats/4")) {
-                snaptype = SnapToAQuarterBeat;
-        } else if (choice == _("Beats/8")) {
-                snaptype = SnapToAEighthBeat;
-        } else if (choice == _("Beats/16")) {
-                snaptype = SnapToASixteenthBeat;
-        } else if (choice == _("Beats/32")) {
-                snaptype = SnapToAThirtysecondBeat;
-        } else if (choice == _("Beats")) {
+               snaptype = SnapToAThirdBeat;
+       } else if (choice == _("Beats/4")) {
+               snaptype = SnapToAQuarterBeat;
+       } else if (choice == _("Beats/8")) {
+               snaptype = SnapToAEighthBeat;
+       } else if (choice == _("Beats/16")) {
+               snaptype = SnapToASixteenthBeat;
+       } else if (choice == _("Beats/32")) {
+               snaptype = SnapToAThirtysecondBeat;
+       } else if (choice == _("Beats")) {
                snaptype = SnapToBeat;
        } else if (choice == _("Bars")) {
                snaptype = SnapToBar;
@@ -3668,10 +3634,10 @@ Editor::snap_type_selection_done ()
                snaptype = SnapToSeconds;
        } else if (choice == _("Minutes")) {
                snaptype = SnapToMinutes;
-        } else if (choice == _("None")) {
+       } else if (choice == _("None")) {
                snaptype = SnapToFrame;
        }
-       
+
        set_snap_to (snaptype);
 }      
 
@@ -3685,9 +3651,9 @@ Editor::snap_mode_selection_done ()
        string choice = snap_mode_selector.get_active_text();
        SnapMode mode = SnapNormal;
 
-       if (choice == _("Normal")) {
+       if (choice == _("Normal Snap")) {
                mode = SnapNormal;
-       } else if (choice == _("Magnetic")) {
+       } else if (choice == _("Magnetic Snap")) {
                mode = SnapMagnetic;
        }
 
index b29b51a39908a237b62e46d350ca1424c94d2dbc..5b197ae8629c3642e33161f2532e8319d6f2e989 100644 (file)
@@ -1269,7 +1269,6 @@ class Editor : public PublicEditor
        AudioClock               selection_end_clock;
        Gtk::Label               selection_end_clock_label;
        AudioClock               edit_cursor_clock;
-       Gtk::Label               edit_cursor_clock_label;
        AudioClock               zoom_range_clock;
        Gtk::Button              zoom_in_button;
        Gtk::Button              zoom_out_button;
@@ -1281,8 +1280,8 @@ class Editor : public PublicEditor
        Gtk::Table               toolbar_selection_clock_table;
        Gtk::Label               toolbar_selection_cursor_label;
        
-       Gtk::Table               mouse_mode_button_table;
-       Gtkmm2ext::TearOff*       mouse_mode_tearoff;
+       Gtk::HBox                mouse_mode_button_box;
+       Gtkmm2ext::TearOff*      mouse_mode_tearoff;
        Gtk::ToggleButton        mouse_select_button;
        Gtk::ToggleButton        mouse_move_button;
        Gtk::ToggleButton        mouse_gain_button;
@@ -1300,32 +1299,23 @@ class Editor : public PublicEditor
        Gtk::ToggleButton        global_automation_button;
 
        Gtk::ComboBoxText edit_mode_selector;
-       Gtk::Label               edit_mode_label;
-       Gtk::VBox                edit_mode_box;
+       Gtk::VBox         edit_mode_box;
 
        void edit_mode_selection_done ();
 
        Gtk::ComboBoxText snap_type_selector;
-       Gtk::Label               snap_type_label;
-       Gtk::VBox                snap_type_box;
+       Gtk::ComboBoxText snap_mode_selector;
+       Gtk::HBox         snap_box;
 
        void snap_type_selection_done ();
-
-       Gtk::ComboBoxText               snap_mode_selector;
-       Gtk::Label               snap_mode_label;
-       Gtk::VBox                snap_mode_box;
-
        void snap_mode_selection_done ();
        
        Gtk::ComboBoxText zoom_focus_selector;
-       Gtk::Label               zoom_focus_label;
        Gtk::VBox                zoom_focus_box;
        
        void zoom_focus_selection_done ();
 
-       Gtk::Label          zoom_indicator_label;
-       Gtk::HBox           zoom_indicator_box;
-       Gtk::VBox           zoom_indicator_vbox;
+       Gtk::HBox           zoom_box;
 
        void                update_zoom_indicator ();
        void                zoom_adjustment_changed();
@@ -1776,7 +1766,6 @@ class Editor : public PublicEditor
        Gtk::Button      nudge_backward_button;
        Gtk::HBox        nudge_hbox;
        Gtk::VBox        nudge_vbox;
-       Gtk::Label       nudge_label;
        AudioClock       nudge_clock;
 
        jack_nframes_t get_nudge_distance (jack_nframes_t pos, jack_nframes_t& next);
index c2d81abf3ce1ab4ad045873d69d936e020667ee4..5e462aa447394ac41146651cd34d91323b53020c 100644 (file)
@@ -234,11 +234,11 @@ FFTGraph::draw_scales(Glib::RefPtr<Gdk::Window> window)
                while (_logScale[logscale_pos] < position_on_scale)
                        logscale_pos++;
                
-               int coord = v_margin + 1.0 + position_on_scale;
+               int coord = (int)(v_margin + 1.0 + position_on_scale);
                
                int SR = 44100;
 
-               int rate_at_pos = (double)(SR/2) * (double)logscale_pos / (double)_dataSize;
+               int rate_at_pos = (int)((double)(SR/2) * (double)logscale_pos / (double)_dataSize);
                
                char buf[32];
                snprintf(buf,32,"%dhz",rate_at_pos);
@@ -384,7 +384,7 @@ FFTGraph::on_size_request(Gtk::Requisition* requisition)
 }
 
 void
-FFTGraph::on_size_allocate(Gtk::Allocation alloc)
+FFTGraph::on_size_allocate(Gtk::Allocation& alloc)
 {
        width = alloc.get_width();
        height = alloc.get_height();
index 80c78180a6c8a934709a2af0ff5bc0a7bd5e0509..2163b64b7e8092840ed299d679378e8862c63249 100644 (file)
@@ -51,7 +51,7 @@ class FFTGraph : public Gtk::DrawingArea
                bool on_expose_event (GdkEventExpose* event);
                
                void on_size_request(Gtk::Requisition* requisition);
-               void on_size_allocate(Gtk::Allocation alloc);
+               void on_size_allocate(Gtk::Allocation& alloc);
                FFTResult *prepareResult(Gdk::Color color, std::string trackname);
                
        private:
index c0afce57ccfe97cccdd2d612696729c0fd7a4d5f..819f19b75a3d2a2237dc66b77724b9d93ba6f440 100644 (file)
@@ -1,21 +1,22 @@
 /* XPM */
-static const gchar * left_arrow_xpm[] = {
-"12 15 3 1",
+static char * left_arrow_xpm[] = {
+"12 12 7 1",
 "      c None",
 ".     c #000000",
 "+     c #FFFFFF",
-"       ..+. ",
-"      ..++. ",
-"     ..+++. ",
-"    ..+++.. ",
-"   ..+++..  ",
-"  ..+++..   ",
-" ..+++..    ",
-" .+++..     ",
-" ..+++..    ",
-"  ..+++..   ",
-"   ..+++..  ",
-"    ..+++.. ",
-"     ..+++. ",
-"      ..++. ",
-"       ..+. "};
+"@     c #020202",
+"#     c #0B0B0B",
+"$     c #131313",
+"%     c #121212",
+"      ....  ",
+"     ..++.  ",
+"    ..++..  ",
+"   ..++..   ",
+"  ..++..    ",
+" ..++..     ",
+" ..++@.     ",
+"  ..++#.    ",
+"   ..++$.   ",
+"    ..++%.  ",
+"     ..++.  ",
+"      ....  "};
index d5626f71fefcd6b6f66f4e2f59ced5550d74db6c..7c7730398ec8c714b85390b61e443839bcf6ded4 100644 (file)
@@ -1,21 +1,22 @@
 /* XPM */
-static const gchar * right_arrow_xpm[] = {
-"12 15 3 1",
+static char * right_arrow_xpm[] = {
+"12 12 7 1",
 "      c None",
 ".     c #000000",
 "+     c #FFFFFF",
-" .+..       ",
-" .++..      ",
-" .+++..     ",
-" ..+++..    ",
-"  ..+++..   ",
-"   ..+++..  ",
-"    ..+++.. ",
-"     ..+++. ",
-"    ..+++.. ",
-"   ..+++..  ",
-"  ..+++..   ",
-" ..+++..    ",
-" .+++..     ",
-" .++..      ",
-" .+..       "};
+"@     c #020202",
+"#     c #0B0B0B",
+"$     c #131313",
+"%     c #121212",
+"  ....      ",
+"  .++..     ",
+"  ..++..    ",
+"   ..++..   ",
+"    ..++..  ",
+"     ..++.. ",
+"     .@++.. ",
+"    .#++..  ",
+"   .$++..   ",
+"  .%++..    ",
+"  .++..     ",
+"  ....      "};
diff --git a/gtk2_ardour/pixmaps/tool_audition.xpm b/gtk2_ardour/pixmaps/tool_audition.xpm
new file mode 100644 (file)
index 0000000..d6f2ccd
--- /dev/null
@@ -0,0 +1,19 @@
+/* XPM */
+static char * tool_audition_xpm[] = {
+"16 12 4 1",
+"      c None",
+".     c #000000",
+"+     c #ECECEC",
+"@     c #FFFFFF",
+"      ..        ",
+"     .+.    .   ",
+"    .++.   .@.  ",
+"....+@+...  .@. ",
+".+++@@+..@.  .@.",
+".+@@@@+. .@. .@.",
+".+@@@@+. .@. .@.",
+".+++@@+..@.  .@.",
+"....+@+...  .@. ",
+"    .++.   .@.  ",
+"     .+.    .   ",
+"      ..        "};
diff --git a/gtk2_ardour/pixmaps/tool_gain.xpm b/gtk2_ardour/pixmaps/tool_gain.xpm
new file mode 100644 (file)
index 0000000..480426f
--- /dev/null
@@ -0,0 +1,18 @@
+/* XPM */
+static char * tool_gain_xpm[] = {
+"16 12 3 1",
+"      c None",
+".     c #000000",
+"+     c #FFFFFF",
+"...             ",
+".++..           ",
+"...++.          ",
+"   ..+.         ",
+"     .+.        ",
+"     .+.        ",
+"      .+.       ",
+"      .+.       ",
+"       .+..     ",
+"        .++.....",
+"         ..++++.",
+"           ....."};
diff --git a/gtk2_ardour/pixmaps/tool_object.xpm b/gtk2_ardour/pixmaps/tool_object.xpm
new file mode 100644 (file)
index 0000000..a2e6fe6
--- /dev/null
@@ -0,0 +1,23 @@
+/* XPM */
+static char * tool_object_xpm[] = {
+"16 12 8 1",
+"      c None",
+".     c #000000",
+"+     c #444444",
+"@     c #888888",
+"#     c #CC9966",
+"$     c #DDDDDD",
+"%     c #FFCC99",
+"&     c #FFFFFF",
+"     ...        ",
+"     .&.        ",
+"     .&.        ",
+"     .&.        ",
+"     .&.....    ",
+"     .&.&.&...  ",
+"   ...&.&.&.&.  ",
+"   .&.&&&&&&&.  ",
+"   .&&&&&&&&&.  ",
+"   ...&&&&&&..  ",
+"     ..&&&&&.   ",
+"      .&&&&&.   "};
diff --git a/gtk2_ardour/pixmaps/tool_range.xpm b/gtk2_ardour/pixmaps/tool_range.xpm
new file mode 100644 (file)
index 0000000..75ee865
--- /dev/null
@@ -0,0 +1,18 @@
+/* XPM */
+static char * tool_range_xpm[] = {
+"16 12 3 1",
+"      c None",
+".     c #000000",
+"+     c #FFFFFF",
+"...          ...",
+".+.  ..  ..  .+.",
+".+. .+.  .+. .+.",
+".+..+.    .+..+.",
+".+.++......++.+.",
+".++++++++++++++.",
+".+.++......++.+.",
+".+..+.    .+..+.",
+".+. .+.  .+. .+.",
+".+.  ..  ..  .+.",
+".+.          .+.",
+"...          ..."};
diff --git a/gtk2_ardour/pixmaps/tool_stretch.xpm b/gtk2_ardour/pixmaps/tool_stretch.xpm
new file mode 100644 (file)
index 0000000..fa9fd33
--- /dev/null
@@ -0,0 +1,18 @@
+/* XPM */
+static char * tool_stretch_xpm[] = {
+"16 12 3 1",
+"      c None",
+".     c #000000",
+"+     c #FFFFFF",
+"  ..        ..  ",
+" .+.        .+. ",
+".++..........++.",
+"++++++++++++++++",
+".++..........++.",
+" .+.        .+. ",
+"  ..        ..  ",
+"    +   +       ",
+" +  + + + + + + ",
+"++++++++++++++++",
+"  +   +   + + + ",
+"  +       +   + "};
diff --git a/gtk2_ardour/pixmaps/tool_zoom.xpm b/gtk2_ardour/pixmaps/tool_zoom.xpm
new file mode 100644 (file)
index 0000000..581363f
--- /dev/null
@@ -0,0 +1,29 @@
+/* XPM */
+static char * tool_zoom_xpm[] = {
+"16 12 14 1",
+"      c None",
+".     c #000000",
+"+     c #474747",
+"@     c #E7E7E7",
+"#     c #F6F6F6",
+"$     c #DCDCDC",
+"%     c #FFFFFF",
+"&     c #DFDFDF",
+"*     c #D7D7D7",
+"=     c #D6D6D6",
+"-     c #040404",
+";     c #070707",
+">     c #060606",
+",     c #050505",
+"     ...        ",
+"   +.@#$.+      ",
+"   .%%%%%.      ",
+"  .&%%%%%*.     ",
+"  .#%%%%%#.     ",
+"  .$%%%%%&.     ",
+"   .%%%%%.+     ",
+"   +.*#=...     ",
+"     ...+...    ",
+"          -.;   ",
+"           >.-  ",
+"            ,.  "};
diff --git a/gtk2_ardour/pixmaps/zoom_full.xpm b/gtk2_ardour/pixmaps/zoom_full.xpm
new file mode 100644 (file)
index 0000000..f902403
--- /dev/null
@@ -0,0 +1,29 @@
+/* XPM */
+static char * zoom_full_xpm[] = {
+"12 12 14 1",
+"      c None",
+".     c #000000",
+"+     c #474747",
+"@     c #E7E7E7",
+"#     c #F6F6F6",
+"$     c #DCDCDC",
+"%     c #FFFFFF",
+"&     c #DFDFDF",
+"*     c #D7D7D7",
+"=     c #D6D6D6",
+"-     c #040404",
+";     c #070707",
+">     c #060606",
+",     c #050505",
+"   ...      ",
+" +.@#$.+    ",
+" .%%.%%.    ",
+".&%..%%*.   ",
+".#%%.%%#.   ",
+".$%%.%%&.   ",
+" .%...%.+   ",
+" +.*#=...   ",
+"   ...+...  ",
+"        -.; ",
+"         >.-",
+"          ,."};
diff --git a/gtk2_ardour/pixmaps/zoom_in.xpm b/gtk2_ardour/pixmaps/zoom_in.xpm
new file mode 100644 (file)
index 0000000..1f8d4e8
--- /dev/null
@@ -0,0 +1,29 @@
+/* XPM */
+static char * zoom_in_xpm[] = {
+"12 12 14 1",
+"      c None",
+".     c #000000",
+"+     c #474747",
+"@     c #E7E7E7",
+"#     c #F6F6F6",
+"$     c #DCDCDC",
+"%     c #FFFFFF",
+"&     c #DFDFDF",
+"*     c #D7D7D7",
+"=     c #D6D6D6",
+"-     c #040404",
+";     c #070707",
+">     c #060606",
+",     c #050505",
+"   ...      ",
+" +.@#$.+    ",
+" .%%.%%.    ",
+".&%%.%%*.   ",
+".#.....#.   ",
+".$%%.%%&.   ",
+" .%%.%%.+   ",
+" +.*#=...   ",
+"   ...+...  ",
+"        -.; ",
+"         >.-",
+"          ,."};
diff --git a/gtk2_ardour/pixmaps/zoom_out.xpm b/gtk2_ardour/pixmaps/zoom_out.xpm
new file mode 100644 (file)
index 0000000..ea50d14
--- /dev/null
@@ -0,0 +1,29 @@
+/* XPM */
+static char * zoom_out_xpm[] = {
+"12 12 14 1",
+"      c None",
+".     c #000000",
+"+     c #474747",
+"@     c #E7E7E7",
+"#     c #F6F6F6",
+"$     c #DCDCDC",
+"%     c #FFFFFF",
+"&     c #DFDFDF",
+"*     c #D7D7D7",
+"=     c #D6D6D6",
+"-     c #040404",
+";     c #070707",
+">     c #060606",
+",     c #050505",
+"   ...      ",
+" +.@#$.+    ",
+" .%%%%%.    ",
+".&%%%%%*.   ",
+".#.....#.   ",
+".$%%%%%&.   ",
+" .%%%%%.+   ",
+" +.*#=...   ",
+"   ...+...  ",
+"        -.; ",
+"         >.-",
+"          ,."};