|
| | QCPAbstractLegendItem (QCPLegend *parent) |
| | Constructs a QCPAbstractLegendItem and associates it with the QCPLegend parent.
|
| |
|
QCPLegend * | parentLegend () const |
| |
|
QFont | font () const |
| |
|
QColor | textColor () const |
| |
|
QFont | selectedFont () const |
| |
|
QColor | selectedTextColor () const |
| |
|
bool | selectable () const |
| |
|
bool | selected () const |
| |
| void | setFont (const QFont &font) |
| | Sets the default font of this specific legend item to font.
|
| |
| void | setTextColor (const QColor &color) |
| | Sets the default text color of this specific legend item to color.
|
| |
| void | setSelectedFont (const QFont &font) |
| | When this legend item is selected, font is used to draw generic text, instead of the normal font set with setFont.
|
| |
| void | setSelectedTextColor (const QColor &color) |
| | When this legend item is selected, color is used to draw generic text, instead of the normal color set with setTextColor.
|
| |
| Q_SLOT void | setSelectable (bool selectable) |
| | Sets whether this specific legend item is selectable.
|
| |
| Q_SLOT void | setSelected (bool selected) |
| | Sets whether this specific legend item is selected.
|
| |
| virtual double | selectTest (const QPointF &pos, bool onlySelectable, QVariant *details=0) const Q_DECL_OVERRIDE |
| | Layout elements are sensitive to events inside their outer rect.
|
| |
|
| QCPLayoutElement (QCustomPlot *parentPlot=0) |
| | Creates an instance of QCPLayoutElement and sets default values.
|
| |
|
QCPLayout * | layout () const |
| | Returns the parent layout of this layout element.
|
| |
| QRect | rect () const |
| | Returns the inner rect of this layout element.
|
| |
| QRect | outerRect () const |
| | Returns the outer rect of this layout element.
|
| |
|
QMargins | margins () const |
| |
|
QMargins | minimumMargins () const |
| |
|
QCP::MarginSides | autoMargins () const |
| |
|
QSize | minimumSize () const |
| |
|
QSize | maximumSize () const |
| |
|
SizeConstraintRect | sizeConstraintRect () const |
| |
|
QCPMarginGroup * | marginGroup (QCP::MarginSide side) const |
| |
|
QHash< QCP::MarginSide, QCPMarginGroup * > | marginGroups () const |
| |
| void | setOuterRect (const QRect &rect) |
| | Sets the outer rect of this layout element.
|
| |
| void | setMargins (const QMargins &margins) |
| | Sets the margins of this layout element.
|
| |
| void | setMinimumMargins (const QMargins &margins) |
| | If setAutoMargins is enabled on some or all margins, this function is used to provide minimum values for those margins.
|
| |
| void | setAutoMargins (QCP::MarginSides sides) |
| | Sets on which sides the margin shall be calculated automatically.
|
| |
| void | setMinimumSize (const QSize &size) |
| | Sets the minimum size of this layout element.
|
| |
| void | setMinimumSize (int width, int height) |
| | This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.Sets the minimum size of this layout element.
|
| |
| void | setMaximumSize (const QSize &size) |
| | Sets the maximum size of this layout element.
|
| |
| void | setMaximumSize (int width, int height) |
| | This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.Sets the maximum size of this layout element.
|
| |
| void | setSizeConstraintRect (SizeConstraintRect constraintRect) |
| | Sets to which rect of a layout element the size constraints apply.
|
| |
| void | setMarginGroup (QCP::MarginSides sides, QCPMarginGroup *group) |
| | Sets the margin group of the specified margin sides.
|
| |
| virtual void | update (UpdatePhase phase) |
| | Updates the layout element and sub-elements.
|
| |
| virtual QSize | minimumOuterSizeHint () const |
| | Returns the suggested minimum size this layout element (the outerRect) may be compressed to, if no manual minimum size is set.
|
| |
| virtual QSize | maximumOuterSizeHint () const |
| | Returns the suggested maximum size this layout element (the outerRect) may be expanded to, if no manual maximum size is set.
|
| |
| virtual QList< QCPLayoutElement * > | elements (bool recursive) const |
| | Returns a list of all child elements in this layout element.
|
| |
| virtual double | selectTest (const QPointF &pos, bool onlySelectable, QVariant *details=0) const Q_DECL_OVERRIDE |
| | Layout elements are sensitive to events inside their outer rect.
|
| |
| | QCPLayerable (QCustomPlot *plot, QString targetLayer=QString(), QCPLayerable *parentLayerable=0) |
| | Creates a new QCPLayerable instance.
|
| |
|
bool | visible () const |
| |
|
QCustomPlot * | parentPlot () const |
| |
| QCPLayerable * | parentLayerable () const |
| | Returns the parent layerable of this layerable.
|
| |
|
QCPLayer * | layer () const |
| |
|
bool | antialiased () const |
| |
| void | setVisible (bool on) |
| | Sets the visibility of this layerable object.
|
| |
| Q_SLOT bool | setLayer (QCPLayer *layer) |
| | Sets the layer of this layerable object.
|
| |
| bool | setLayer (const QString &layerName) |
| | This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Sets the layer of this layerable object by name.
|
| |
| void | setAntialiased (bool enabled) |
| | Sets whether this object will be drawn antialiased or not.
|
| |
| virtual double | selectTest (const QPointF &pos, bool onlySelectable, QVariant *details=0) const |
| | This function is used to decide whether a click hits a layerable object or not.
|
| |
| bool | realVisibility () const |
| | Returns whether this layerable is visible, taking the visibility of the layerable parent and the visibility of this layerable's layer into account.
|
| |
|
| virtual QCP::Interaction | selectionCategory () const Q_DECL_OVERRIDE |
| |
| virtual void | applyDefaultAntialiasingHint (QCPPainter *painter) const Q_DECL_OVERRIDE |
| |
| virtual QRect | clipRect () const Q_DECL_OVERRIDE |
| |
| virtual void | draw (QCPPainter *painter) Q_DECL_OVERRIDE=0 |
| |
| virtual void | selectEvent (QMouseEvent *event, bool additive, const QVariant &details, bool *selectionStateChanged) Q_DECL_OVERRIDE |
| |
| virtual void | deselectEvent (bool *selectionStateChanged) Q_DECL_OVERRIDE |
| |
|
virtual int | calculateAutoMargin (QCP::MarginSide side) |
| |
|
virtual void | layoutChanged () |
| |
| virtual void | applyDefaultAntialiasingHint (QCPPainter *painter) const Q_DECL_OVERRIDE |
| |
| virtual void | draw (QCPPainter *painter) Q_DECL_OVERRIDE |
| |
| virtual void | parentPlotInitialized (QCustomPlot *parentPlot) Q_DECL_OVERRIDE |
| |
|
virtual void | parentPlotInitialized (QCustomPlot *parentPlot) |
| |
|
virtual QCP::Interaction | selectionCategory () const |
| |
|
virtual QRect | clipRect () const |
| |
|
virtual void | applyDefaultAntialiasingHint (QCPPainter *painter) const =0 |
| |
|
virtual void | draw (QCPPainter *painter)=0 |
| |
|
virtual void | selectEvent (QMouseEvent *event, bool additive, const QVariant &details, bool *selectionStateChanged) |
| |
|
virtual void | deselectEvent (bool *selectionStateChanged) |
| |
| virtual void | mousePressEvent (QMouseEvent *event, const QVariant &details) |
| | This event gets called when the user presses a mouse button while the cursor is over the layerable.
|
| |
| virtual void | mouseMoveEvent (QMouseEvent *event, const QPointF &startPos) |
| | This event gets called when the user moves the mouse while holding a mouse button, after this layerable has become the mouse grabber by accepting the preceding mousePressEvent.
|
| |
| virtual void | mouseReleaseEvent (QMouseEvent *event, const QPointF &startPos) |
| | This event gets called when the user releases the mouse button, after this layerable has become the mouse grabber by accepting the preceding mousePressEvent.
|
| |
| virtual void | mouseDoubleClickEvent (QMouseEvent *event, const QVariant &details) |
| | This event gets called when the user presses the mouse button a second time in a double-click, while the cursor is over the layerable.
|
| |
| virtual void | wheelEvent (QWheelEvent *event) |
| | This event gets called when the user turns the mouse scroll wheel while the cursor is over the layerable.
|
| |
|
void | initializeParentPlot (QCustomPlot *parentPlot) |
| |
|
void | setParentLayerable (QCPLayerable *parentLayerable) |
| |
|
bool | moveToLayer (QCPLayer *layer, bool prepend) |
| |
|
void | applyAntialiasingHint (QCPPainter *painter, bool localAntialiased, QCP::AntialiasedElement overrideElement) const |
| |
The abstract base class for all entries in a QCPLegend.
It defines a very basic interface for entries in a QCPLegend. For representing plottables in the legend, the subclass QCPPlottableLegendItem is more suitable.
Only derive directly from this class when you need absolute freedom (e.g. a custom legend entry that's not even associated with a plottable).
You must implement the following pure virtual functions:
You inherit the following members you may use:
| QCPLegend *mParentLegend | A pointer to the parent QCPLegend. |
| QFont mFont | The generic font of the item. You should use this font for all or at least the most prominent text of the item. |