QwtPlotPanner(3)

πŸ’… QwtPlotPanner(3) β€” Library Functions Manual ✨

okay bestie, buckle up 🫢 this is the QwtPlotPanner(3) page, and it’s lowkey iconic for anyone who wants to pan around a plot canvas like a main character.

🌸 NAME 🌸

QwtPlotPanner β€” QwtPlotPanner provides panning of a plot canvas.


✨ SYNOPSIS ✨

#include <qwt_plot_panner.h>

Inherits QwtPanner.

πŸŽ€ Public Slots πŸŽ€

  • virtual void moveCanvas (int dx, int dy) β€” public slot signature; the full tea is in the moveCanvas docs below πŸ‘‡

πŸ‘‘ Public Member Functions πŸ‘‘

  • QwtPlotPanner (QWidget *) β€” A panner for the canvas of a QwtPlot.
  • virtual ~QwtPlotPanner () β€” Destructor.
  • QWidget * canvas () β€” Return observed plot canvas.
  • const QWidget * canvas () const β€” Return Observed plot canvas.
  • QwtPlot * plot () β€” Return plot widget, containing the observed plot canvas.
  • const QwtPlot * plot () const β€” Return plot widget, containing the observed plot canvas.
  • void setAxisEnabled (QwtAxisId axisId, bool on) β€” En/Disable an axis.
  • bool isAxisEnabled (QwtAxisId) const β€” signature only in the source, no extra one-liner here.

πŸ‘‘ Public Member Functions inherited from QwtPanner πŸ‘‘

  • QwtPanner (QWidget *parent) β€” constructor signature; the source doesn’t add an extra description.
  • virtual ~QwtPanner () β€” Destructor.
  • void setEnabled (bool) β€” En/disable the panner.
  • bool isEnabled () const β€” signature only in the source.
  • void setMouseButton (Qt::MouseButton, Qt::KeyboardModifiers=Qt::NoModifier) β€” signature only in the source.
  • void getMouseButton (Qt::MouseButton &button, Qt::KeyboardModifiers &) const β€” Get mouse button and modifiers used for panning.
  • void setAbortKey (int key, Qt::KeyboardModifiers=Qt::NoModifier) β€” signature only in the source.
  • void getAbortKey (int &key, Qt::KeyboardModifiers &) const β€” Get the abort key and modifiers.
  • void setCursor (const QCursor &) β€” signature only in the source.
  • const QCursor cursor () const β€” signature only in the source.
  • void setOrientations (Qt::Orientations) β€” signature only in the source.
  • Qt::Orientations orientations () const β€” Return the orientation, where panning is enabled.
  • bool isOrientationEnabled (Qt::Orientation) const β€” signature only in the source.
  • virtual bool eventFilter (QObject *, QEvent *) override β€” Event filter.

πŸ›‘οΈ Protected Member Functions πŸ›‘οΈ

  • virtual QBitmap contentsMask () const override β€” protected override signature.
  • virtual QPixmap grab () const override β€” protected override signature.

πŸ”’ Protected Member Functions inherited from QwtPanner πŸ”’

  • virtual void widgetMousePressEvent (QMouseEvent *) β€” signature only in the source.
  • virtual void widgetMouseReleaseEvent (QMouseEvent *) β€” signature only in the source.
  • virtual void widgetMouseMoveEvent (QMouseEvent *) β€” signature only in the source.
  • virtual void widgetKeyPressEvent (QKeyEvent *) β€” signature only in the source.
  • virtual void widgetKeyReleaseEvent (QKeyEvent *) β€” signature only in the source.
  • virtual void paintEvent (QPaintEvent *) override β€” Paint event.

🌟 Additional Inherited Members 🌟

πŸ“‘ Signals inherited from QwtPanner πŸ“‘

  • void panned (int dx, int dy) β€” signal signature.
  • void moved (int dx, int dy) β€” signal signature.

🌈 Detailed Description 🌈

QwtPlotPanner provides panning of a plot canvas.

QwtPlotPanner is a panner for a plot canvas that adjusts the scales of the axes after dropping the canvas on its new position. yes bestie, it’s doing the glow-up math for you ✨

Together with QwtPlotZoomer and QwtPlotMagnifier, powerful ways of navigating on a QwtPlot widget can be implemented easily. team-up energy fr fr 🫢

⚠️ Note: The axes are not updated, while dragging the canvas.

See also: QwtPlotZoomer, QwtPlotMagnifier

Definition at line 32 of file qwt_plot_panner.h.


πŸŽ€ Constructor & Destructor Documentation πŸŽ€

QwtPlotPanner::QwtPlotPanner (QWidget * canvas) [explicit]

A panner for the canvas of a QwtPlot. The panner is enabled for all axes.

Parameters

  • canvas β€” Plot canvas to pan, also the parent object.

See also: setAxisEnabled()

Definition at line 128 of file qwt_plot_panner.cpp.

QwtPlotPanner::~QwtPlotPanner () [virtual]

Destructor.

Definition at line 138 of file qwt_plot_panner.cpp.


πŸ’– Member Function Documentation πŸ’–

QWidget * QwtPlotPanner::canvas ()

Return observed plot canvas.

Definition at line 177 of file qwt_plot_panner.cpp.

const QWidget * QwtPlotPanner::canvas () const

Return Observed plot canvas.

Definition at line 183 of file qwt_plot_panner.cpp.

QBitmap QwtPlotPanner::contentsMask () const [override], [protected], [virtual]

Calculate a mask from the border path of the canvas.

Returns: Mask as bitmap.

See also: QwtPlotCanvas::borderPath()

Reimplemented from: QwtPanner.

Definition at line 267 of file qwt_plot_panner.cpp.

QPixmap QwtPlotPanner::grab () const [override], [protected], [virtual]

Returns: Pixmap with the content of the canvas.

Reimplemented from: QwtPanner.

Definition at line 278 of file qwt_plot_panner.cpp.

bool QwtPlotPanner::isAxisEnabled (QwtAxisId axisId) const

Test if an axis is enabled.

Parameters

  • axisId β€” Axis.

Returns: True, if the axis is enabled.

See also: setAxisEnabled(), moveCanvas()

Definition at line 168 of file qwt_plot_panner.cpp.

void QwtPlotPanner::moveCanvas (int dx, int dy) [virtual], [slot]

Adjust the enabled axes according to dx/dy.

Parameters

  • dx β€” Pixel offset in x direction.
  • dy β€” Pixel offset in y direction.

See also: QwtPanner::panned()

Definition at line 216 of file qwt_plot_panner.cpp.

QwtPlot * QwtPlotPanner::plot ()

Return plot widget, containing the observed plot canvas.

Definition at line 189 of file qwt_plot_panner.cpp.

const QwtPlot * QwtPlotPanner::plot () const

Return plot widget, containing the observed plot canvas.

Definition at line 199 of file qwt_plot_panner.cpp.

void QwtPlotPanner::setAxisEnabled (QwtAxisId axisId, bool on)

En/Disable an axis. Axes that are enabled will be synchronized to the result of panning. All other axes will remain unchanged.

Parameters

  • axisId β€” Axis id.
  • on β€” On/Off.

See also: isAxisEnabled(), moveCanvas()

Definition at line 154 of file qwt_plot_panner.cpp.


🌟 Author 🌟

Generated automatically by Doxygen for Qwt User's Guide from the source code.


mwah πŸ’‹ that’s the whole page, bestie β€” the footer gives source/version <purple>Qwt User's Guide</purple> and page tag <pink>QwtPlotPanner(3)</pink> (no date in this footer, just those bits). periodt 🫢✨

πŸ“¦ where this page comes from