projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Channels: Don't use flat buttons and add vertical spacer
[pulseview.git]
/
pv
/
widgets
/
colourbutton.cpp
diff --git
a/pv/widgets/colourbutton.cpp
b/pv/widgets/colourbutton.cpp
index 1f503462ea2f839f0f39891aeb481fa6c830b4ae..01a22b67d165b85a48298aa3a45b5294fc64d612 100644
(file)
--- a/
pv/widgets/colourbutton.cpp
+++ b/
pv/widgets/colourbutton.cpp
@@
-14,13
+14,12
@@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
#include "colourbutton.hpp"
*/
#include "colourbutton.hpp"
-#include <
assert.h
>
+#include <
cassert
>
#include <QApplication>
#include <QPainter>
#include <QApplication>
#include <QPainter>
@@
-58,13
+57,11
@@
void ColourButton::set_colour(QColor colour)
for (unsigned int r = 0; r < rows; r++)
for (unsigned int c = 0; c < cols; c++)
for (unsigned int r = 0; r < rows; r++)
for (unsigned int c = 0; c < cols; c++)
- if (popup_.well_array().cellBrush(r, c).color() ==
- colour)
- {
+ if (popup_.well_array().cellBrush(r, c).color() == colour) {
popup_.well_array().setSelected(r, c);
popup_.well_array().setCurrent(r, c);
return;
popup_.well_array().setSelected(r, c);
popup_.well_array().setCurrent(r, c);
return;
- }
+ }
}
void ColourButton::set_palette(const QColor *const palette)
}
void ColourButton::set_palette(const QColor *const palette)
@@
-92,9
+89,9
@@
void ColourButton::on_selected(int row, int col)
selected(cur_colour_);
}
selected(cur_colour_);
}
-void ColourButton::paintEvent(QPaintEvent *e)
+void ColourButton::paintEvent(QPaintEvent *e
vent
)
{
{
- QPushButton::paintEvent(e);
+ QPushButton::paintEvent(e
vent
);
QPainter p(this);
QPainter p(this);
@@
-105,5
+102,5
@@
void ColourButton::paintEvent(QPaintEvent *e)
p.drawRect(r);
}
p.drawRect(r);
}
-}
//
widgets
-}
//
pv
+}
// namespace
widgets
+}
// namespace
pv