From d5facc08f76c3394ef53391e910d865069a0ab05 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Sat, 10 Nov 2018 21:52:12 -0500 Subject: [PATCH] get mode button rendering slightly more correct --- gtk2_ardour/beatbox_gui.cc | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/gtk2_ardour/beatbox_gui.cc b/gtk2_ardour/beatbox_gui.cc index 7c24749ad0..dad97adcd8 100644 --- a/gtk2_ardour/beatbox_gui.cc +++ b/gtk2_ardour/beatbox_gui.cc @@ -258,40 +258,44 @@ SequencerGrid::SequencerGrid (StepSequencer& s, Canvas* c) ArdourCanvas::Text* label; velocity_mode_button = new Rectangle (no_scroll_group); - velocity_mode_button->set (Rect (250.0 + 10, 10, 250.0 + 110, 60)); + velocity_mode_button->set_position (Duple (250.0 + 10, 10)); + velocity_mode_button->set (Rect (0, 0, 110, 60)); velocity_mode_button->set_fill_color (UIConfiguration::instance().color ("gtk_bright_color")); label = new Text (velocity_mode_button); label->set_font_description (UIConfiguration::instance().get_NormalFont()); label->set_position (Duple (30, 30)); label->set (_("Vel")); - //label->set_color (contrasting_text_color (velocity_mode_button->fill_color())); + label->set_color (contrasting_text_color (velocity_mode_button->fill_color())); pitch_mode_button = new Rectangle (no_scroll_group); - pitch_mode_button->set (Rect (250.0 + 110, 10, 250.0 + 210, 60)); + pitch_mode_button->set_position (Duple (250.0 + 110, 10)); + pitch_mode_button->set (Rect (0, 0, 110, 60)); pitch_mode_button->set_fill_color (UIConfiguration::instance().color ("gtk_bright_color")); label = new Text (pitch_mode_button); label->set_font_description (UIConfiguration::instance().get_NormalFont()); label->set_position (Duple (30, 30)); label->set (_("Pitch")); - //label->set_color (contrasting_text_color (pitch_mode_button->fill_color())); + label->set_color (contrasting_text_color (pitch_mode_button->fill_color())); gate_mode_button = new Rectangle (no_scroll_group); - gate_mode_button->set (Rect (250.0 + 220, 10, 250.0 + 330, 60)); + gate_mode_button->set_position (Duple (250.0 + 220, 10)); + gate_mode_button->set (Rect (0, 0, 110, 60)); gate_mode_button->set_fill_color (UIConfiguration::instance().color ("gtk_bright_color")); label = new Text (gate_mode_button); label->set_font_description (UIConfiguration::instance().get_NormalFont()); label->set_position (Duple (30, 30)); label->set (_("Gate")); - //label->set_color (contrasting_text_color (pitch_mode_button->fill_color())); + label->set_color (contrasting_text_color (pitch_mode_button->fill_color())); octave_mode_button = new Rectangle (no_scroll_group); - octave_mode_button->set (Rect (250.0 + 330, 10, 250.0 + 440, 60)); + octave_mode_button->set_position (Duple (250.0 + 330, 10)); + octave_mode_button->set (Rect (0, 0, 110, 60)); octave_mode_button->set_fill_color (UIConfiguration::instance().color ("gtk_bright_color")); label = new Text (octave_mode_button); label->set_font_description (UIConfiguration::instance().get_NormalFont()); label->set_position (Duple (30, 30)); label->set (_("Oct")); - //label->set_color (contrasting_text_color (pitch_mode_button->fill_color())); + label->set_color (contrasting_text_color (pitch_mode_button->fill_color())); set_position (Duple (250, _step_dimen + 70.0));