A class for drawing symbols.
Definition at line 22 of file qwt_symbol.h.
enum Style { None, Ellipse, Rect, Diamond, Triangle, DTriangle, UTriangle, LTriangle, RTriangle, Cross, XCross, StyleCnt }
QwtSymbol ()
QwtSymbol (Style st, const QBrush &bd, const QPen &pn, const QSize &s)
virtual ~QwtSymbol ()
bool operator!= (const QwtSymbol &) const
bool operator== (const QwtSymbol &) const
void setSize (const QSize &s)
void setSize (int a, int b=-1)
void setBrush (const QBrush &b)
void setPen (const QPen &p)
void setStyle (Style s)
const QBrush & brush () const
const QPen & pen () const
const QSize & size () const
Style style () const
void draw (QPainter *p, const QPoint &pt) const
void draw (QPainter *p, int x, int y) const
virtual void draw (QPainter *p, const QRect &r) const
Style
See also:
Definition at line 29 of file qwt_symbol.h.
Default Constructor
The symbol is constructed with gray interior, black outline with zero width, no size and style 'None'. Definition at line 22 of file qwt_symbol.cpp.
Constructor.
Parameters:
Definition at line 37 of file qwt_symbol.cpp.
Destructor.
Definition at line 47 of file qwt_symbol.cpp.
Return Brush.
Definition at line 47 of file qwt_symbol.h.
Referenced by QwtPlotPrintFilter::apply(), QwtLegendItem::drawIdentifier(), QwtCurve::drawSymbols(), operator==(), and QwtPlotPrintFilter::reset().
Draw the symbol into a bounding rectangle.
This function assumes that the painter has been initialized with brush and pen before. This allows a much more performant implementation when painting many symbols with the same brush and pen like in curves.
Parameters:
Definition at line 116 of file qwt_symbol.cpp.
References QwtPainter::drawEllipse(), QwtPainter::drawLine(), QwtPainter::drawPolygon(), and QwtPainter::drawRect().
Draw the symbol at a point (x,y).
Definition at line 100 of file qwt_symbol.cpp.
Draw the symbol at a specified point.
Parameters:
Definition at line 198 of file qwt_symbol.cpp.
Referenced by draw(), QwtMarker::draw(), QwtLegendItem::drawIdentifier(), and QwtCurve::drawSymbols().
!= operator
Definition at line 240 of file qwt_symbol.cpp.
== operator
Definition at line 233 of file qwt_symbol.cpp.
References brush(), pen(), size(), and style().
Return Pen.
Definition at line 49 of file qwt_symbol.h.
Referenced by QwtPlotPrintFilter::apply(), QwtLegendItem::drawIdentifier(), QwtCurve::drawSymbols(), operator==(), and QwtPlotPrintFilter::reset().
Assign a brush.
The brush is used to draw the interior of the symbol.
Parameters:
Definition at line 80 of file qwt_symbol.cpp.
Referenced by QwtPlotPrintFilter::apply(), and QwtPlotPrintFilter::reset().
Assign a pen.
The pen is used to draw the symbol's outline.
Parameters:
Definition at line 92 of file qwt_symbol.cpp.
Referenced by QwtPlotPrintFilter::apply(), and QwtPlotPrintFilter::reset().
Specify the symbol's size.
If the 'h' parameter is left out or less than 0, and the 'w' parameter is greater than or equal to 0, the symbol size will be set to (w,w).
Parameters:
Definition at line 60 of file qwt_symbol.cpp.
Set the symbol's size.
Definition at line 68 of file qwt_symbol.cpp.
Specify the symbol style.
The following styles are defined:
Parameters:
Definition at line 227 of file qwt_symbol.cpp.
Return Size.
Definition at line 51 of file qwt_symbol.h.
Referenced by QwtMarker::draw(), QwtLegendItem::drawIdentifier(), QwtCurve::drawSymbols(), and operator==().
Return Style.
Definition at line 53 of file qwt_symbol.h.
Referenced by QwtPlot::closestMarker(), QwtMarker::draw(), QwtCurve::draw(), QwtLegendItem::drawIdentifier(), operator==(), and QwtPlot::updateLegendItem().
Generated automatically by Doxygen for Qwt User's Guide from the source code.