QwtPlot is a widget for plotting two-dimensional graphs. An unlimited number of data pairs can be displayed as curves in different styles and colors. A plot can have up to four axes, with each curve attached to an x- and a y axis. The scales at the axes are dimensioned automatically using an algorithm which can be configured separately for each axis. Linear and logarithmic scaling is supported. Markers of different styles can be added to the plot.
Curves and markers are identified by unique keys which are generated automatically when a curve or a marker is inserted. These keys are used to access the properties of the corresponding curves and markers.
A QwtPlot widget can have up to four axes which are indexed by the constants QwtPlot::yLeft, QwtPlot::yRight, QwtPlot::xTop, and QwtPlot::xBottom. Curves, markers, and the grid must be attached to an x axis and a y axis (Default: yLeft and xBottom).
#include "../include/qwt_plot.h> QwtPlot *myPlot; long curve1, curve2; // keys double x[100], y1[100], y2[100]; // x and y values myPlot = new QwtPlot("Two Graphs", parent, name); // add curves curve1 = myPlot->insertCurve("Graph 1"); curve2 = myPlot->insertCurve("Graph 2"); getSomeValues(x, y1, y2); // copy the data into the curves myPlot->setCurveData(curve1, x, y1, 100); myPlot->setCurveData(curve2, x, y2, 100); // finally, refresh the plot myPlot->replot();
Definition at line 85 of file qwt_plot.h.
Public Types | |
enum | Axis { yLeft, yRight, xBottom, xTop, axisCnt } |
enum | Position { Left = Qwt::Left, Right = Qwt::Right, Bottom = Qwt::Bottom, Top = Qwt::Top } |
Public Slots | |
void | clear () |
bool | removeCurve (long key) |
void | removeCurves () |
bool | removeMarker (long key) |
void | removeMarkers () |
virtual void | replot () |
Signals | |
void | plotMousePressed (const QMouseEvent &e) |
void | plotMouseReleased (const QMouseEvent &e) |
void | plotMouseMoved (const QMouseEvent &e) |
void | legendClicked (long key) |
Public Member Functions | |
QwtPlot (QWidget *p=0, const char *name=0) | |
QwtPlot (const QString &title, QWidget *p=0, const char *name=0) | |
virtual | ~QwtPlot () |
void | enableXBottomAxis (bool b) |
bool | xBottomAxisEnabled () const |
void | enableXTopAxis (bool b) |
bool | xTopAxisEnabled () const |
void | enableYRightAxis (bool b) |
bool | yRightAxisEnabled () const |
void | enableYLeftAxis (bool b) |
bool | yLeftAxisEnabled () const |
void | setAutoReplot (bool tf=TRUE) |
bool | autoReplot () const |
void | print (QPaintDevice &p, const QwtPlotPrintFilter &=QwtPlotPrintFilter()) const |
virtual void | print (QPainter *, const QRect &rect, const QwtPlotPrintFilter &=QwtPlotPrintFilter()) const |
void | enableOutline (bool tf) |
bool | outlineEnabled () const |
void | setOutlineStyle (Qwt::Shape os) |
Qwt::Shape | outlineStyle () const |
void | setOutlinePen (const QPen &pn) |
const QPen & | outlinePen () const |
QwtPlotLayout * | plotLayout () |
const QwtPlotLayout * | plotLayout () const |
void | setMargin (int margin) |
int | margin () const |
void | setTitle (const QString &t) |
QString | title () const |
void | setTitleFont (const QFont &f) |
QFont | titleFont () const |
QLabel * | titleLabel () |
const QLabel * | titleLabel () const |
QwtPlotCanvas * | canvas () |
const QwtPlotCanvas * | canvas () const |
void | setCanvasBackground (const QColor &c) |
const QColor & | canvasBackground () const |
void | setCanvasLineWidth (int w) |
int | canvasLineWidth () const |
QwtPlotCurveIterator | curveIterator () const |
QwtPlotMarkerIterator | markerIterator () const |
QwtDiMap | canvasMap (int axis) const |
double | invTransform (int axis, int pos) const |
int | transform (int axis, double value) const |
long | insertCurve (QwtPlotCurve *) |
long | insertCurve (const QString &title, int xAxis=xBottom, int yAxis=yLeft) |
QwtPlotCurve * | curve (long key) |
const QwtPlotCurve * | curve (long key) const |
QwtArray< long > | curveKeys () const |
long | closestCurve (int xpos, int ypos, int &dist) const |
long | closestCurve (int xpos, int ypos, int &dist, double &xval, double &yval, int &index) const |
bool | setCurveBaseline (long key, double ref) |
double | curveBaseline (long key) const |
bool | setCurveRawData (long key, const double *x, const double *y, int size) |
bool | setCurveData (long key, const double *x, const double *y, int size) |
bool | setCurveData (long key, const QwtArray< double > &x, const QwtArray< double > &y) |
bool | setCurveData (long key, const QwtArray< QwtDoublePoint > &data) |
bool | setCurveData (long key, const QwtData &data) |
bool | setCurveOptions (long key, int t) |
int | curveOptions (long key) const |
bool | setCurvePen (long key, const QPen &pen) |
QPen | curvePen (long key) const |
bool | setCurveBrush (long key, const QBrush &brush) |
QBrush | curveBrush (long key) const |
bool | setCurveSplineSize (long key, int s) |
int | curveSplineSize (long key) const |
bool | setCurveStyle (long key, int s, int options=0) |
int | curveStyle (long key) const |
bool | setCurveSymbol (long key, const QwtSymbol &s) |
QwtSymbol | curveSymbol (long key) const |
bool | setCurveTitle (long key, const QString &s) |
QString | curveTitle (long key) const |
bool | setCurveXAxis (long key, int axis) |
int | curveXAxis (long key) const |
bool | setCurveYAxis (long key, int axis) |
int | curveYAxis (long key) const |
void | drawCurve (long key, int from=0, int to=-1) |
void | enableGridX (bool tf=TRUE) |
void | enableGridXMin (bool tf=TRUE) |
void | enableGridY (bool tf=TRUE) |
void | enableGridYMin (bool tf=TRUE) |
bool | gridXEnabled () const |
bool | gridXMinEnabled () const |
bool | gridYEnabled () const |
bool | gridYMinEnabled () const |
void | setGridXAxis (int axis) |
int | gridXAxis () const |
void | setGridYAxis (int axis) |
int | gridYAxis () const |
void | setGridPen (const QPen &p) |
void | setGridMajPen (const QPen &p) |
const QPen & | gridMajPen () const |
void | setGridMinPen (const QPen &p) |
const QPen & | gridMinPen () const |
QwtPlotGrid & | grid () |
const QwtPlotGrid & | grid () const |
void | setAxisAutoScale (int axis) |
bool | axisAutoScale (int axis) const |
void | enableAxis (int axis, bool tf=TRUE) |
bool | axisEnabled (int axis) const |
void | changeAxisOptions (int axis, int opt, bool value) |
void | setAxisOptions (int axis, int opt) |
int | axisOptions (int axis) const |
void | setAxisFont (int axis, const QFont &f) |
QFont | axisFont (int axis) const |
void | setAxisMargins (int axis, double mlo, double mhi) |
bool | axisMargins (int axis, double &mlo, double &mhi) const |
void | setAxisScale (int axis, double min, double max, double step=0) |
void | setAxisScaleDraw (int axis, QwtScaleDraw *) |
const QwtScaleDiv * | axisScale (int axis) const |
const QwtScaleDraw * | axisScaleDraw (int axis) const |
const QwtScale * | axis (int axis) const |
void | setAxisLabelFormat (int axis, char f, int prec, int fieldwidth=0) |
void | axisLabelFormat (int axis, char &f, int &prec, int &fieldwidth) const |
void | setAxisLabelAlignment (int axis, int alignment) |
void | setAxisLabelRotation (int axis, double rotation) |
void | setAxisTitle (int axis, const QString &t) |
QString | axisTitle (int axis) const |
void | setAxisTitleFont (int axis, const QFont &f) |
QFont | axisTitleFont (int axis) const |
void | setAxisTitleAlignment (int axis, int align) |
int | axisTitleAlignment (int axis) const |
void | setAxisMaxMinor (int axis, int maxMinor) |
int | axisMaxMajor (int axis) const |
void | setAxisMaxMajor (int axis, int maxMajor) |
int | axisMaxMinor (int axis) const |
void | setAxisReference (int axis, double value) |
double | axisReference (int axis) const |
long | insertMarker (QwtPlotMarker *) |
long | insertMarker (const QString &label=QString::null, int xAxis=xBottom, int yAxis=yLeft) |
long | insertLineMarker (const QString &label, int axis) |
QwtPlotMarker * | marker (long key) |
const QwtPlotMarker * | marker (long key) const |
long | closestMarker (int xpos, int ypos, int &dist) const |
QwtArray< long > | markerKeys () const |
bool | setMarkerXAxis (long key, int axis) |
int | markerXAxis (long key) const |
bool | setMarkerYAxis (long key, int axis) |
int | markerYAxis (long key) const |
bool | setMarkerPos (long key, double xval, double yVal) |
bool | setMarkerXPos (long key, double val) |
bool | setMarkerYPos (long key, double val) |
void | markerPos (long key, double &mx, double &my) const |
bool | setMarkerFont (long key, const QFont &f) |
QFont | markerFont (long key) const |
bool | setMarkerPen (long key, const QPen &p) |
bool | setMarkerLabel (long key, const QString &text, const QFont &font=QFont(), const QColor &color=QColor(), const QPen &pen=QPen(Qt::NoPen), const QBrush &brush=QBrush(Qt::NoBrush)) |
bool | setMarkerLabelText (long key, const QString &text) |
const QString | markerLabel (long key) const |
bool | setMarkerLabelAlign (long key, int align) |
int | markerLabelAlign (long key) const |
bool | setMarkerLabelPen (long key, const QPen &p) |
QPen | markerLabelPen (long key) const |
bool | setMarkerLinePen (long key, const QPen &p) |
QPen | markerLinePen (long key) const |
bool | setMarkerLineStyle (long key, QwtMarker::LineStyle st) |
QwtMarker::LineStyle | markerLineStyle (long key) const |
bool | setMarkerSymbol (long key, const QwtSymbol &s) |
QwtSymbol | markerSymbol (long key) const |
void | setAutoLegend (bool enabled) |
bool | autoLegend () const |
void | enableLegend (bool tf, long curveKey=-1) |
bool | legendEnabled (long curveKey) const |
void | setLegendPosition (Position pos, double ratio) |
void | setLegendPosition (Position pos) |
Position | legendPosition () const |
void | setLegendPos (int pos, double ratio=0.0) |
int | legendPos () const |
void | setLegendFont (const QFont &f) |
const QFont | legendFont () const |
void | setLegendFrameStyle (int st) |
int | legendFrameStyle () const |
QwtLegend * | legend () |
const QwtLegend * | legend () const |
void | setLegendDisplayPolicy (QwtLegend::LegendDisplayPolicy, int mode=-1) |
virtual QSize | sizeHint () const |
virtual QSize | minimumSizeHint () const |
virtual bool | event (QEvent *) |
Protected Slots | |
virtual void | lgdClicked () |
Protected Member Functions | |
void | autoRefresh () |
virtual void | drawCanvas (QPainter *) |
virtual void | drawCanvasItems (QPainter *, const QRect &, const QwtArray< QwtDiMap > &, const QwtPlotPrintFilter &) const |
virtual void | drawContents (QPainter *p) |
virtual void | updateTabOrder () |
void | updateAxes () |
void | updateLayout () |
virtual void | resizeEvent (QResizeEvent *e) |
virtual void | insertLegendItem (long curveKey) |
virtual void | updateLegendItem (long curveKey) |
virtual void | printLegendItem (QPainter *, const QWidget *, const QRect &) const |
void | updateLegendItem (const QwtPlotCurve *, QwtLegendItem *) |
virtual void | printTitle (QPainter *, const QRect &) const |
virtual void | printScale (QPainter *, int axis, int startDist, int endDist, int baseDist, const QRect &) const |
virtual void | printCanvas (QPainter *, const QRect &, const QwtArray< QwtDiMap > &, const QwtPlotPrintFilter &) const |
virtual void | printLegend (QPainter *, const QRect &) const |
Static Protected Member Functions | |
bool | axisValid (int axis) |
|
Axis index. Definition at line 129 of file qwt_plot.h. |
|
Position. Definition at line 136 of file qwt_plot.h. Referenced by legendPosition(), and setLegendPos(). |
|
Constructor.
|
|
Constructor.
|
|
Destructor. Definition at line 54 of file qwt_plot.cpp. |
|
|
|
Replots the plot if QwtPlot::autoReplot() is Definition at line 168 of file qwt_plot.cpp. References replot(). Referenced by changeAxisOptions(), insertMarker(), QwtPlotItem::itemChanged(), removeCurve(), removeCurves(), removeMarker(), removeMarkers(), setAxisAutoScale(), setAxisMargins(), setAxisMaxMajor(), setAxisMaxMinor(), setAxisOptions(), setAxisReference(), setAxisScale(), and setAxisScaleDraw(). |
|
Referenced by replot(). |
|
References axisEnabled(). Referenced by closestCurve(), closestMarker(), QwtPlotLayout::minimumSizeHint(), and print(). |
|
References QwtAutoScale::autoScale(), and axisValid(). |
|
References axisValid(). Referenced by axis(), canvasMap(), print(), and QwtPlotPicker::QwtPlotPicker(). |
|
References axisValid(). |
|
References axisValid(), and QwtScale::labelFormat(). Referenced by QwtPlotZoomer::minZoomSize(). |
|
Determine the scale margins for a specified axis.
References axisValid(), and QwtAutoScale::loMargin(). |
|
References axisValid(), and QwtAutoScale::maxMajor(). |
|
References axisValid(), and QwtAutoScale::maxMinor(). |
|
References axisValid(), and QwtAutoScale::options(). |
|
The reference value is needed if the autoscaling options QwtAutoScale::Symmetric or QwtAutoScale::IncludeRef are set.
References axisValid(), and QwtAutoScale::reference(). |
|
References axisValid(), and QwtAutoScale::scaleDiv(). Referenced by QwtPlotPicker::scaleRect(). |
|
References axisValid(), and QwtScale::scaleDraw(). |
|
References axisValid(), and QwtScale::title(). |
|
References axisValid(), and QwtScale::titleAlignment(). |
|
References axisValid(), and QwtScale::titleFont(). |
|
Referenced by axisAutoScale(), axisEnabled(), axisFont(), axisLabelFormat(), axisMargins(), axisMaxMajor(), axisMaxMinor(), axisOptions(), axisReference(), axisScale(), axisScaleDraw(), axisTitle(), axisTitleAlignment(), axisTitleFont(), changeAxisOptions(), enableAxis(), invTransform(), setAxisAutoScale(), setAxisFont(), setAxisLabelAlignment(), setAxisLabelFormat(), setAxisLabelRotation(), setAxisMargins(), setAxisMaxMajor(), setAxisMaxMinor(), setAxisOptions(), setAxisReference(), setAxisScale(), setAxisScaleDraw(), setAxisTitle(), setAxisTitleAlignment(), setAxisTitleFont(), and transform(). |
|
|
|
Referenced by canvasBackground(), canvasLineWidth(), drawCurve(), QwtPlotLayout::minimumSizeHint(), setCanvasBackground(), and setCanvasLineWidth(). |
|
Nothing else than: canvas()->palette().color( QPalette::Normal, QColorGroup::Background);
References canvas(). Referenced by QwtPlotPrintFilter::apply(), and printCanvas(). |
|
Nothing else than: canvas()->lineWidth(), left for compatibility only.
References canvas(). |
|
References axisEnabled(), QwtPlotLayout::canvasMargin(), QwtScale::endBorderDist(), QwtScaleDiv::hBound(), QwtScaleDiv::lBound(), QwtScaleDiv::logScale(), margin(), plotLayout(), QwtAutoScale::scaleDiv(), QwtDiMap::setDblRange(), QwtDiMap::setIntRange(), and QwtScale::startBorderDist(). Referenced by closestCurve(), closestMarker(), drawCanvas(), drawCurve(), QwtPlotPicker::invTransform(), invTransform(), QwtPlotPicker::transform(), and transform(). |
|
Change specified autoscaling options of an axis.
References autoRefresh(), axisValid(), and QwtAutoScale::changeOptions(). |
|
Remove all curves and markers. Definition at line 932 of file qwt_plot.cpp. References QwtLegend::clear(). |
|
Find the curve which is closest to a point in the plotting area. Determines the position and index of the closest data point.
References axis(), canvasMap(), curveIterator(), QwtCurve::dataSize(), qwtSqr(), QwtCurve::x(), QwtPlotMappedItem::xAxis(), QwtDiMap::xTransform(), QwtCurve::y(), and QwtPlotMappedItem::yAxis(). |
|
Find the curve which is closest to a specified point in the plotting area.
|
|
Find the marker which is closest to a given point.
References axis(), canvasMap(), QwtMarker::lineStyle(), markerIterator(), qwtSqr(), QwtSymbol::style(), QwtMarker::symbol(), QwtPlotMappedItem::xAxis(), QwtDiMap::xTransform(), QwtPlotMarker::xValue(), QwtPlotMappedItem::yAxis(), and QwtPlotMarker::yValue(). |
|
Find and return an existing curve.
|
|
Find and return an existing curve.
Referenced by drawCanvasItems(), drawCurve(), enableLegend(), insertCurve(), and updateLegendItem(). |
|
Return the baseline offset for a specified curve.
References QwtCurve::baseline(). |
|
References QwtCurve::brush(). |
|
Return an iterator for the plot curves. Definition at line 16 of file qwt_plot_curve.cpp. Referenced by closestCurve(), curveKeys(), drawCanvasItems(), enableLegend(), setLegendDisplayPolicy(), and updateAxes(). |
|
References curveIterator(). |
|
References QwtCurve::options(). |
|
References QwtCurve::pen(). |
|
References QwtCurve::splineSize(). |
|
References QwtCurve::style(). |
|
the symbol of the curve indexed by key
References QwtCurve::symbol(). |
|
References QwtCurve::title(). |
|
Return the index of the x axis to which a curve is mapped.
References QwtPlotMappedItem::xAxis(). |
|
the index of the y axis to which a curve is mapped
References QwtPlotMappedItem::yAxis(). |
|
Redraw the canvas.
References canvasMap(), and drawCanvasItems(). |
|
Redraw the canvas items.
References curve(), curveIterator(), QwtMarker::draw(), QwtCurve::draw(), QwtGrid::draw(), QwtPlotItem::enabled(), marker(), markerIterator(), QwtPlotPrintFilter::options(), QwtPlotMappedItem::xAxis(), QwtPlotMarker::xValue(), QwtPlotMappedItem::yAxis(), and QwtPlotMarker::yValue(). Referenced by drawCanvas(), and printCanvas(). |
|
drawContents Definition at line 548 of file qwt_plot.cpp. |
|
Draw a set of points of a curve. When observing an measurement while it is running, new points have to be added to an existing curve. drawCurve can be used to display them avoiding a complete redraw of the canvas.
References QwtPlotCanvas::cache(), QwtPlotCanvas::cacheMode(), canvas(), canvasMap(), curve(), QwtCurve::draw(), QwtPlotMappedItem::xAxis(), and QwtPlotMappedItem::yAxis(). |
|
Enable or disable a specified axis. When an axis is disabled, this only means that it is not visible on the screen. Curves, markers and can be attached to disabled axes, and transformation of screen coordinates into values works as normal. Only xBottom and yLeft are enabled by default.
References axisValid(), and updateLayout(). |
|
Enable or disable vertical gridlines.
References QwtGrid::enableX(). |
|
Enable or disable vertical gridlines for the minor scale marks.
References QwtGrid::enableXMin(). |
|
Enable or disable horizontal gridlines.
References QwtGrid::enableY(). |
|
Enable or disable horizontal gridlines for the minor scale marks.
References QwtGrid::enableYMin(). |
|
Enable or disable the legend.
References QwtLegend::clear(), curve(), curveIterator(), QwtLegend::findItem(), insertLegendItem(), QwtLegend::itemCount(), and updateLayout(). |
|
Enables or disables outline drawing.
References QwtPlotCanvas::enableOutline(). |
|
Designer API for enableAxis. Definition at line 148 of file qwt_plot.h. |
|
Designer API for enableAxis. Definition at line 152 of file qwt_plot.h. |
|
Designer API for enableAxis. Definition at line 160 of file qwt_plot.h. |
|
Designer API for enableAxis. Definition at line 156 of file qwt_plot.h. |
|
Adds handling of QEvent::LayoutHint. Definition at line 147 of file qwt_plot.cpp. References updateLayout(). |
|
Return the canvas grid. Definition at line 22 of file qwt_plot_grid.cpp. |
|
Return the canvas grid. Definition at line 16 of file qwt_plot_grid.cpp. |
|
References QwtGrid::majPen(). |
|
References QwtGrid::minPen(). |
|
References QwtPlotMappedItem::xAxis(). |
|
References QwtGrid::xEnabled(). |
|
References QwtGrid::xMinEnabled(). |
|
References QwtPlotMappedItem::yAxis(). |
|
References QwtGrid::yEnabled(). |
|
References QwtGrid::yMinEnabled(). |
|
Insert a new curve and return a unique key.
References curve(), insertCurve(), QwtPlotMappedItem::setAxis(), and QwtCurve::setTitle(). |
|
Insert a curve.
References insertLegendItem(), QwtPlotItem::reparent(), and updateLayout(). Referenced by insertCurve(). |
|
Insert a QwtLegendItem for a specified curve. In case of legend()->isReadOnly the item will be a QwtLegendLabel, otherwise a QwtLegendButton.
References QwtLegend::contentsWidget(), QwtLegend::insertItem(), QwtLegend::isReadOnly(), lgdClicked(), and updateLegendItem(). Referenced by enableLegend(), and insertCurve(). |
|
This function is a shortcut to insert a horizontal or vertical line marker, dependent on the specified axis.
References insertMarker(), marker(), QwtPlotMappedItem::setAxis(), QwtMarker::setLabel(), QwtMarker::setLabelAlignment(), and QwtMarker::setLineStyle(). |
|
Insert a new marker.
References insertMarker(), marker(), QwtPlotMappedItem::setAxis(), and QwtMarker::setLabel(). |
|
Insert a new marker.
References autoRefresh(), and QwtPlotItem::reparent(). Referenced by insertLineMarker(), and insertMarker(). |
|
Transform the x or y coordinate of a position in the drawing region into a value.
References axisValid(), canvasMap(), and QwtDiMap::invTransform(). |
|
|
|
Referenced by QwtPlotLayout::activate(), and QwtPlotLayout::minimumSizeHint(). |
|
A signal which is emitted when legend()->isReadOnly() == FALSE and the user has clicked on a legend item,
Referenced by lgdClicked(). |
|
References QwtLegend::findItem(). |
|
|
|
|
|
References QwtPlotLayout::legendPosition(). |
|
References QwtPlotLayout::legendPosition(), and Position. |
|
Called internally when the legend has been clicked on. Emits a legendClicked() signal. Definition at line 921 of file qwt_plot.cpp. References QwtLegend::key(), and legendClicked(). Referenced by insertLegendItem(). |
|
References QwtPlotLayout::margin(). Referenced by canvasMap(), and print(). |
|
Find and return an existing marker.
|
|
Find and return an existing marker.
Referenced by drawCanvasItems(), insertLineMarker(), and insertMarker(). |
|
References QwtMarker::font(). |
|
Return an iterator for the plot curves. Definition at line 17 of file qwt_plot_marker.cpp. Referenced by closestMarker(), drawCanvasItems(), and markerKeys(). |
|
References markerIterator(). |
|
References QwtMarker::label(). |
|
References QwtMarker::labelAlignment(). |
|
References QwtMarker::labelPen(). |
|
References QwtMarker::linePen(). |
|
References QwtMarker::lineStyle(). |
|
Get the position of a marker.
References QwtPlotMarker::xValue(), and QwtPlotMarker::yValue(). |
|
References QwtMarker::symbol(). |
|
References QwtPlotMappedItem::xAxis(). |
|
References QwtPlotMappedItem::yAxis(). |
|
Return a minimum size hint. Definition at line 343 of file qwt_plot.cpp. References QwtPlotLayout::minimumSizeHint(). Referenced by sizeHint(). |
|
References QwtPlotCanvas::outlineEnabled(). |
|
References QwtPlotCanvas::outlinePen(). |
|
References QwtPlotCanvas::outlineStyle(). |
|
|
|
Referenced by canvasMap(), and print(). |
|
A signal which is emitted when the mouse is moved in the plot canvas.
|
|
A signal which is emitted when the mouse is pressed in the plot canvas.
|
|
A signal which is emitted when a mouse button has been released in the plot canvas.
|
|
Paint the plot into a given rectangle. Paint the contents of a QwtPlot instance into a given rectangle.
References QwtPlotLayout::activate(), QwtPlotPrintFilter::apply(), axis(), axisEnabled(), QwtScale::baseLineDist(), QwtPlotLayout::canvasMargin(), QwtPlotLayout::canvasRect(), QwtScaleDiv::hBound(), QwtPlotLayout::invalidate(), QwtLegend::isEmpty(), QwtScaleDiv::lBound(), QwtPlotLayout::legendRect(), QwtScaleDiv::logScale(), margin(), QwtPainter::metricsMap(), QwtPlotPrintFilter::options(), plotLayout(), printCanvas(), printLegend(), printScale(), printTitle(), QwtPlotPrintFilter::reset(), QwtPainter::resetMetricsMap(), QwtAutoScale::scaleDiv(), QwtPlotLayout::scaleRect(), QwtScale::setBaselineDist(), QwtPainter::setMetricsMap(), QwtScale::startBorderDist(), and QwtPlotLayout::titleRect(). |
|
Print the plot to a
|
|
Print the canvas into a given rectangle.
References canvasBackground(), drawCanvasItems(), QwtPainter::drawRect(), QwtPainter::fillRect(), QwtPlotPrintFilter::options(), and QwtPainter::setClipRect(). Referenced by print(). |
|
Print the legend into a given rectangle.
References QwtDynGridLayout::columnsForWidth(), QwtLegend::contentsWidget(), QwtLegend::isEmpty(), QwtDynGridLayout::iterator(), QwtDynGridLayout::layoutItems(), printLegendItem(), and QwtPainter::setClipRect(). Referenced by print(). |
|
Print the legend item into a given rectangle.
References QwtLegendItem::drawItem(). Referenced by printLegend(). |
|
Paint a scale into a given rectangle. Paint the scale into a given rectangle.
References QwtScaleDraw::draw(), QwtScale::drawTitle(), QwtScaleDraw::length(), QwtScale::scaleDraw(), QwtScaleDraw::setGeometry(), QwtScaleDraw::x(), and QwtScaleDraw::y(). Referenced by print(). |
|
Print the title into a given rectangle.
References QwtText::draw(), and QwtText::makeText(). Referenced by print(). |
|
remove the curve indexed by key
References autoRefresh(), QwtLegend::findItem(), and updateLayout(). |
|
Remove all curves. Definition at line 941 of file qwt_plot.cpp. References autoRefresh(), and QwtLegend::clear(). |
|
Remove the marker indexed by key.
References autoRefresh(). |
|
Remove all markers. Definition at line 949 of file qwt_plot.cpp. References autoRefresh(). |
|
Redraw the plot. If the autoReplot option is not set (which is the default) or if any curves are attached to raw data, the plot has to be refreshed explicitly in order to make changes visible.
References autoReplot(), QwtPlotCanvas::invalidateCache(), setAutoReplot(), and updateAxes(). Referenced by autoRefresh(), and QwtPlotZoomer::rescale(). |
|
Resize and update internal layout. Definition at line 352 of file qwt_plot.cpp. References updateLayout(). |
|
Set or reset the autoLegend option If the autoLegend option is set, a item will be added to the legend whenever a curve is inserted. The autoLegend option is set to FALSE by default, which means that the user has to call enableLegend.
|
|
Set or reset the autoReplot option If the autoReplot option is set, the plot will be updated implicitly by manipulating member functions. Since this may be time-consuming, it is recommended to leave this option switched off and call replot() explicitly if necessary. The autoReplot option is set to FALSE by default, which means that the user has to call replot() in order to make changes visible.
Referenced by replot(). |
|
Enable autoscaling for a specified axis. This member function is used to switch back to autoscaling mode after a fixed scale has been set. Autoscaling is enabled by default.
References autoRefresh(), axisValid(), and QwtAutoScale::setAutoScale(). |
|
Change the font of an axis.
References axisValid(). |
|
Change the alignment of the tick labels
References axisValid(), and QwtScale::setLabelAlignment(). |
|
Change the number format for the major scale of a selected axis
References axisValid(), and QwtScale::setLabelFormat(). |
|
Rotate all tick labels
References axisValid(), and QwtScale::setLabelRotation(). |
|
Assign margins to a specified axis.
References autoRefresh(), axisValid(), and QwtAutoScale::setMargins(). |
|
Set the maximum number of major scale intervals for a specified axis.
References autoRefresh(), axisValid(), and QwtAutoScale::setMaxMajor(). |
|
Set the maximum number of minor scale intervals for a specified axis.
References autoRefresh(), axisValid(), and QwtAutoScale::setMaxMinor(). |
|
Reset scale options and set specified options for a specified axis.
References autoRefresh(), axisValid(), and QwtAutoScale::setOptions(). |
|
Set a reference value for a specified axis. The reference value is used by some autoscaling modes.
References autoRefresh(), axisValid(), and QwtAutoScale::setReference(). |
|
Disable autoscaling and specify a fixed scale for a selected axis.
References autoRefresh(), axisValid(), and QwtAutoScale::setScale(). Referenced by QwtPlotZoomer::rescale(). |
|
Set a scale draw.
References autoRefresh(), axisValid(), and QwtScale::setScaleDraw(). |
|
Change the title of a specified axis.
References axisValid(), and QwtScale::setTitle(). |
|
Change the title alignment of a selected axis.
References axisValid(), and QwtScale::setTitleAlignment(). |
|
Change the title font of a selected axis.
References axisValid(), and QwtScale::setTitleFont(). |
|
Change the background of the plotting area. Sets c to QColorGroup::Background of all colorgroups of the palette of the canvas. Using canvas()->setPalette() is a more powerful way to set these colors.
References canvas(). Referenced by QwtPlotPrintFilter::apply(), and QwtPlotPrintFilter::reset(). |
|
Change the border width of the plotting area Nothing else than canvas()->setLineWidth(w), left for compatibility only.
References canvas(). |
|
Set the baseline for a specified curve. The baseline is needed for the curve style QwtCurve::Sticks,
References QwtCurve::setBaseline(). |
|
Assign a brush to a curve indexed by key The brush will be used to fill the area between the curve and the baseline.
References QwtCurve::setBrush(), and updateLegendItem(). |
|
Initialize curve data with any QwtData object.
References QwtCurve::setData(). |
|
Initialize curve data with a array of points (explicitly shared).
References QwtCurve::setData(). |
|
Initialize curve data with x- and y-arrays (data is explicitly shared).
References QwtCurve::setData(). |
|
Set curve data by copying x- and y-values from specified blocks. Contrary to QwtPlot::setCurveRawData, this function makes a 'deep copy' of the data.
References QwtCurve::setData(). |
|
Set the style options of a curve indexed by key.
References QwtCurve::setOptions(). |
|
Assign a pen to a curve indexed by key.
References QwtCurve::setPen(), and updateLegendItem(). |
|
Initialize the curve data by pointing to memory blocks which are not managed by QwtPlot.
References QwtCurve::setRawData(). |
|
Set the number of interpolated points of a curve indexed by key.
References QwtCurve::setSplineSize(). |
|
Change a curve's style.
References QwtCurve::setStyle(), and updateLegendItem(). |
|
Assign a symbol to the curve indexed by key.
References QwtCurve::setSymbol(), and updateLegendItem(). |
|
Assign a title to the curve indexed by key.
References QwtCurve::setTitle(), and updateLegendItem(). |
|
Attach a curve to an x axis.
References QwtPlotMappedItem::setXAxis(). |
|
Attach a curve to an y axis.
References QwtPlotMappedItem::setYAxis(). |
|
Change the pen for the major gridlines.
References QwtGrid::setMajPen(). |
|
Change the pen for the minor gridlines.
References QwtGrid::setMinPen(). |
|
Change the grid's pens for major and minor gridlines.
References QwtGrid::setPen(). |
|
Attach the grid to an x axis.
References QwtPlotMappedItem::setXAxis(), and QwtGrid::setXDiv(). |
|
Attach the grid to an y axis.
References QwtPlotMappedItem::setYAxis(), and QwtGrid::setYDiv(). |
|
Set the identifier display policy of the legend.
References curveIterator(), QwtLegend::setDisplayPolicy(), and updateLegendItem(). |
|
Change the font of the legend items.
References updateLayout(). |
|
Change the legend's frame style.
References updateLayout(). |
|
Specify the position of the legend within the widget. If the position legend is
References Position, and setLegendPosition(). |
|
Specify the position of the legend within the widget. If the position legend is
References setLegendPosition(). |
|
Specify the position of the legend within the widget. If the position legend is
References QwtLegend::contentsWidget(), QwtPlotLayout::legendPosition(), QwtPlotLayout::setLegendPosition(), QwtDynGridLayout::setMaxCols(), updateLayout(), and updateTabOrder(). Referenced by setLegendPos(), and setLegendPosition(). |
|
Change the margin of the plot. The margin is the space around all components.
References QwtPlotLayout::margin(), QwtPlotLayout::setMargin(), and updateLayout(). |
|
Specify a font for a marker's label.
References QwtMarker::setFont(). |
|
Set the marker label.
References QwtMarker::setLabel(). |
|
Specify the alignment of a marker's label. The alignment determines the position of the label relative to the marker's position. The default setting is AlignCenter.
References QwtMarker::setLabelAlignment(). |
|
Specify a pen for a marker's label.
References QwtMarker::setLabelPen(). |
|
Assign a text to the label of a marker.
References QwtMarker::setLabelText(). |
|
Specify a pen for a marker's line.
References QwtMarker::setLinePen(). |
|
Specify the line style for a marker.
References QwtMarker::setLineStyle(). |
|
Specify a pen for a marker's label.
References QwtMarker::setLabelPen(), and QwtMarker::setLinePen(). |
|
Change the position of a marker.
References QwtPlotMarker::setXValue(), and QwtPlotMarker::setYValue(). |
|
Assign a symbol to a specified marker.
References QwtMarker::setSymbol(). |
|
Attach the marker to an x axis.
References QwtPlotMappedItem::setXAxis(). |
|
Specify the X position of a marker.
References QwtPlotMarker::setXValue(). |
|
Attach the marker to a Y axis.
References QwtPlotMappedItem::setYAxis(). |
|
Specify the Y position of the marker.
References QwtPlotMarker::setYValue(). |
|
Specify a pen for the outline.
References QwtPlotCanvas::setOutlinePen(). |
|
Specify the style of the outline.
References QwtPlotCanvas::setOutlineStyle(). |
|
Change the plot's title.
|
|
Change the title font.
|
|
Return sizeHint
References QwtScaleDiv::majCnt(), minimumSizeHint(), QwtScale::minimumSizeHint(), QwtScaleDraw::scaleDiv(), and QwtScale::scaleDraw(). |
|
|
|
|
|
|
|
Referenced by QwtPlotLayout::minimumSizeHint(). |
|
Transform a value into a coordinate in the plotting region.
References axisValid(), canvasMap(), and QwtDiMap::transform(). |
|
Rebuild the scales and maps. Definition at line 438 of file qwt_plot.cpp. References QwtAutoScale::adjust(), QwtAutoScale::autoScale(), QwtCurve::boundingRect(), curveIterator(), QwtDoubleRect::isValid(), QwtScale::minBorderDist(), QwtAutoScale::reset(), QwtScale::setBorderDist(), QwtScale::setScaleDiv(), QwtGrid::setXDiv(), QwtGrid::setYDiv(), QwtDoubleRect::x1(), QwtDoubleRect::x2(), QwtPlotMappedItem::xAxis(), QwtDoubleRect::y1(), QwtDoubleRect::y2(), and QwtPlotMappedItem::yAxis(). Referenced by replot(). |
|
Adjust plot content to its current size.
References QwtPlotLayout::activate(), QwtPlotLayout::canvasRect(), QwtLegend::itemCount(), QwtPlotLayout::legendRect(), QwtPlotLayout::scaleRect(), and QwtPlotLayout::titleRect(). Referenced by enableAxis(), enableLegend(), event(), insertCurve(), removeCurve(), resizeEvent(), setLegendFont(), setLegendFrameStyle(), setLegendPosition(), and setMargin(). |
|
Update a liegen item for a specified curve
References QwtLegend::displayPolicy(), QwtLegend::identifierMode(), QwtCurve::pen(), QwtLegendItem::setCurvePen(), QwtLegendItem::setIdentifierMode(), QwtLegendItem::setSymbol(), QwtLegendItem::setTitle(), QwtSymbol::style(), QwtCurve::style(), QwtCurve::symbol(), and QwtCurve::title(). |
|
Update the legend item of a specified curve
References curve(), and QwtLegend::findItem(). Referenced by insertLegendItem(), setCurveBrush(), setCurvePen(), setCurveStyle(), setCurveSymbol(), setCurveTitle(), and setLegendDisplayPolicy(). |
|
Update the focus tab order. Definition at line 501 of file qwt_plot.cpp. References QwtLegend::contentsWidget(), and QwtPlotLayout::legendPosition(). Referenced by setLegendPosition(). |
|
Designer API for axisEnabled. Definition at line 150 of file qwt_plot.h. |
|
Designer API for axisEnabled. Definition at line 154 of file qwt_plot.h. |
|
Designer API for axisEnabled. Definition at line 162 of file qwt_plot.h. |
|
Designer API for axisEnabled. Definition at line 158 of file qwt_plot.h. |