tilde~
Puredata Qt-based GUI
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
paint_border.hpp
Go to the documentation of this file.
1 
23 #ifndef PAINT_BORDER_HPP
24 #define PAINT_BORDER_HPP
25 
26 #include <QWidget>
27 #include <QPainter>
28 
29 inline void paint_tl_border(QPainter &painter, QSize sz, QColor c, int inpx)
30 {
31  //c.setAlpha(0.5);
32  painter.setPen(c);
33  painter.drawLine(inpx,inpx,sz.width()-1-inpx,inpx);
34  painter.drawLine(inpx,inpx,inpx,sz.height()-1-inpx);
35 }
36 
37 inline void paint_br_border(QPainter &painter, QSize sz, QColor c, int inpx)
38 {
39  //c.setAlpha(0.5);
40  painter.setPen(c);
41  painter.drawLine(sz.width()-1-inpx, inpx,
42  sz.width()-1-inpx, sz.height()-1-inpx );
43  painter.drawLine(inpx, sz.height()-1-inpx,
44  sz.width()-1-inpx, sz.height()-1-inpx );
45 }
46 
47 #endif // PAINT_BORDER_HPP
void paint_tl_border(QPainter &painter, QSize sz, QColor c, int inpx)
Definition: paint_border.hpp:29
void paint_br_border(QPainter &painter, QSize sz, QColor c, int inpx)
Definition: paint_border.hpp:37