Browse Source

A few more style updates. Added theme awareness to the toolbar. Also switched the plot zoomer over to use blue instead of red as it's selector coloring to match the standard accent color for QGC.

QGC4.4
Bryant 12 years ago
parent
commit
8e05f82174
  1. 11
      src/ui/QGCToolBar.cc
  2. 8
      src/ui/linechart/ChartPlot.cc

11
src/ui/QGCToolBar.cc

@ -102,7 +102,7 @@ void QGCToolBar::createUI() @@ -102,7 +102,7 @@ void QGCToolBar::createUI()
toolBarTimeoutLabel->setObjectName("toolBarTimeoutLabel");
addWidget(toolBarTimeoutLabel);
toolBarSafetyLabel = new QLabel("SAFE", this);
toolBarSafetyLabel = new QLabel("----", this);
toolBarSafetyLabel->setToolTip(tr("Vehicle safety state"));
toolBarSafetyLabel->setAlignment(Qt::AlignCenter);
addWidget(toolBarSafetyLabel);
@ -364,7 +364,14 @@ void QGCToolBar::updateView() @@ -364,7 +364,14 @@ void QGCToolBar::updateView()
}
else
{
toolBarSafetyLabel->setStyleSheet("QLabel {color: #14C814;}");
if (MainWindow::instance()->getStyle() == MainWindow::QGC_MAINWINDOW_STYLE_LIGHT)
{
toolBarSafetyLabel->setStyleSheet("QLabel {color: #0D820D;}");
}
else
{
toolBarSafetyLabel->setStyleSheet("QLabel {color: #14C814;}");
}
toolBarSafetyLabel->setText(tr("SAFE"));
}

8
src/ui/linechart/ChartPlot.cc

@ -110,8 +110,8 @@ void ChartPlot::applyColorScheme(MainWindow::QGC_MAINWINDOW_STYLE style) @@ -110,8 +110,8 @@ void ChartPlot::applyColorScheme(MainWindow::QGC_MAINWINDOW_STYLE style)
if (style == MainWindow::QGC_MAINWINDOW_STYLE_LIGHT)
{
// Set the coloring of the area selector for zooming.
zoomer->setRubberBandPen(QPen(Qt::darkRed, zoomerWidth, Qt::DotLine));
zoomer->setTrackerPen(QPen(Qt::darkRed));
zoomer->setRubberBandPen(QPen(QColor(0x37, 0x9A, 0xC3), zoomerWidth, Qt::DotLine));
zoomer->setTrackerPen(QPen(QColor(0x37, 0x9A, 0xC3)));
// Set canvas background
setCanvasBackground(QColor(0xFF, 0xFF, 0xFF));
@ -123,8 +123,8 @@ void ChartPlot::applyColorScheme(MainWindow::QGC_MAINWINDOW_STYLE style) @@ -123,8 +123,8 @@ void ChartPlot::applyColorScheme(MainWindow::QGC_MAINWINDOW_STYLE style)
else
{
// Set the coloring of the area selector for zooming.
zoomer->setRubberBandPen(QPen(Qt::red, zoomerWidth, Qt::DotLine));
zoomer->setTrackerPen(QPen(Qt::red));
zoomer->setRubberBandPen(QPen(QColor(0xB8, 0xD3, 0xE6), zoomerWidth, Qt::DotLine));
zoomer->setTrackerPen(QPen(QColor(0xB8, 0xD3, 0xE6)));
// Set canvas background
setCanvasBackground(QColor(0, 0, 0));

Loading…
Cancel
Save