Definition at line 28 of file qwt_plot_canvas.h.
Public Types | |
enum | PaintAttribute { PaintCached = 1, PaintPacked = 2 } |
enum | FocusIndicator { NoFocusIndicator, CanvasFocusIndicator, ItemFocusIndicator } |
Public Member Functions | |
void | setFocusIndicator (FocusIndicator) |
FocusIndicator | focusIndicator () const |
void | setPaintAttribute (PaintAttribute, bool on=true) |
bool | testPaintAttribute (PaintAttribute) const |
QPixmap * | cache () |
const QPixmap * | cache () const |
void | invalidateCache () |
Protected Member Functions | |
QwtPlotCanvas (QwtPlot *) | |
virtual | ~QwtPlotCanvas () |
virtual void | hideEvent (QHideEvent *) |
virtual void | paintEvent (QPaintEvent *) |
virtual void | drawContents (QPainter *) |
virtual void | drawFocusIndicator (QPainter *) |
void | drawCanvas (QPainter *painter=NULL) |
Friends | |
class | QwtPlot |
|
Focus indicator.
Definition at line 76 of file qwt_plot_canvas.h. |
|
Paint attributes.
Definition at line 52 of file qwt_plot_canvas.h. |
|
Sets a cross cursor, enables QwtPlotCanvas::PaintCached.
Definition at line 50 of file qwt_plot_canvas.cpp. References setPaintAttribute(). |
|
Destructor.
Definition at line 86 of file qwt_plot_canvas.cpp. |
|
Return the paint cache, might be null.
Definition at line 172 of file qwt_plot_canvas.cpp. |
|
Return the paint cache, might be null.
Definition at line 166 of file qwt_plot_canvas.cpp. Referenced by QwtPlotCurve::draw(). |
|
Draw the the canvas Paints all plot items to the contentsRect(), using QwtPlot::drawCanvas and updates the cache.
Definition at line 268 of file qwt_plot_canvas.cpp. Referenced by drawContents(). |
|
Redraw the canvas, and focus rect.
Definition at line 245 of file qwt_plot_canvas.cpp. References drawCanvas(), drawFocusIndicator(), and focusIndicator(). |
|
Draw the focus indication.
Definition at line 339 of file qwt_plot_canvas.cpp. Referenced by drawContents(). |
|
Definition at line 199 of file qwt_plot_canvas.cpp. Referenced by drawContents(). |
|
Invalidate the internal paint cache.
Definition at line 178 of file qwt_plot_canvas.cpp. Referenced by QwtPlot::replot(). |
|
Set the focus indicator
Definition at line 189 of file qwt_plot_canvas.cpp. |
|
En/Disable caching. When cache mode is enabled the canvas contents are copied to a pixmap that is used for trivial repaints. Such repaints happen when a plot gets unhidden, deiconified or changes the focus. The win of caching depends on the costs of QwtPlot::drawCanvas. In case of plots with huge data it might be significant. The price of caching is wasting memory for the cache, what is a pixmap in size of contentsRect(). In case of QwtPaintBuffer::isEnabled() updating the cache produces no performance overhead as it reuses the temporary paintbuffer of the double buffering. Otherwise canvas updates have to painted twice to widget and cache.
Definition at line 110 of file qwt_plot_canvas.cpp. Referenced by QwtPlotCanvas(). |