mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-10 08:36:32 +01:00
Don't include program-name with <Option name="color-file" />
This allows for e.g. mixbus and mixbus32c to share the config, but use different color-files at runtime.
This commit is contained in:
parent
2f30d763ed
commit
5ec21347a9
2 changed files with 15 additions and 3 deletions
|
|
@ -260,8 +260,15 @@ UIConfiguration::color_file_name (bool use_my, bool with_version) const
|
||||||
basename += "my-";
|
basename += "my-";
|
||||||
}
|
}
|
||||||
|
|
||||||
//this is the overall theme file, e.g. "dark" plus "-downcase(PROGRAM_NAME)"
|
std::string color_name = color_file.get();
|
||||||
basename += color_file.get();
|
size_t sep = color_name.find_first_of("-");
|
||||||
|
if (sep != string::npos) {
|
||||||
|
color_name = color_name.substr (0, sep);
|
||||||
|
}
|
||||||
|
|
||||||
|
basename += color_name;
|
||||||
|
basename += "-";
|
||||||
|
basename += downcase(PROGRAM_NAME);
|
||||||
|
|
||||||
std::string rev (revision);
|
std::string rev (revision);
|
||||||
std::size_t pos = rev.find_first_of("-");
|
std::size_t pos = rev.find_first_of("-");
|
||||||
|
|
|
||||||
|
|
@ -403,7 +403,12 @@ ARDOUR_UI_UTILS::get_color_themes (map<std::string,std::string>& themes)
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
themes.insert (make_pair (prop->value(), Glib::filename_to_utf8 (basename_nosuffix(*e))));
|
std::string color_name = basename_nosuffix(*e);
|
||||||
|
size_t sep = color_name.find_first_of("-");
|
||||||
|
if (sep != string::npos) {
|
||||||
|
color_name = color_name.substr (0, sep);
|
||||||
|
}
|
||||||
|
themes.insert (make_pair (prop->value(), color_name));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue