QWT 7.0.1
Loading...
Searching...
No Matches
Classes | Public Types | Public Member Functions | Protected Member Functions | List of all members
QwtPlotAbstractCanvas Class Reference

Base class for all type of plot canvases. More...

#include <qwt_plot_abstract_canvas.h>

Inheritance diagram for QwtPlotAbstractCanvas:
QwtPlotAbstractGLCanvas QwtPlotCanvas QwtPlotTransparentCanvas QwtPlotGLCanvas QwtPlotOpenGLCanvas

Classes

class  PrivateData
 

Public Types

enum  FocusIndicator { NoFocusIndicator , CanvasFocusIndicator , ItemFocusIndicator }
 Focus indicator The default setting is NoFocusIndicator. More...
 

Public Member Functions

 QwtPlotAbstractCanvas (QWidget *canvasWidget)
 Constructor.
 
virtual ~QwtPlotAbstractCanvas ()
 Destructor.
 
QwtPlotplot ()
 Return parent plot widget.
 
const QwtPlotplot () const
 Return parent plot widget.
 
void setFocusIndicator (FocusIndicator)
 Set the focus indicator.
 
FocusIndicator focusIndicator () const
 
void setBorderRadius (double)
 Set the radius for the corners of the border frame.
 
double borderRadius () const
 

Protected Member Functions

QWidget * canvasWidget ()
 
const QWidget * canvasWidget () const
 
virtual void drawFocusIndicator (QPainter *)
 Draw the focus indication.
 
virtual void drawBorder (QPainter *)
 Draw the border of the canvas.
 
virtual void drawBackground (QPainter *)
 Helper function for the derived plot canvas.
 
void fillBackground (QPainter *)
 Helper function for the derived plot canvas.
 
void drawCanvas (QPainter *)
 Draw the plot to the canvas.
 
void drawStyled (QPainter *, bool)
 Helper function for the derived plot canvas.
 
void drawUnstyled (QPainter *)
 Helper function for the derived plot canvas.
 
QPainterPath canvasBorderPath (const QRect &rect) const
 
void updateStyleSheetInfo ()
 Update the cached information about the current style sheet.
 

Detailed Description

Base class for all type of plot canvases.

Member Enumeration Documentation

◆ FocusIndicator

Focus indicator The default setting is NoFocusIndicator.

See also
setFocusIndicator(), focusIndicator(), drawFocusIndicator()
Enumerator
NoFocusIndicator 

Don't paint a focus indicator.

CanvasFocusIndicator 

The focus is related to the complete canvas.

Paint the focus indicator using drawFocusIndicator()

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.

Constructor & Destructor Documentation

◆ QwtPlotAbstractCanvas()

QwtPlotAbstractCanvas::QwtPlotAbstractCanvas ( QWidget *  canvasWidget)
explicit

Constructor.

Parameters
canvasWidgetplot canvas widget

Member Function Documentation

◆ borderRadius()

double QwtPlotAbstractCanvas::borderRadius ( ) const
Returns
Radius for the corners of the border frame
See also
setBorderRadius()

◆ canvasBorderPath()

QPainterPath QwtPlotAbstractCanvas::canvasBorderPath ( const QRect &  rect) const
protected
Returns
Path for the canvas border

◆ canvasWidget() [1/2]

QWidget * QwtPlotAbstractCanvas::canvasWidget ( )
protected
Returns
canvas widget

◆ canvasWidget() [2/2]

const QWidget * QwtPlotAbstractCanvas::canvasWidget ( ) const
protected
Returns
canvas widget

◆ drawBorder()

void QwtPlotAbstractCanvas::drawBorder ( QPainter *  painter)
protectedvirtual

Draw the border of the canvas.

Parameters
painterPainter

Reimplemented in QwtPlotCanvas, and QwtPlotTransparentCanvas.

◆ drawFocusIndicator()

void QwtPlotAbstractCanvas::drawFocusIndicator ( QPainter *  painter)
protectedvirtual

Draw the focus indication.

Parameters
painterPainter

◆ focusIndicator()

QwtPlotAbstractCanvas::FocusIndicator QwtPlotAbstractCanvas::focusIndicator ( ) const
Returns
Focus indicator
See also
FocusIndicator, setFocusIndicator()

◆ setBorderRadius()

void QwtPlotAbstractCanvas::setBorderRadius ( double  radius)

Set the radius for the corners of the border frame.

Parameters
radiusRadius of a rounded corner
See also
borderRadius()

◆ setFocusIndicator()

void QwtPlotAbstractCanvas::setFocusIndicator ( FocusIndicator  focusIndicator)

Set the focus indicator.

See also
FocusIndicator, focusIndicator()

The documentation for this class was generated from the following files: