The QwtPlotGrid class can be used to draw a coordinate grid. A coordinate grid consists of major and minor vertical and horizontal gridlines. The locations of the gridlines are determined by the X and Y scale divisions which can be assigned with QwtPlotGrid::setXDiv and QwtPlotGrid::setYDiv() The draw() member draws the grid within a bounding rectangle.
Definition at line 34 of file qwt_plot_grid.h.
Public Member Functions | |
QwtPlotGrid () | |
virtual | ~QwtPlotGrid () |
virtual int | rtti () const |
void | enableX (bool tf) |
bool | xEnabled () const |
void | enableY (bool tf) |
bool | yEnabled () const |
void | enableXMin (bool tf) |
bool | xMinEnabled () const |
void | enableYMin (bool tf) |
bool | yMinEnabled () const |
void | setXDiv (const QwtScaleDiv &sx) |
const QwtScaleDiv & | xScaleDiv () const |
void | setYDiv (const QwtScaleDiv &sy) |
const QwtScaleDiv & | yScaleDiv () const |
void | setPen (const QPen &p) |
void | setMajPen (const QPen &p) |
const QPen & | majPen () const |
void | setMinPen (const QPen &p) |
const QPen & | minPen () const |
virtual void | draw (QPainter *p, const QwtScaleMap &xMap, const QwtScaleMap &yMap, const QRect &rect) const |
virtual void | updateScaleDiv (const QwtScaleDiv &, const QwtScaleDiv &) |
|
Enables major grid, disables minor grid.
Definition at line 42 of file qwt_plot_grid.cpp. References QwtPlotItem::setZ(). |
|
dtor
Definition at line 50 of file qwt_plot_grid.cpp. |
|
Draw the grid. The grid is drawn into the bounding rectangle such that gridlines begin and end at the rectangle's borders. The X and Y maps are used to map the scale divisions into the drawing region screen.
Implements QwtPlotItem. Definition at line 202 of file qwt_plot_grid.cpp. |
|
Enable or disable vertical gridlines.
Definition at line 67 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). |
|
Enable or disable minor vertical gridlines.
Definition at line 95 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). |
|
Enable or disable horizontal gridlines.
Definition at line 81 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). |
|
Enable or disable minor horizontal gridlines.
Definition at line 109 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). |
|
Definition at line 270 of file qwt_plot_grid.cpp. |
|
Definition at line 279 of file qwt_plot_grid.cpp. |
|
Assign a pen for the major gridlines.
Definition at line 168 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). |
|
Assign a pen for the minor gridlines.
Definition at line 181 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). |
|
Assign a pen for both major and minor gridlines.
Definition at line 153 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). |
|
Assign an x axis scale division.
Definition at line 124 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). Referenced by updateScaleDiv(). |
|
Assign a y axis division.
Definition at line 139 of file qwt_plot_grid.cpp. References QwtPlotItem::itemChanged(). Referenced by updateScaleDiv(). |
|
Update the item to changes of the axes scale division. Update the item, when the axes of plot have changed. The default implementation does nothing, but items that depend on the scale division (like QwtPlotGrid()) have to reimplement updateScaleDiv()
Reimplemented from QwtPlotItem. Definition at line 333 of file qwt_plot_grid.cpp. |
|
Definition at line 288 of file qwt_plot_grid.cpp. |
|
Definition at line 297 of file qwt_plot_grid.cpp. |
|
Definition at line 322 of file qwt_plot_grid.cpp. |
|
Definition at line 306 of file qwt_plot_grid.cpp. |
|
Definition at line 315 of file qwt_plot_grid.cpp. |
|
Definition at line 328 of file qwt_plot_grid.cpp. |