mirror of
https://github.com/cjcliffe/CubicSDR.git
synced 2025-09-15 13:07:58 -04:00
Use Google Turbo Color for Default Theme WF colors (#748)
* Use Google Turbo Color for Default Theme WF colors * Added Default Jet Waterfall as the old WF color theme * Oups duplicate IDs for widgets is wrong
This commit is contained in:
parent
e0d1e2b6ff
commit
4f7dcd4d89
@ -603,6 +603,7 @@ wxMenu *AppFrame::makeDisplayMenu() {
|
|||||||
int themeId = wxGetApp().getConfig()->getTheme();
|
int themeId = wxGetApp().getConfig()->getTheme();
|
||||||
|
|
||||||
themeMenu->AppendRadioItem(wxID_THEME_DEFAULT, "Default")->Check(themeId==COLOR_THEME_DEFAULT);
|
themeMenu->AppendRadioItem(wxID_THEME_DEFAULT, "Default")->Check(themeId==COLOR_THEME_DEFAULT);
|
||||||
|
themeMenu->AppendRadioItem(wxID_THEME_DEFAULT_JET, "Default (Jet Waterfall)")->Check(themeId == COLOR_THEME_DEFAULT_JET);
|
||||||
themeMenu->AppendRadioItem(wxID_THEME_RADAR, "RADAR")->Check(themeId==COLOR_THEME_RADAR);
|
themeMenu->AppendRadioItem(wxID_THEME_RADAR, "RADAR")->Check(themeId==COLOR_THEME_RADAR);
|
||||||
themeMenu->AppendRadioItem(wxID_THEME_BW, "Black & White")->Check(themeId==COLOR_THEME_BW);
|
themeMenu->AppendRadioItem(wxID_THEME_BW, "Black & White")->Check(themeId==COLOR_THEME_BW);
|
||||||
themeMenu->AppendRadioItem(wxID_THEME_SHARP, "Sharp")->Check(themeId==COLOR_THEME_SHARP);
|
themeMenu->AppendRadioItem(wxID_THEME_SHARP, "Sharp")->Check(themeId==COLOR_THEME_SHARP);
|
||||||
@ -1316,10 +1317,13 @@ bool AppFrame::actionOnMenuDisplay(wxCommandEvent& event) {
|
|||||||
|
|
||||||
//by default, is managed.
|
//by default, is managed.
|
||||||
bool bManaged = true;
|
bool bManaged = true;
|
||||||
|
|
||||||
if (event.GetId() == wxID_THEME_DEFAULT) {
|
if (event.GetId() == wxID_THEME_DEFAULT) {
|
||||||
ThemeMgr::mgr.setTheme(COLOR_THEME_DEFAULT);
|
ThemeMgr::mgr.setTheme(COLOR_THEME_DEFAULT);
|
||||||
}
|
}
|
||||||
|
else if (event.GetId() == wxID_THEME_DEFAULT_JET) {
|
||||||
|
ThemeMgr::mgr.setTheme(COLOR_THEME_DEFAULT_JET);
|
||||||
|
}
|
||||||
else if (event.GetId() == wxID_THEME_SHARP) {
|
else if (event.GetId() == wxID_THEME_SHARP) {
|
||||||
ThemeMgr::mgr.setTheme(COLOR_THEME_SHARP);
|
ThemeMgr::mgr.setTheme(COLOR_THEME_SHARP);
|
||||||
}
|
}
|
||||||
|
@ -337,15 +337,16 @@ private:
|
|||||||
#define wxID_VIS_SPLITTER 2051
|
#define wxID_VIS_SPLITTER 2051
|
||||||
#define wxID_BM_SPLITTER 2052
|
#define wxID_BM_SPLITTER 2052
|
||||||
|
|
||||||
#define wxID_THEME_DEFAULT 2100
|
#define wxID_THEME_DEFAULT 2070
|
||||||
#define wxID_THEME_SHARP 2101
|
#define wxID_THEME_DEFAULT_JET 2071
|
||||||
#define wxID_THEME_BW 2102
|
#define wxID_THEME_SHARP 2072
|
||||||
#define wxID_THEME_RAD 2103
|
#define wxID_THEME_BW 2073
|
||||||
#define wxID_THEME_TOUCH 2104
|
#define wxID_THEME_RAD 2074
|
||||||
#define wxID_THEME_HD 2105
|
#define wxID_THEME_TOUCH 2075
|
||||||
#define wxID_THEME_RADAR 2106
|
#define wxID_THEME_HD 2076
|
||||||
|
#define wxID_THEME_RADAR 2077
|
||||||
|
|
||||||
#define wxID_DISPLAY_BOOKMARKS 2107
|
#define wxID_DISPLAY_BOOKMARKS 2100
|
||||||
|
|
||||||
#define wxID_BANDWIDTH_BASE 2150
|
#define wxID_BANDWIDTH_BASE 2150
|
||||||
#define wxID_BANDWIDTH_MANUAL_DIALOG 2199
|
#define wxID_BANDWIDTH_MANUAL_DIALOG 2199
|
||||||
|
@ -5,13 +5,25 @@
|
|||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
|
||||||
Gradient::Gradient() {
|
Gradient::Gradient() {
|
||||||
|
//nothing
|
||||||
|
}
|
||||||
|
|
||||||
|
void Gradient::clear() {
|
||||||
|
colors.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
void Gradient::addColor(GradientColor c) {
|
void Gradient::addColor(GradientColor c) {
|
||||||
colors.push_back(c);
|
colors.push_back(c);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Gradient::addColors(const std::vector<GradientColor>& color_list) {
|
||||||
|
|
||||||
|
for (auto single_color : color_list) {
|
||||||
|
|
||||||
|
colors.push_back(single_color);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
std::vector<float> &Gradient::getRed() {
|
std::vector<float> &Gradient::getRed() {
|
||||||
return r_val;
|
return r_val;
|
||||||
}
|
}
|
||||||
|
@ -21,6 +21,10 @@ public:
|
|||||||
|
|
||||||
void addColor(GradientColor c);
|
void addColor(GradientColor c);
|
||||||
|
|
||||||
|
void clear();
|
||||||
|
|
||||||
|
void addColors(const std::vector<GradientColor>& color_list);
|
||||||
|
|
||||||
std::vector<float> &getRed();
|
std::vector<float> &getRed();
|
||||||
std::vector<float> &getGreen();
|
std::vector<float> &getGreen();
|
||||||
std::vector<float> &getBlue();
|
std::vector<float> &getBlue();
|
||||||
|
File diff suppressed because one or more lines are too long
@ -11,13 +11,14 @@
|
|||||||
#include <wx/colour.h>
|
#include <wx/colour.h>
|
||||||
|
|
||||||
#define COLOR_THEME_DEFAULT 0
|
#define COLOR_THEME_DEFAULT 0
|
||||||
#define COLOR_THEME_BW 1
|
#define COLOR_THEME_DEFAULT_JET 1
|
||||||
#define COLOR_THEME_SHARP 2
|
#define COLOR_THEME_BW 2
|
||||||
#define COLOR_THEME_RAD 3
|
#define COLOR_THEME_SHARP 3
|
||||||
#define COLOR_THEME_TOUCH 4
|
#define COLOR_THEME_RAD 4
|
||||||
#define COLOR_THEME_HD 5
|
#define COLOR_THEME_TOUCH 5
|
||||||
#define COLOR_THEME_RADAR 6
|
#define COLOR_THEME_HD 6
|
||||||
#define COLOR_THEME_MAX 7
|
#define COLOR_THEME_RADAR 7
|
||||||
|
#define COLOR_THEME_MAX 8
|
||||||
|
|
||||||
class RGBA4f {
|
class RGBA4f {
|
||||||
public:
|
public:
|
||||||
@ -101,6 +102,11 @@ public:
|
|||||||
DefaultColorTheme();
|
DefaultColorTheme();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
class DefaultColorThemeJet : public DefaultColorTheme {
|
||||||
|
public:
|
||||||
|
DefaultColorThemeJet();
|
||||||
|
};
|
||||||
|
|
||||||
class BlackAndWhiteColorTheme: public ColorTheme {
|
class BlackAndWhiteColorTheme: public ColorTheme {
|
||||||
public:
|
public:
|
||||||
BlackAndWhiteColorTheme();
|
BlackAndWhiteColorTheme();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user