Compare commits
3 Commits
b6b1aec50e
...
4b30239275
Author | SHA1 | Date |
---|---|---|
Ben Loftis | 4b30239275 | |
Ben Loftis | 9cb6c67f7b | |
Ben Loftis | f420c74598 |
|
@ -2945,13 +2945,25 @@ RCOptionEditor::RCOptionEditor ()
|
|||
|
||||
bo = new BoolOption (
|
||||
"use-palette-for-new-route",
|
||||
_("Use color-palette to assign color for new tracks/busses"),
|
||||
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::get_use_palette_for_new_route),
|
||||
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::set_use_palette_for_new_route)
|
||||
_("Use color-palette to assign color for new Tracks"),
|
||||
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::get_use_palette_for_new_track),
|
||||
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::set_use_palette_for_new_track)
|
||||
);
|
||||
Gtkmm2ext::UI::instance()->set_tip (bo->tip_widget (),
|
||||
_("<b>When enabled</b> new Routes are assigned a color from the stripable-color-palette in round-robin fashion.\n"
|
||||
"<b>When disabled</b> all new Routes will have a neutral color from the theme."
|
||||
_("<b>When enabled</b> new Tracks are assigned a color from the stripable-color-palette in round-robin fashion.\n"
|
||||
"<b>When disabled</b> all new Tracks will use the FIRST color from the stripable-color-palette."
|
||||
));
|
||||
add_option (_("Appearance/Colors"), bo);
|
||||
|
||||
bo = new BoolOption (
|
||||
"use-palette-for-new-route",
|
||||
_("Use color-palette to assign color for new Busses"),
|
||||
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::get_use_palette_for_new_bus),
|
||||
sigc::mem_fun (UIConfiguration::instance(), &UIConfiguration::set_use_palette_for_new_bus)
|
||||
);
|
||||
Gtkmm2ext::UI::instance()->set_tip (bo->tip_widget (),
|
||||
_("<b>When enabled</b> new Buses are assigned a color from the stripable-color-palette in round-robin fashion.\n"
|
||||
"<b>When disabled</b> all new Buses will use the FIRST color from the stripable-color-palette."
|
||||
));
|
||||
add_option (_("Appearance/Colors"), bo);
|
||||
|
||||
|
|
|
@ -366,10 +366,15 @@ RouteUI::set_route (std::shared_ptr<Route> rp)
|
|||
}
|
||||
|
||||
if (set_color_from_route()) {
|
||||
if (UIConfiguration::instance().get_use_palette_for_new_route ()) {
|
||||
if (_route->is_track() && UIConfiguration::instance().get_use_palette_for_new_track ()) {
|
||||
set_color (gdk_color_to_rgba (AxisView::round_robin_palette_color ()));
|
||||
} else if (!_route->is_track() && UIConfiguration::instance().get_use_palette_for_new_bus ()) {
|
||||
set_color (gdk_color_to_rgba (AxisView::round_robin_palette_color ()));
|
||||
} else {
|
||||
set_color (UIConfiguration::instance ().color (X_("neutral:midground")));
|
||||
string cp = UIConfiguration::instance().get_stripable_color_palette ();
|
||||
Gdk::ArrayHandle_Color gc = ColorSelection::palette_from_string (cp);
|
||||
std::vector<Gdk::Color> c (gc);
|
||||
set_color (gdk_color_to_rgba (c[0]));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -123,9 +123,10 @@ UI_CONFIG_VARIABLE (uint32_t, action_table_columns, "action-table-columns", 3)
|
|||
UI_CONFIG_VARIABLE (bool, hide_splash_screen, "hide-splash-screen", true)
|
||||
UI_CONFIG_VARIABLE (bool, check_announcements, "check-announcements,", true)
|
||||
UI_CONFIG_VARIABLE (bool, use_wm_visibility, "use-wm-visibility", true)
|
||||
UI_CONFIG_VARIABLE (bool, use_palette_for_new_route, "use-palette-for-new-route", true)
|
||||
UI_CONFIG_VARIABLE (bool, use_palette_for_new_track, "use-palette-for-new-track", true)
|
||||
UI_CONFIG_VARIABLE (bool, use_palette_for_new_bus, "use-palette-for-new-bus", true)
|
||||
UI_CONFIG_VARIABLE (bool, use_palette_for_new_vca, "use-palette-for-new-vca", true)
|
||||
UI_CONFIG_VARIABLE (std::string, stripable_color_palette, "stripable-color-palette", "#AA3939:#FFAAAA:#D46A6A:#801515:#550000:#AA8E39:#FFEAAA:#D4BA6A:#806515:#554000:#343477:#8080B3:#565695:#1A1A59:#09093B:#2D882D:#88CC88:#55AA55:#116611:#004400") /* Gtk::ColorSelection::palette_to_string */
|
||||
UI_CONFIG_VARIABLE (std::string, stripable_color_palette, "stripable-color-palette", "#006E90:#008DB8:#00ACE0:#0AC6FF:#7EE8FA:#AA8E39:#FFEAAA:#D4BA6A:#806515:#554000:#343477:#8080B3:#565695:#1A1A59:#09093B:#2D882D:#88CC88:#55AA55:#116611:#004400") /* Gtk::ColorSelection::palette_to_string */
|
||||
UI_CONFIG_VARIABLE (bool, use_note_bars_for_velocity, "use-note-bars-for-velocity", true)
|
||||
UI_CONFIG_VARIABLE (bool, use_note_color_for_velocity, "use-note-color-for-velocity", true)
|
||||
UI_CONFIG_VARIABLE (bool, show_snapped_cursor, "show-snapped-cursor", true)
|
||||
|
|
|
@ -67,7 +67,10 @@ VCAMasterStrip::VCAMasterStrip (Session* s, std::shared_ptr<VCA> v)
|
|||
if (UIConfiguration::instance().get_use_palette_for_new_vca ()) {
|
||||
_vca->presentation_info().set_color (Gtkmm2ext::gdk_color_to_rgba (AxisView::round_robin_palette_color ()));
|
||||
} else {
|
||||
_vca->presentation_info().set_color (UIConfiguration::instance ().color (X_("neutral:midground")));
|
||||
string cp = UIConfiguration::instance().get_stripable_color_palette ();
|
||||
Gdk::ArrayHandle_Color gc = ColorSelection::palette_from_string (cp);
|
||||
std::vector<Gdk::Color> c (gc);
|
||||
_vca->presentation_info().set_color (gdk_color_to_rgba (c[0]));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue