From 22911e332af3ed8b05a73714e8906b476776fd4f Mon Sep 17 00:00:00 2001 From: Jordan Sherer Date: Mon, 11 May 2020 10:49:29 -0400 Subject: [PATCH] Expose color pallete --- plotter.cpp | 4 ++++ plotter.h | 1 + widegraph.cpp | 4 ++++ widegraph.h | 1 + 4 files changed, 10 insertions(+) diff --git a/plotter.cpp b/plotter.cpp index f580585..a1fc029 100644 --- a/plotter.cpp +++ b/plotter.cpp @@ -879,6 +879,10 @@ void CPlotter::setTol(int n) //setTol() DrawOverlay(); } +QVector const& CPlotter::colors(){ + return g_ColorTbl; +} + void CPlotter::setColours(QVector const& cl) { g_ColorTbl = cl; diff --git a/plotter.h b/plotter.h index a3df2a6..60db84f 100644 --- a/plotter.h +++ b/plotter.h @@ -77,6 +77,7 @@ public: void setBreadth(qint32 w) {m_w = w;} qint32 breadth() const {return m_w;} float fSpan() const {return m_fSpan;} + QVector const& colors(); void setColours(QVector const& cl); void setFlatten(bool b1, bool b2); void setTol(int n); diff --git a/widegraph.cpp b/widegraph.cpp index ef0b875..1721502 100644 --- a/widegraph.cpp +++ b/widegraph.cpp @@ -690,6 +690,10 @@ void WideGraph::readPalette () //readPalette } } +QVector const& WideGraph::colors(){ + return ui->widePlot->colors(); +} + void WideGraph::on_paletteComboBox_activated (QString const& palette) //palette selector { m_waterfallPalette = palette; diff --git a/widegraph.h b/widegraph.h index bae92a6..6d34ec0 100644 --- a/widegraph.h +++ b/widegraph.h @@ -69,6 +69,7 @@ public: void setRedFile(QString fRed); void setTurbo(bool turbo); bool shouldDisplayDecodeAttempts(); + QVector const& colors(); signals: void freezeDecode2(int n);