mirror of
https://github.com/Serial-Studio/Serial-Studio.git
synced 2025-01-15 05:22:53 +08:00
Cleanup themes
This commit is contained in:
parent
4779f704bb
commit
7f2a25a3ad
@ -37,7 +37,7 @@ Widgets.Window {
|
||||
title: qsTr("View")
|
||||
headerDoubleClickEnabled: false
|
||||
icon.source: "qrc:/icons/visibility.svg"
|
||||
backgroundColor: Cpp_ThemeManager.embeddedWindowBackground
|
||||
backgroundColor: Cpp_ThemeManager.paneWindowBackground
|
||||
|
||||
//
|
||||
// Maps the slider position to points
|
||||
|
@ -38,7 +38,7 @@ Item {
|
||||
anchors.fill: parent
|
||||
title: loader.widgetTitle
|
||||
icon.source: loader.widgetIcon
|
||||
borderColor: Cpp_ThemeManager.datasetWindowBorder
|
||||
borderColor: Cpp_ThemeManager.widgetWindowBorder
|
||||
onHeaderDoubleClicked: externalWindow.visible = true
|
||||
|
||||
WidgetLoader {
|
||||
@ -58,8 +58,8 @@ Item {
|
||||
minimumWidth: 640
|
||||
minimumHeight: 480
|
||||
title: externalLoader.widgetTitle
|
||||
palette.base: Cpp_ThemeManager.datasetWindowBackground
|
||||
palette.window: Cpp_ThemeManager.datasetWindowBackground
|
||||
palette.base: Cpp_ThemeManager.widgetWindowBackground
|
||||
palette.window: Cpp_ThemeManager.widgetWindowBackground
|
||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||
|
||||
WidgetLoader {
|
||||
|
@ -36,7 +36,7 @@ Widgets.Window {
|
||||
title: qsTr("Data")
|
||||
headerDoubleClickEnabled: false
|
||||
icon.source: "qrc:/icons/dataset.svg"
|
||||
backgroundColor: Cpp_ThemeManager.embeddedWindowBackground
|
||||
backgroundColor: Cpp_ThemeManager.paneWindowBackground
|
||||
|
||||
// Hacks for calculating cell width
|
||||
readonly property int cellHeight: cellWidth * (2/3)
|
||||
|
@ -34,8 +34,8 @@ Widgets.Window {
|
||||
//
|
||||
headerDoubleClickEnabled: false
|
||||
icon.source: "qrc:/icons/dataset.svg"
|
||||
borderColor: Cpp_ThemeManager.datasetWindowBorder
|
||||
palette.window: Cpp_ThemeManager.datasetWindowBackground
|
||||
borderColor: Cpp_ThemeManager.widgetWindowBorder
|
||||
palette.window: Cpp_ThemeManager.widgetWindowBackground
|
||||
title: qsTr("Dataset %1 - %2").arg(dataset + 1).arg(Cpp_JSON_Editor.datasetTitle(group, dataset))
|
||||
|
||||
//
|
||||
|
@ -36,7 +36,7 @@ Widgets.Window {
|
||||
Layout.minimumHeight: height
|
||||
headerDoubleClickEnabled: false
|
||||
icon.source: "qrc:/icons/group.svg"
|
||||
backgroundColor: Cpp_ThemeManager.embeddedWindowBackground
|
||||
backgroundColor: Cpp_ThemeManager.paneWindowBackground
|
||||
height: column.implicitHeight + headerHeight + 4 * app.spacing
|
||||
title: qsTr("Group %1 - %2").arg(group + 1).arg(Cpp_JSON_Editor.groupTitle(group))
|
||||
|
||||
|
@ -122,7 +122,7 @@ Item {
|
||||
headerDoubleClickEnabled: false
|
||||
icon.source: "qrc:/icons/code.svg"
|
||||
anchors.margins: app.spacing * 1.5
|
||||
backgroundColor: Cpp_ThemeManager.embeddedWindowBackground
|
||||
backgroundColor: Cpp_ThemeManager.paneWindowBackground
|
||||
|
||||
//
|
||||
// Right-click context menu
|
||||
|
@ -136,7 +136,7 @@ Item {
|
||||
headerDoubleClickEnabled: false
|
||||
anchors.margins: app.spacing * 1.5
|
||||
icon.source: "qrc:/icons/settings.svg"
|
||||
backgroundColor: Cpp_ThemeManager.embeddedWindowBackground
|
||||
backgroundColor: Cpp_ThemeManager.paneWindowBackground
|
||||
|
||||
//
|
||||
// Control arrangement
|
||||
@ -210,7 +210,7 @@ Item {
|
||||
Layout.alignment: Qt.AlignVCenter
|
||||
checked: Cpp_CSV_Export.exportEnabled
|
||||
Layout.maximumWidth: root.maxItemWidth
|
||||
palette.highlight: Cpp_ThemeManager.csvHighlight
|
||||
palette.highlight: Cpp_ThemeManager.csvCheckbox
|
||||
|
||||
onCheckedChanged: {
|
||||
if (Cpp_CSV_Export.exportEnabled !== checked)
|
||||
|
@ -43,7 +43,7 @@ Page {
|
||||
property bool altButtonEnabled: false
|
||||
property alias altButtonIcon: altBt.icon
|
||||
property alias headerDoubleClickEnabled: headerMouseArea.enabled
|
||||
property color backgroundColor: Cpp_ThemeManager.datasetWindowBackground
|
||||
property color backgroundColor: Cpp_ThemeManager.widgetWindowBackground
|
||||
property color gradientColor1: root.gradient ? Cpp_ThemeManager.windowGradient1 :
|
||||
root.borderColor
|
||||
property color gradientColor2: root.gradient ? Cpp_ThemeManager.windowGradient2 :
|
||||
|
@ -35,33 +35,28 @@
|
||||
"windowGradient2":"#323030",
|
||||
"alternativeHighlight":"#42b554",
|
||||
"setupPanelBackground":"#f2f2f2",
|
||||
"datasetValue":"#dd3224",
|
||||
"graphDialBorder":"#222222",
|
||||
"datasetTextPrimary":"#24476a",
|
||||
"datasetTextSecondary":"#666666",
|
||||
"datasetWindowBackground":"#ffffff",
|
||||
"datasetWindowBorder":"#62676a",
|
||||
"embeddedWindowBackground":"#ffffff",
|
||||
"paneWindowBackground":"#ffffff",
|
||||
"ledEnabled":"#26cd40",
|
||||
"ledDisabled":"#686868",
|
||||
"csvHighlight":"#2e895c",
|
||||
"widgetForegroundPrimary":"#f94144",
|
||||
"widgetForegroundSecondary":"#666666",
|
||||
"widgetIndicator1":"#444444",
|
||||
"widgetIndicator2":"#f94144",
|
||||
"widgetIndicator3":"#90be6d",
|
||||
"widgetAlternativeBackground":"#fafafa",
|
||||
"widgetControlBackground":"#666666",
|
||||
"csvCheckbox":"#2e895c",
|
||||
"connectButtonChecked":"#d72d60",
|
||||
"connectButtonUnchecked":"#2eed5c",
|
||||
"widgetTextPrimary":"#24476a",
|
||||
"widgetTextSecondary":"#666666",
|
||||
"widgetWindowBackground":"#f2f2f2",
|
||||
"widgetWindowBorder":"#62676a",
|
||||
"widgetForegroundPrimary":"#f94144",
|
||||
"widgetForegroundSecondary":"#666666",
|
||||
"widgetIndicator":"#444444",
|
||||
"widgetControlBackground":"#666666",
|
||||
"widgetColors":[
|
||||
"#f94144",
|
||||
"#f3722c",
|
||||
"#f8961e",
|
||||
"#f9844a",
|
||||
"#f9c74f",
|
||||
"#90be6d",
|
||||
"#43aa8b",
|
||||
"#0172bd",
|
||||
"#d9531a",
|
||||
"#ecb120",
|
||||
"#7d2f8e",
|
||||
"#77ab30",
|
||||
"#4dbeee",
|
||||
"#a21330",
|
||||
"#4d908e",
|
||||
"#577590",
|
||||
"#277da1"
|
@ -35,33 +35,28 @@
|
||||
"windowGradient2":"#058ca7",
|
||||
"alternativeHighlight":"#d72d60",
|
||||
"setupPanelBackground":"#16232a",
|
||||
"datasetValue":"#e6e0b2",
|
||||
"graphDialBorder":"#eeeeee",
|
||||
"datasetTextPrimary":"#e6e0b2",
|
||||
"datasetTextSecondary":"#517497",
|
||||
"datasetWindowBackground":"#121920",
|
||||
"datasetWindowBorder":"#517497",
|
||||
"embeddedWindowBackground":"#121218",
|
||||
"paneWindowBackground":"#121218",
|
||||
"ledEnabled":"#d72d60",
|
||||
"ledDisabled":"#2d6073",
|
||||
"csvHighlight":"#2e895c",
|
||||
"widgetForegroundPrimary":"#8ecd9d",
|
||||
"widgetForegroundSecondary":"#517497",
|
||||
"widgetIndicator1":"#e6e0b2",
|
||||
"widgetIndicator2":"#d72d60",
|
||||
"widgetIndicator3":"#2d6073",
|
||||
"widgetAlternativeBackground":"#121218",
|
||||
"csvCheckbox":"#2e895c",
|
||||
"widgetControlBackground":"#bebebe",
|
||||
"connectButtonChecked":"#d72d60",
|
||||
"connectButtonUnchecked":"#2eed5c",
|
||||
"widgetTextPrimary":"#e6e0b2",
|
||||
"widgetTextSecondary":"#517497",
|
||||
"widgetWindowBackground":"#121920",
|
||||
"widgetWindowBorder":"#517497",
|
||||
"widgetForegroundPrimary":"#8ecd9d",
|
||||
"widgetForegroundSecondary":"#517497",
|
||||
"widgetIndicator":"#e6e0b2",
|
||||
"widgetColors":[
|
||||
"#f94144",
|
||||
"#f3722c",
|
||||
"#f8961e",
|
||||
"#f9844a",
|
||||
"#f9c74f",
|
||||
"#90be6d",
|
||||
"#43aa8b",
|
||||
"#0172bd",
|
||||
"#d9531a",
|
||||
"#ecb120",
|
||||
"#7d2f8e",
|
||||
"#77ab30",
|
||||
"#4dbeee",
|
||||
"#a21330",
|
||||
"#4d908e",
|
||||
"#577590",
|
||||
"#277da1"
|
@ -35,33 +35,28 @@
|
||||
"windowGradient2":"#004077",
|
||||
"alternativeHighlight":"#53ab27",
|
||||
"setupPanelBackground":"#e8e8e8",
|
||||
"datasetValue":"#dd3224",
|
||||
"graphDialBorder":"#222222",
|
||||
"datasetTextPrimary":"#24476a",
|
||||
"datasetTextSecondary":"#666666",
|
||||
"datasetWindowBackground":"#e8e8e8",
|
||||
"datasetWindowBorder":"#336698",
|
||||
"embeddedWindowBackground":"#f1f1f1",
|
||||
"paneWindowBackground":"#f1f1f1",
|
||||
"ledEnabled":"#0072C3",
|
||||
"ledDisabled":"#686868",
|
||||
"csvHighlight":"#2e895c",
|
||||
"widgetForegroundPrimary":"#f94144",
|
||||
"widgetForegroundSecondary":"#666666",
|
||||
"widgetIndicator1":"#444444",
|
||||
"widgetIndicator2":"#f94144",
|
||||
"widgetIndicator3":"#90be6d",
|
||||
"widgetAlternativeBackground":"#fafafa",
|
||||
"widgetControlBackground":"#666666",
|
||||
"csvCheckbox":"#2e895c",
|
||||
"connectButtonChecked":"#fe696e",
|
||||
"connectButtonUnchecked":"#26cd40",
|
||||
"widgetTextPrimary":"#24476a",
|
||||
"widgetTextSecondary":"#666666",
|
||||
"widgetWindowBackground":"#e8e8e8",
|
||||
"widgetWindowBorder":"#336698",
|
||||
"widgetForegroundPrimary":"#f94144",
|
||||
"widgetForegroundSecondary":"#666666",
|
||||
"widgetIndicator":"#444444",
|
||||
"widgetControlBackground":"#666666",
|
||||
"widgetColors":[
|
||||
"#f94144",
|
||||
"#f3722c",
|
||||
"#f8961e",
|
||||
"#f9844a",
|
||||
"#f9c74f",
|
||||
"#90be6d",
|
||||
"#43aa8b",
|
||||
"#0172bd",
|
||||
"#d9531a",
|
||||
"#ecb120",
|
||||
"#7d2f8e",
|
||||
"#77ab30",
|
||||
"#4dbeee",
|
||||
"#a21330",
|
||||
"#4d908e",
|
||||
"#577590",
|
||||
"#277da1"
|
@ -1,7 +1,7 @@
|
||||
<RCC>
|
||||
<qresource prefix="/themes">
|
||||
<file>1_Light.json</file>
|
||||
<file>0_Dark.json</file>
|
||||
<file>2_Noir.json</file>
|
||||
<file>2_MathWorks.json</file>
|
||||
<file>1_Classic.json</file>
|
||||
<file>0_Noir.json</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
@ -171,22 +171,17 @@ void ThemeManager::loadTheme(const int id)
|
||||
m_dialogBackground = QColor(colors.value("dialogBackground").toString());
|
||||
m_alternativeHighlight = QColor(colors.value("alternativeHighlight").toString());
|
||||
m_setupPanelBackground = QColor(colors.value("setupPanelBackground").toString());
|
||||
m_datasetValue = QColor(colors.value("datasetValue").toString());
|
||||
m_graphDialBorder = QColor(colors.value("graphDialBorder").toString());
|
||||
m_datasetTextPrimary = QColor(colors.value("datasetTextPrimary").toString());
|
||||
m_datasetTextSecondary = QColor(colors.value("datasetTextSecondary").toString());
|
||||
m_datasetWindowBackground = QColor(colors.value("datasetWindowBackground").toString());
|
||||
m_datasetWindowBorder = QColor(colors.value("datasetWindowBorder").toString());
|
||||
m_embeddedWindowBackground = QColor(colors.value("embeddedWindowBackground").toString());
|
||||
m_widgetTextPrimary = QColor(colors.value("widgetTextPrimary").toString());
|
||||
m_widgetTextSecondary = QColor(colors.value("widgetTextSecondary").toString());
|
||||
m_widgetWindowBackground = QColor(colors.value("widgetWindowBackground").toString());
|
||||
m_widgetWindowBorder = QColor(colors.value("widgetWindowBorder").toString());
|
||||
m_paneWindowBackground = QColor(colors.value("paneWindowBackground").toString());
|
||||
m_ledEnabled = QColor(colors.value("ledEnabled").toString());
|
||||
m_ledDisabled = QColor(colors.value("ledDisabled").toString());
|
||||
m_csvHighlight = QColor(colors.value("csvHighlight").toString());
|
||||
m_csvCheckbox = QColor(colors.value("csvCheckbox").toString());
|
||||
m_widgetForegroundPrimary = QColor(colors.value("widgetForegroundPrimary").toString());
|
||||
m_widgetForegroundSecondary = QColor(colors.value("widgetForegroundSecondary").toString());
|
||||
m_widgetIndicator1 = QColor(colors.value("widgetIndicator1").toString());
|
||||
m_widgetIndicator2 = QColor(colors.value("widgetIndicator2").toString());
|
||||
m_widgetIndicator3 = QColor(colors.value("widgetIndicator3").toString());
|
||||
m_widgetAlternativeBackground = QColor(colors.value("widgetAlternativeBackground").toString());
|
||||
m_widgetIndicator = QColor(colors.value("widgetIndicator").toString());
|
||||
m_widgetControlBackground = QColor(colors.value("widgetControlBackground").toString());
|
||||
m_connectButtonChecked = QColor(colors.value("connectButtonChecked").toString());
|
||||
m_connectButtonUnchecked = QColor(colors.value("connectButtonUnchecked").toString());
|
||||
@ -429,39 +424,29 @@ QColor ThemeManager::setupPanelBackground() const
|
||||
return m_setupPanelBackground;
|
||||
}
|
||||
|
||||
QColor ThemeManager::datasetValue() const
|
||||
QColor ThemeManager::widgetTextPrimary() const
|
||||
{
|
||||
return m_datasetValue;
|
||||
return m_widgetTextPrimary;
|
||||
}
|
||||
|
||||
QColor ThemeManager::graphDialBorder() const
|
||||
QColor ThemeManager::widgetTextSecondary() const
|
||||
{
|
||||
return m_graphDialBorder;
|
||||
return m_widgetTextSecondary;
|
||||
}
|
||||
|
||||
QColor ThemeManager::datasetTextPrimary() const
|
||||
QColor ThemeManager::widgetWindowBackground() const
|
||||
{
|
||||
return m_datasetTextPrimary;
|
||||
return m_widgetWindowBackground;
|
||||
}
|
||||
|
||||
QColor ThemeManager::datasetTextSecondary() const
|
||||
QColor ThemeManager::widgetWindowBorder() const
|
||||
{
|
||||
return m_datasetTextSecondary;
|
||||
return m_widgetWindowBorder;
|
||||
}
|
||||
|
||||
QColor ThemeManager::datasetWindowBackground() const
|
||||
QColor ThemeManager::paneWindowBackground() const
|
||||
{
|
||||
return m_datasetWindowBackground;
|
||||
}
|
||||
|
||||
QColor ThemeManager::datasetWindowBorder() const
|
||||
{
|
||||
return m_datasetWindowBorder;
|
||||
}
|
||||
|
||||
QColor ThemeManager::embeddedWindowBackground() const
|
||||
{
|
||||
return m_embeddedWindowBackground;
|
||||
return m_paneWindowBackground;
|
||||
}
|
||||
|
||||
QColor ThemeManager::ledEnabled() const
|
||||
@ -474,9 +459,9 @@ QColor ThemeManager::ledDisabled() const
|
||||
return m_ledDisabled;
|
||||
}
|
||||
|
||||
QColor ThemeManager::csvHighlight() const
|
||||
QColor ThemeManager::csvCheckbox() const
|
||||
{
|
||||
return m_csvHighlight;
|
||||
return m_csvCheckbox;
|
||||
}
|
||||
|
||||
QColor ThemeManager::widgetForegroundPrimary() const
|
||||
@ -489,24 +474,9 @@ QColor ThemeManager::widgetForegroundSecondary() const
|
||||
return m_widgetForegroundSecondary;
|
||||
}
|
||||
|
||||
QColor ThemeManager::widgetIndicator1() const
|
||||
QColor ThemeManager::widgetIndicator() const
|
||||
{
|
||||
return m_widgetIndicator1;
|
||||
}
|
||||
|
||||
QColor ThemeManager::widgetIndicator2() const
|
||||
{
|
||||
return m_widgetIndicator2;
|
||||
}
|
||||
|
||||
QColor ThemeManager::widgetIndicator3() const
|
||||
{
|
||||
return m_widgetIndicator3;
|
||||
}
|
||||
|
||||
QColor ThemeManager::widgetAlternativeBackground() const
|
||||
{
|
||||
return m_widgetAlternativeBackground;
|
||||
return m_widgetIndicator;
|
||||
}
|
||||
|
||||
QColor ThemeManager::widgetControlBackground() const
|
||||
|
@ -135,26 +135,20 @@ class ThemeManager : public QObject
|
||||
Q_PROPERTY(QColor setupPanelBackground
|
||||
READ setupPanelBackground
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor datasetValue
|
||||
READ datasetValue
|
||||
Q_PROPERTY(QColor widgetTextPrimary
|
||||
READ widgetTextPrimary
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor graphDialBorder
|
||||
READ graphDialBorder
|
||||
Q_PROPERTY(QColor widgetTextSecondary
|
||||
READ widgetTextSecondary
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor datasetTextPrimary
|
||||
READ datasetTextPrimary
|
||||
Q_PROPERTY(QColor widgetWindowBackground
|
||||
READ widgetWindowBackground
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor datasetTextSecondary
|
||||
READ datasetTextSecondary
|
||||
Q_PROPERTY(QColor widgetWindowBorder
|
||||
READ widgetWindowBorder
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor datasetWindowBackground
|
||||
READ datasetWindowBackground
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor datasetWindowBorder
|
||||
READ datasetWindowBorder
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor embeddedWindowBackground
|
||||
READ embeddedWindowBackground
|
||||
Q_PROPERTY(QColor paneWindowBackground
|
||||
READ paneWindowBackground
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor ledEnabled
|
||||
READ ledEnabled
|
||||
@ -162,8 +156,8 @@ class ThemeManager : public QObject
|
||||
Q_PROPERTY(QColor ledDisabled
|
||||
READ ledDisabled
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor csvHighlight
|
||||
READ csvHighlight
|
||||
Q_PROPERTY(QColor csvCheckbox
|
||||
READ csvCheckbox
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor widgetForegroundPrimary
|
||||
READ widgetForegroundPrimary
|
||||
@ -171,17 +165,8 @@ class ThemeManager : public QObject
|
||||
Q_PROPERTY(QColor widgetForegroundSecondary
|
||||
READ widgetForegroundSecondary
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor widgetIndicator1
|
||||
READ widgetIndicator1
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor widgetIndicator2
|
||||
READ widgetIndicator2
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor widgetIndicator3
|
||||
READ widgetIndicator3
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor widgetAlternativeBackground
|
||||
READ widgetAlternativeBackground
|
||||
Q_PROPERTY(QColor widgetIndicator
|
||||
READ widgetIndicator
|
||||
NOTIFY themeChanged)
|
||||
Q_PROPERTY(QColor widgetControlBackground
|
||||
READ widgetControlBackground
|
||||
@ -242,22 +227,17 @@ public:
|
||||
QColor windowGradient2() const;
|
||||
QColor alternativeHighlight() const;
|
||||
QColor setupPanelBackground() const;
|
||||
QColor datasetValue() const;
|
||||
QColor graphDialBorder() const;
|
||||
QColor datasetTextPrimary() const;
|
||||
QColor datasetTextSecondary() const;
|
||||
QColor datasetWindowBackground() const;
|
||||
QColor datasetWindowBorder() const;
|
||||
QColor embeddedWindowBackground() const;
|
||||
QColor widgetTextPrimary() const;
|
||||
QColor widgetTextSecondary() const;
|
||||
QColor widgetWindowBackground() const;
|
||||
QColor widgetWindowBorder() const;
|
||||
QColor paneWindowBackground() const;
|
||||
QColor ledEnabled() const;
|
||||
QColor ledDisabled() const;
|
||||
QColor csvHighlight() const;
|
||||
QColor csvCheckbox() const;
|
||||
QColor widgetForegroundPrimary() const;
|
||||
QColor widgetForegroundSecondary() const;
|
||||
QColor widgetIndicator1() const;
|
||||
QColor widgetIndicator2() const;
|
||||
QColor widgetIndicator3() const;
|
||||
QColor widgetAlternativeBackground() const;
|
||||
QColor widgetIndicator() const;
|
||||
QColor widgetControlBackground() const;
|
||||
QColor connectButtonChecked() const;
|
||||
QColor connectButtonUnchecked() const;
|
||||
@ -314,22 +294,17 @@ private:
|
||||
QColor m_windowGradient2;
|
||||
QColor m_alternativeHighlight;
|
||||
QColor m_setupPanelBackground;
|
||||
QColor m_datasetValue;
|
||||
QColor m_graphDialBorder;
|
||||
QColor m_datasetTextPrimary;
|
||||
QColor m_datasetTextSecondary;
|
||||
QColor m_datasetWindowBackground;
|
||||
QColor m_datasetWindowBorder;
|
||||
QColor m_embeddedWindowBackground;
|
||||
QColor m_widgetTextPrimary;
|
||||
QColor m_widgetTextSecondary;
|
||||
QColor m_widgetWindowBackground;
|
||||
QColor m_widgetWindowBorder;
|
||||
QColor m_paneWindowBackground;
|
||||
QColor m_ledEnabled;
|
||||
QColor m_ledDisabled;
|
||||
QColor m_csvHighlight;
|
||||
QColor m_csvCheckbox;
|
||||
QColor m_widgetForegroundPrimary;
|
||||
QColor m_widgetForegroundSecondary;
|
||||
QColor m_widgetIndicator1;
|
||||
QColor m_widgetIndicator2;
|
||||
QColor m_widgetIndicator3;
|
||||
QColor m_widgetAlternativeBackground;
|
||||
QColor m_widgetIndicator;
|
||||
QColor m_widgetControlBackground;
|
||||
QColor m_connectButtonChecked;
|
||||
QColor m_connectButtonUnchecked;
|
||||
|
@ -63,7 +63,7 @@ Accelerometer::Accelerometer(const int index)
|
||||
// Set gauge palette
|
||||
QPalette palette;
|
||||
palette.setColor(QPalette::WindowText, theme->base());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator());
|
||||
m_gauge.setPalette(palette);
|
||||
|
||||
// Set widget pointer
|
||||
|
@ -46,11 +46,11 @@ Bar::Bar(const int index)
|
||||
QPalette palette;
|
||||
palette.setColor(QPalette::Base, theme->base());
|
||||
palette.setColor(QPalette::Highlight, QColor("#f00"));
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Dark, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Light, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::ButtonText, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::WindowText, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::Dark, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::Light, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::ButtonText, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::WindowText, theme->widgetIndicator());
|
||||
m_thermo.setPalette(palette);
|
||||
|
||||
// Get thermo color
|
||||
|
@ -35,8 +35,8 @@ BaseWidget::BaseWidget()
|
||||
// Set window palette
|
||||
QPalette palette;
|
||||
auto theme = Misc::ThemeManager::getInstance();
|
||||
palette.setColor(QPalette::Base, theme->datasetWindowBackground());
|
||||
palette.setColor(QPalette::Window, theme->datasetWindowBackground());
|
||||
palette.setColor(QPalette::Base, theme->widgetWindowBackground());
|
||||
palette.setColor(QPalette::Window, theme->widgetWindowBackground());
|
||||
setPalette(palette);
|
||||
|
||||
// Configure label style
|
||||
@ -47,7 +47,7 @@ BaseWidget::BaseWidget()
|
||||
auto valueQSS = QSS("background-color:%1; color:%2; border:1px solid %3;",
|
||||
theme->base(),
|
||||
theme->widgetForegroundPrimary(),
|
||||
theme->widgetIndicator1());
|
||||
theme->widgetIndicator());
|
||||
m_label.setStyleSheet(valueQSS);
|
||||
// clang-format on
|
||||
}
|
||||
|
@ -62,7 +62,7 @@ Compass::Compass(const int index)
|
||||
// Set compass palette
|
||||
QPalette palette;
|
||||
palette.setColor(QPalette::WindowText, theme->base());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator());
|
||||
m_compass.setPalette(palette);
|
||||
|
||||
// Set widget pointer
|
||||
|
@ -53,15 +53,15 @@ DataGroup::DataGroup(const int index)
|
||||
return;
|
||||
|
||||
// Generate widget stylesheets
|
||||
auto titleQSS = QSS("color:%1", theme->datasetTextPrimary());
|
||||
auto unitsQSS = QSS("color:%1", theme->datasetTextSecondary());
|
||||
auto titleQSS = QSS("color:%1", theme->widgetTextPrimary());
|
||||
auto unitsQSS = QSS("color:%1", theme->widgetTextSecondary());
|
||||
auto valueQSS = QSS("color:%1", theme->widgetForegroundPrimary());
|
||||
auto iconsQSS = QSS("color:%1; font-weight:600;", theme->datasetTextSecondary());
|
||||
auto iconsQSS = QSS("color:%1; font-weight:600;", theme->widgetTextSecondary());
|
||||
|
||||
// Set window palette
|
||||
QPalette windowPalette;
|
||||
windowPalette.setColor(QPalette::Base, theme->datasetWindowBackground());
|
||||
windowPalette.setColor(QPalette::Window, theme->datasetWindowBackground());
|
||||
windowPalette.setColor(QPalette::Base, theme->widgetWindowBackground());
|
||||
windowPalette.setColor(QPalette::Window, theme->widgetWindowBackground());
|
||||
setPalette(windowPalette);
|
||||
|
||||
// Configure scroll area container
|
||||
|
@ -65,7 +65,7 @@ Gauge::Gauge(const int index)
|
||||
// Set gauge palette
|
||||
QPalette palette;
|
||||
palette.setColor(QPalette::WindowText, theme->base());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator());
|
||||
m_gauge.setPalette(palette);
|
||||
|
||||
// Set widget pointer
|
||||
|
@ -46,7 +46,7 @@ Gyroscope::Gyroscope(const int index)
|
||||
// Set gauge palette
|
||||
QPalette palette;
|
||||
palette.setColor(QPalette::WindowText, theme->base());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator());
|
||||
m_gauge.setPalette(palette);
|
||||
|
||||
// Set widget pointer
|
||||
|
@ -43,18 +43,18 @@ MultiPlot::MultiPlot(const int index)
|
||||
|
||||
// Set window palette
|
||||
QPalette palette;
|
||||
palette.setColor(QPalette::Base, theme->datasetWindowBackground());
|
||||
palette.setColor(QPalette::Window, theme->datasetWindowBackground());
|
||||
palette.setColor(QPalette::Base, theme->widgetWindowBackground());
|
||||
palette.setColor(QPalette::Window, theme->widgetWindowBackground());
|
||||
setPalette(palette);
|
||||
|
||||
// Set plot palette
|
||||
palette.setColor(QPalette::Base, theme->base());
|
||||
palette.setColor(QPalette::Highlight, QColor("#f00"));
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Dark, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Light, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::ButtonText, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::WindowText, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::Dark, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::Light, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::ButtonText, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::WindowText, theme->widgetIndicator());
|
||||
m_plot.setPalette(palette);
|
||||
m_plot.setCanvasBackground(theme->base());
|
||||
m_plot.setFrameStyle(QFrame::Plain);
|
||||
@ -112,7 +112,7 @@ MultiPlot::MultiPlot(const int index)
|
||||
*
|
||||
* If the widget is disabled (e.g. the user hides it, or the external
|
||||
* window is hidden), then the new data shall be saved to the plot
|
||||
* vector, but the widget shall not be redrawn.
|
||||
* vectors, but the widget shall not be redrawn.
|
||||
*/
|
||||
void MultiPlot::updateData()
|
||||
{
|
||||
|
@ -43,18 +43,18 @@ Plot::Plot(const int index)
|
||||
|
||||
// Set window palette
|
||||
QPalette palette;
|
||||
palette.setColor(QPalette::Base, theme->datasetWindowBackground());
|
||||
palette.setColor(QPalette::Window, theme->datasetWindowBackground());
|
||||
palette.setColor(QPalette::Base, theme->widgetWindowBackground());
|
||||
palette.setColor(QPalette::Window, theme->widgetWindowBackground());
|
||||
setPalette(palette);
|
||||
|
||||
// Set plot palette
|
||||
palette.setColor(QPalette::Base, theme->base());
|
||||
palette.setColor(QPalette::Highlight, QColor("#f00"));
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Dark, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Light, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::ButtonText, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::WindowText, theme->widgetIndicator1());
|
||||
palette.setColor(QPalette::Text, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::Dark, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::Light, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::ButtonText, theme->widgetIndicator());
|
||||
palette.setColor(QPalette::WindowText, theme->widgetIndicator());
|
||||
m_plot.setPalette(palette);
|
||||
m_plot.setCanvasBackground(theme->base());
|
||||
m_plot.setFrameStyle(QFrame::Plain);
|
||||
|
Loading…
x
Reference in New Issue
Block a user