conflicting packages
QwtPlotCanvas(3) | Qwt User's Guide | QwtPlotCanvas(3) |
NAME¶
QwtPlotCanvas - Canvas of a QwtPlot.SYNOPSIS¶
#include <qwt_plot_canvas.h>Public Types¶
enum PaintAttribute { BackingStore = 1, Opaque = 2, HackStyledBackground = 4, ImmediatePaint = 8 }
Public Member Functions¶
QwtPlotCanvas (QwtPlot *)
Protected Member Functions¶
virtual void paintEvent (QPaintEvent *)
Detailed Description¶
Canvas of a QwtPlot.QwtPlot
Member Typedef Documentation¶
typedef QFlags<PaintAttribute> QwtPlotCanvas::PaintAttributes¶
Paint attributes.Member Enumeration Documentation¶
enum QwtPlotCanvas::FocusIndicator¶
Focus indicator. .IP "•" 2 NoFocusIndicatorDon't paint a focus indicator
- •
- CanvasFocusIndicator
The focus is related to the complete canvas. Paint the focus indicator using paintFocus()
- •
- ItemFocusIndicator
The focus is related to an item (curve, point, ...) on the canvas. It is up to the application to display a focus indication using f.e. highlighting.
setFocusIndicator(),
focusIndicator(), paintFocus()
enum QwtPlotCanvas::PaintAttribute¶
Paint attributes. The default setting enables BackingStore and Opaque. See also:setPaintAttribute(),
testPaintAttribute()
- BackingStore
- Paint double buffered reusing the content of the pixmap buffer when possible. Using a backing store might improve the performance significantly, when workin with widget overlays ( like rubberbands ). Disabling the cache might improve the performance for incremental paints (using QwtPlotDirectPainter ).
backingStore(),
invalidateBackingStore()
- Opaque
- Try to fill the complete contents rectangle of the plot canvas. When using styled backgrounds Qt assumes, that the canvas doesn't fill its area completely ( f.e because of rounded borders ) and fills the area below the canvas. When this is done with gradients it might result in a serious performance bottleneck - depending on the size.
Will not work for semitransparent
backgrounds
- HackStyledBackground
- Try to improve painting of styled backgrounds. QwtPlotCanvas supports the box model attributes for customizing the layout with style sheets. Unfortunately the design of Qt style sheets has no concept how to handle backgrounds with rounded corners - beside of padding.
- ImmediatePaint
- When ImmediatePaint is set replot() calls repaint() instead of update().
replot(), QWidget::repaint(),
QWidget::update()
Constructor & Destructor Documentation¶
QwtPlotCanvas::QwtPlotCanvas (QwtPlot *plot) [explicit]¶
Sets a cross cursor, enables QwtPlotCanvas::BackingStore.QwtPlotCanvas::~QwtPlotCanvas () [virtual]¶
Destructor.Member Function Documentation¶
const QPixmap * QwtPlotCanvas::backingStore () const¶
Return the backing store, might be null.QBitmap QwtPlotCanvas::borderMask (const QSize &size) const Calculate a mask, that can be used to clip away the border frame¶
Parameters:size Size including the frame
QPainterPath QwtPlotCanvas::borderPath (const QRect &rect) const Calculate the painter path for a styled or rounded border¶
When the canvas has no styled background or rounded borders the painter path is empty. Parameters:rect Bounding rectangle of the
canvas
Returns:
Painter path, that can be used for
clipping
double QwtPlotCanvas::borderRadius () const Returns:¶
Radius for the corners of the border
frame
See also:
setBorderRadius()
void QwtPlotCanvas::drawBorder (QPainter *painter) [protected, virtual] Draw the border of the plot canvas¶
Parameters:painter Painter
See also:
setBorderRadius(),
QFrame::drawFrame()
void QwtPlotCanvas::drawFocusIndicator (QPainter *painter) [protected, virtual] Draw the focus indication¶
Parameters:painter Painter
bool QwtPlotCanvas::event (QEvent *event) [virtual] Qt event handler for QEvent::PolishRequest and QEvent::StyleChange¶
Parameters:event Qt Event
QwtPlotCanvas::FocusIndicator QwtPlotCanvas::focusIndicator () const Returns:¶
Focus indicator
See also:
FocusIndicator,
setFocusIndicator()
void QwtPlotCanvas::invalidateBackingStore ()¶
Invalidate the internal backing store.void QwtPlotCanvas::paintEvent (QPaintEvent *event) [protected, virtual] Paint event¶
Parameters:event Paint event
QwtPlot * QwtPlotCanvas::plot ()¶
Return parent plot widget.const QwtPlot * QwtPlotCanvas::plot () const¶
Return parent plot widget.void QwtPlotCanvas::replot () Invalidate the paint cache and repaint the canvas¶
See also:invalidatePaintCache()
void QwtPlotCanvas::resizeEvent (QResizeEvent *event) [protected, virtual] Resize event¶
Parameters:event Resize event
void QwtPlotCanvas::setBorderRadius (doubleradius) Set the radius for the corners of the border frame¶
Parameters:radius Radius of a rounded corner
See also:
borderRadius()
void QwtPlotCanvas::setFocusIndicator (FocusIndicatorfocusIndicator) Set the focus indicator¶
See also:FocusIndicator,
focusIndicator()
void QwtPlotCanvas::setPaintAttribute (PaintAttributeattribute, boolon = true)¶
Changing the paint attributes. Parameters:attribute Paint attribute
on On/Off
See also:
testPaintAttribute(),
backingStore()
bool QwtPlotCanvas::testPaintAttribute (PaintAttributeattribute) const Test wether a paint attribute is enabled¶
Parameters:attribute Paint attribute
Returns:
true if the attribute is enabled
See also:
setPaintAttribute()
void QwtPlotCanvas::updateStyleSheetInfo () [protected]¶
Update the cached informations about the current style sheet.Author¶
Generated automatically by Doxygen for Qwt User's Guide from the source code.Fri Apr 15 2011 | Version 6.0.0 |