commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] [gnuradio] 08/23: qtgui: adds an alternative qss file.


From: git
Subject: [Commit-gnuradio] [gnuradio] 08/23: qtgui: adds an alternative qss file.
Date: Thu, 26 Jun 2014 19:54:43 +0000 (UTC)

This is an automated email from the git hooks/post-receive script.

trondeau pushed a commit to branch master
in repository gnuradio.

commit 1beb26555301221476fa9293300d00f565f11a3e
Author: Tom Rondeau <address@hidden>
Date:   Tue Jun 24 18:58:47 2014 -0400

    qtgui: adds an alternative qss file.
---
 gr-qtgui/examples/CMakeLists.txt                   |   1 +
 gr-qtgui/examples/alt.qss                          | 126 +++++++++++++++++++++
 .../include/gnuradio/qtgui/TimeRasterDisplayPlot.h |   6 +-
 gr-qtgui/lib/TimeRasterDisplayPlot.cc              |  12 ++
 4 files changed, 144 insertions(+), 1 deletion(-)

diff --git a/gr-qtgui/examples/CMakeLists.txt b/gr-qtgui/examples/CMakeLists.txt
index 8d3b299..cd6de24 100644
--- a/gr-qtgui/examples/CMakeLists.txt
+++ b/gr-qtgui/examples/CMakeLists.txt
@@ -39,6 +39,7 @@ GR_PYTHON_INSTALL(PROGRAMS
 install(
     FILES
     dark.qss
+    alt.qss
     qtgui_tags_viewing.grc
     DESTINATION ${GR_PKG_QTGUI_EXAMPLES_DIR}
     COMPONENT "qtgui_python"
diff --git a/gr-qtgui/examples/alt.qss b/gr-qtgui/examples/alt.qss
new file mode 100644
index 0000000..c310b80
--- /dev/null
+++ b/gr-qtgui/examples/alt.qss
@@ -0,0 +1,126 @@
+QWidget
+{
+    color: white;
+    background-color: black;
+}
+
+QwtPlot
+{
+    padding: 10px;
+    font-size: 18px;
+}
+
+DisplayPlot {
+    qproperty-zoomer_color: green;
+    qproperty-line_color1: #00FF00;
+    qproperty-line_color2: magenta;
+    qproperty-line_color3: #FF6905;
+    qproperty-line_style1: SolidLine;
+    qproperty-line_style2: DashLine;
+    qproperty-line_style3: DotLine;
+    qproperty-line_width1: 2;
+    qproperty-line_width2: 2;
+    qproperty-line_width3: 2;
+    qproperty-axes_label_font_size: 18;
+}
+
+WaterfallDisplayPlot {
+    qproperty-intensity_color_map_type1: 5;
+    qproperty-low_intensity_color: black;
+    qproperty-high_intensity_color: green;
+}
+
+TimeRasterDisplayPlot {
+    qproperty-intensity_color_map_type1: 6;
+}
+
+FrequencyDisplayPlot {
+    qproperty-line_color1: cyan;
+    qproperty-line_color2: magenta;
+    qproperty-line_color3: purple;
+    qproperty-line_style1: SolidLine;
+    qproperty-line_style2: DashLine;
+    qproperty-line_style3: DotLine;
+    qproperty-max_fft_color: palegreen;
+    qproperty-min_fft_color: darkblue;
+    qproperty-marker_lower_intensity_color: white;
+    qproperty-marker_upper_intensity_color: red;
+    qproperty-marker_lower_intensity_visible: false;
+    qproperty-marker_upper_intensity_visible: false;
+    qproperty-marker_noise_floor_amplitude_color: red;
+    qproperty-marker_noise_floor_amplitude_visible: false;
+}
+
+QwtPlotCanvas
+{
+    border: 1px solid White;
+    border-radius: 10px;
+}
+
+QwtScaleWidget
+{
+    font-size: 14px;
+}
+
+QwtLegend
+{
+    padding: 3px;
+    margin: 3px;
+    font-size: 14px;
+}
+
+QwtLegendItem
+{
+    padding: 2px;
+    margin: 2px;
+}
+
+QLineEdit,
+QPlainTextEdit,
+QComboBox,
+QMenu {
+    selection-color: black;
+    selection-background-color: lightgrey;
+    background: qlineargradient(x1:0, y1:0, x2:1, y2:1, stop:0 black, stop: 1 
rgb(128, 128, 128));
+    border: 1px solid gray;
+    padding: 2px;
+    border-radius: 3px;
+}
+
+QPushButton,
+QToolButton {
+    selection-color: black;
+    selection-background-color: white;
+    background: qlineargradient(x1:0, y1:0, x2:1, y2:1, stop:0 black, stop: 1 
rgb(128, 128, 128));
+    border: 1px solid gray;
+    padding: 2px;
+    border-radius: 3px;
+}
+
+QTabWidget::pane {
+    border: 1px solid white;
+}
+
+QTabBar {
+    margin: 20px;
+    padding: 20px;
+}
+
+QTabBar::tab {
+    background-color: rgb(100, 100, 100);
+    border: 1px solid white;
+    padding: 5px;
+}
+
+QTabBar::tab:first {
+    border-top-left-radius: 4px;
+}
+
+QTabBar::tab:last {
+    border-top-right-radius: 4px;
+}
+
+QTabBar::tab:selected {
+    background-color: rgb(200, 200, 200);
+    color: black;
+}
diff --git a/gr-qtgui/include/gnuradio/qtgui/TimeRasterDisplayPlot.h 
b/gr-qtgui/include/gnuradio/qtgui/TimeRasterDisplayPlot.h
index f22028c..7ef1ad2 100644
--- a/gr-qtgui/include/gnuradio/qtgui/TimeRasterDisplayPlot.h
+++ b/gr-qtgui/include/gnuradio/qtgui/TimeRasterDisplayPlot.h
@@ -46,6 +46,8 @@ class TimeRasterDisplayPlot: public DisplayPlot
 {
   Q_OBJECT
 
+  Q_PROPERTY(int intensity_color_map_type1 READ getIntensityColorMapType1 
WRITE setIntensityColorMapType1)
+
 public:
   TimeRasterDisplayPlot(int nplots,
                        double samp_rate,
@@ -67,7 +69,7 @@ public:
 
   void setPlotDimensions(const double rows, const double cols,
                         const double units, const std::string &strunits);
-  
+
   void plotNewData(const std::vector<double*> dataPoints,
                   const int64_t numDataPoints);
 
@@ -80,7 +82,9 @@ public:
   void replot(void);
 
   int getIntensityColorMapType(int) const;
+  int getIntensityColorMapType1() const;
   void setIntensityColorMapType(const int, const int, const QColor, const 
QColor);
+  void setIntensityColorMapType1(int);
   const QColor getUserDefinedLowIntensityColor() const;
   const QColor getUserDefinedHighIntensityColor() const;
 
diff --git a/gr-qtgui/lib/TimeRasterDisplayPlot.cc 
b/gr-qtgui/lib/TimeRasterDisplayPlot.cc
index 2d4ed41..5cf736d3 100644
--- a/gr-qtgui/lib/TimeRasterDisplayPlot.cc
+++ b/gr-qtgui/lib/TimeRasterDisplayPlot.cc
@@ -468,6 +468,12 @@ TimeRasterDisplayPlot::getIntensityColorMapType(int which) 
const
   return d_color_map_type[which];
 }
 
+int
+TimeRasterDisplayPlot::getIntensityColorMapType1() const
+{
+  return getIntensityColorMapType(0);
+}
+
 void
 TimeRasterDisplayPlot::setIntensityColorMapType(const int which,
                                                const int newType,
@@ -528,6 +534,12 @@ TimeRasterDisplayPlot::setIntensityColorMapType(const int 
which,
   }
 }
 
+void
+TimeRasterDisplayPlot::setIntensityColorMapType1(int newType)
+{
+  setIntensityColorMapType(0, newType, d_low_intensity, d_high_intensity);
+}
+
 const QColor
 TimeRasterDisplayPlot::getUserDefinedLowIntensityColor() const
 {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]