Skip to content

Class QAccelPlot::AxisTicker

ClassList > QAccelPlot > AxisTicker

Controls the visual appearance of ticks, sub-ticks, and tick labels on an Axis .More...

  • #include <AxisTicker.hpp>

Inherits the following classes: QObject

Inheritance diagram

flowchart TB
  classQAccelPlot_1_1AxisTicker["QAccelPlot::AxisTicker"]

  external_base_classQAccelPlot_1_1AxisTicker_1["QObject"]
  external_base_classQAccelPlot_1_1AxisTicker_1 --> classQAccelPlot_1_1AxisTicker

Public Properties

Type Name
property QColor subtickColor
Color of sub-tick marks. Default: Colors.dark.subtick .
property int subtickCount
Number of sub-tick intervals between adjacent major ticks. Default: 10.
property qreal subtickLength
Convenience setter for both subtickLengthIn andsubtickLengthOut simultaneously.
property qreal subtickLengthIn
Inward length in pixels of sub-tick marks. Default: 4.
property qreal subtickLengthOut
Outward length in pixels of sub-tick marks. Default: 4.
property qreal subtickWidth
Width in pixels of sub-tick mark lines. Default: 1.
property QML_ANONYMOUSQColor tickColor
Color of major tick marks. Default: Colors.dark.tick .
property int tickCount
Target number of major tick marks. Actual count is adjusted for "nice" values. Default: 5.
property QColor tickLabelColor
Optional color of tick labels. When invalid, the tickColor is used.
property QFont tickLabelFont
Font used to render tick labels. Default: application default font.
property TickLabelFormatter * tickLabelFormatter
Optional custom formatter for tick labels. When nullptr the defaultNumericTickLabelFormatter is used.
property qreal tickLabelPadding
Spacing in pixels between a tick mark and its label. Default: 5.
property qreal tickLabelRotation
Rotation angle in degrees applied to each tick label. Default: 0.
property qreal tickLength
Convenience setter for both tickLengthIn andtickLengthOut simultaneously.
property qreal tickLengthIn
Length in pixels of the portion of a major tick that extends into the plot area. Default: 8.
property qreal tickLengthOut
Length in pixels of the portion of a major tick that extends outside the plot area. Default: 8.
property qreal tickWidth
Width in pixels of major tick mark lines. Default: 2.

Public Signals

Type Name
signal void subtickColorChanged
Emitted when the subtickColor property changes.
signal void subtickCountChanged
Emitted when the subtickCount property changes.
signal void subtickLengthChanged
Emitted when the subtickLength convenience property changes.
signal void subtickLengthInChanged
Emitted when the subtickLengthIn property changes.
signal void subtickLengthOutChanged
Emitted when the subtickLengthOut property changes.
signal void subtickWidthChanged
Emitted when the subtickWidth property changes.
signal void tickColorChanged
Emitted when the tickColor property changes.
signal void tickCountChanged
Emitted when the tickCount property changes.
signal void tickLabelColorChanged
Emitted when the tickLabelColor property changes.
signal void tickLabelFontChanged
Emitted when the tickLabelFont property changes.
signal void tickLabelFormatChanged
Emitted when the current formatter's output configuration changes.
signal void tickLabelFormatterChanged
Emitted when the tickLabelFormatter property changes.
signal void tickLabelPaddingChanged
Emitted when the tickLabelPadding property changes.
signal void tickLabelRotationChanged
Emitted when the tickLabelRotation property changes.
signal void tickLengthChanged
Emitted when the tickLength convenience property changes.
signal void tickLengthInChanged
Emitted when the tickLengthIn property changes.
signal void tickLengthOutChanged
Emitted when the tickLengthOut property changes.
signal void tickWidthChanged
Emitted when the tickWidth property changes.

Public Functions

Type Name
AxisTicker (QObject * parent=nullptr)
Constructs an AxisTicker with the given__parent .
void setSubtickColor (const QColor & c)
Sets the sub-tick color to c .
void setSubtickCount (int count)
Sets the sub-tick interval count to count .
void setSubtickLength (qreal length)
Sets both subtickLengthIn andsubtickLengthOut to__length .
void setSubtickLengthIn (qreal length)
Sets the inward sub-tick length to length .
void setSubtickLengthOut (qreal length)
Sets the outward sub-tick length to length .
void setSubtickWidth (qreal width)
Sets the sub-tick line width to width .
void setTickColor (const QColor & c)
Sets the major tick color to c .
void setTickCount (int count)
Sets the target major tick count to count .
void setTickLabelColor (const QColor & c)
Sets the tick-label color to c . An invalid color restores the tickColor fallback.
void setTickLabelFont (const QFont & f)
Sets the tick label font to f .
void setTickLabelFormatter (TickLabelFormatter * formatter)
Sets the tick label formatter to formatter .
void setTickLabelPadding (qreal padding)
Sets the tick label padding to padding .
void setTickLabelRotation (qreal rotation)
Sets the tick label rotation to rotation degrees.
void setTickLength (qreal length)
Sets both tickLengthIn andtickLengthOut to__length .
void setTickLengthIn (qreal length)
Sets the inward major tick length to length .
void setTickLengthOut (qreal length)
Sets the outward major tick length to length .
void setTickWidth (qreal width)
Sets the major tick line width to width .
QColor subtickColor () const
Returns the sub-tick color.
int subtickCount () const
Returns the sub-tick interval count.
qreal subtickLength () const
Returns the shared inward+outward sub-tick length (reads subtickLengthIn ).
qreal subtickLengthIn () const
Returns the inward sub-tick length.
qreal subtickLengthOut () const
Returns the outward sub-tick length.
qreal subtickWidth () const
Returns the sub-tick line width.
QColor tickColor () const
Returns the major tick color.
int tickCount () const
Returns the target number of major ticks.
QColor tickLabelColor () const
Returns the tick-label color, or an invalid color when it follows tickColor.
QFont tickLabelFont () const
Returns the tick label font.
TickLabelFormatter * tickLabelFormatter () const
Returns the custom tick label formatter, or nullptr if using the default.
qreal tickLabelPadding () const
Returns the tick label padding.
qreal tickLabelRotation () const
Returns the tick label rotation in degrees.
qreal tickLength () const
Returns the shared inward+outward tick length (reads tickLengthIn ).
qreal tickLengthIn () const
Returns the inward major tick length.
qreal tickLengthOut () const
Returns the outward major tick length.
qreal tickWidth () const
Returns the major tick line width.

Detailed Description

Accessible via the Axis::ticker CONSTANT property. Changes are applied on the next paint event.

See also: Axis

Public Properties Documentation

property subtickColor

Color of sub-tick marks. Default: Colors.dark.subtick .

QColor QAccelPlot::AxisTicker::subtickColor;


property subtickCount

Number of sub-tick intervals between adjacent major ticks. Default: 10.

int QAccelPlot::AxisTicker::subtickCount;


property subtickLength

Convenience setter for both subtickLengthIn andsubtickLengthOut simultaneously.

qreal QAccelPlot::AxisTicker::subtickLength;


property subtickLengthIn

Inward length in pixels of sub-tick marks. Default: 4.

qreal QAccelPlot::AxisTicker::subtickLengthIn;


property subtickLengthOut

Outward length in pixels of sub-tick marks. Default: 4.

qreal QAccelPlot::AxisTicker::subtickLengthOut;


property subtickWidth

Width in pixels of sub-tick mark lines. Default: 1.

qreal QAccelPlot::AxisTicker::subtickWidth;


property tickColor

Color of major tick marks. Default: Colors.dark.tick .

QML_ANONYMOUSQColor QAccelPlot::AxisTicker::tickColor;


property tickCount

Target number of major tick marks. Actual count is adjusted for "nice" values. Default: 5.

int QAccelPlot::AxisTicker::tickCount;


property tickLabelColor

Optional color of tick labels. When invalid, the tickColor is used.

QColor QAccelPlot::AxisTicker::tickLabelColor;


property tickLabelFont

Font used to render tick labels. Default: application default font.

QFont QAccelPlot::AxisTicker::tickLabelFont;


property tickLabelFormatter

Optional custom formatter for tick labels. When nullptr the defaultNumericTickLabelFormatter is used.

TickLabelFormatter* QAccelPlot::AxisTicker::tickLabelFormatter;


property tickLabelPadding

Spacing in pixels between a tick mark and its label. Default: 5.

qreal QAccelPlot::AxisTicker::tickLabelPadding;


property tickLabelRotation

Rotation angle in degrees applied to each tick label. Default: 0.

qreal QAccelPlot::AxisTicker::tickLabelRotation;


property tickLength

Convenience setter for both tickLengthIn andtickLengthOut simultaneously.

qreal QAccelPlot::AxisTicker::tickLength;


property tickLengthIn

Length in pixels of the portion of a major tick that extends into the plot area. Default: 8.

qreal QAccelPlot::AxisTicker::tickLengthIn;


property tickLengthOut

Length in pixels of the portion of a major tick that extends outside the plot area. Default: 8.

qreal QAccelPlot::AxisTicker::tickLengthOut;


property tickWidth

Width in pixels of major tick mark lines. Default: 2.

qreal QAccelPlot::AxisTicker::tickWidth;


Public Signals Documentation

signal subtickColorChanged

Emitted when the subtickColor property changes.

void QAccelPlot::AxisTicker::subtickColorChanged;


signal subtickCountChanged

Emitted when the subtickCount property changes.

void QAccelPlot::AxisTicker::subtickCountChanged;


signal subtickLengthChanged

Emitted when the subtickLength convenience property changes.

void QAccelPlot::AxisTicker::subtickLengthChanged;


signal subtickLengthInChanged

Emitted when the subtickLengthIn property changes.

void QAccelPlot::AxisTicker::subtickLengthInChanged;


signal subtickLengthOutChanged

Emitted when the subtickLengthOut property changes.

void QAccelPlot::AxisTicker::subtickLengthOutChanged;


signal subtickWidthChanged

Emitted when the subtickWidth property changes.

void QAccelPlot::AxisTicker::subtickWidthChanged;


signal tickColorChanged

Emitted when the tickColor property changes.

void QAccelPlot::AxisTicker::tickColorChanged;


signal tickCountChanged

Emitted when the tickCount property changes.

void QAccelPlot::AxisTicker::tickCountChanged;


signal tickLabelColorChanged

Emitted when the tickLabelColor property changes.

void QAccelPlot::AxisTicker::tickLabelColorChanged;


signal tickLabelFontChanged

Emitted when the tickLabelFont property changes.

void QAccelPlot::AxisTicker::tickLabelFontChanged;


signal tickLabelFormatChanged

Emitted when the current formatter's output configuration changes.

void QAccelPlot::AxisTicker::tickLabelFormatChanged;


signal tickLabelFormatterChanged

Emitted when the tickLabelFormatter property changes.

void QAccelPlot::AxisTicker::tickLabelFormatterChanged;


signal tickLabelPaddingChanged

Emitted when the tickLabelPadding property changes.

void QAccelPlot::AxisTicker::tickLabelPaddingChanged;


signal tickLabelRotationChanged

Emitted when the tickLabelRotation property changes.

void QAccelPlot::AxisTicker::tickLabelRotationChanged;


signal tickLengthChanged

Emitted when the tickLength convenience property changes.

void QAccelPlot::AxisTicker::tickLengthChanged;


signal tickLengthInChanged

Emitted when the tickLengthIn property changes.

void QAccelPlot::AxisTicker::tickLengthInChanged;


signal tickLengthOutChanged

Emitted when the tickLengthOut property changes.

void QAccelPlot::AxisTicker::tickLengthOutChanged;


signal tickWidthChanged

Emitted when the tickWidth property changes.

void QAccelPlot::AxisTicker::tickWidthChanged;


Public Functions Documentation

function AxisTicker

Constructs an AxisTicker with the given__parent .

explicit QAccelPlot::AxisTicker::AxisTicker (
    QObject * parent=nullptr
) 


function setSubtickColor

Sets the sub-tick color to c .

void QAccelPlot::AxisTicker::setSubtickColor (
    const QColor & c
) 


function setSubtickCount

Sets the sub-tick interval count to count .

void QAccelPlot::AxisTicker::setSubtickCount (
    int count
) 


function setSubtickLength

Sets both subtickLengthIn andsubtickLengthOut to__length .

void QAccelPlot::AxisTicker::setSubtickLength (
    qreal length
) 


function setSubtickLengthIn

Sets the inward sub-tick length to length .

void QAccelPlot::AxisTicker::setSubtickLengthIn (
    qreal length
) 


function setSubtickLengthOut

Sets the outward sub-tick length to length .

void QAccelPlot::AxisTicker::setSubtickLengthOut (
    qreal length
) 


function setSubtickWidth

Sets the sub-tick line width to width .

void QAccelPlot::AxisTicker::setSubtickWidth (
    qreal width
) 


function setTickColor

Sets the major tick color to c .

void QAccelPlot::AxisTicker::setTickColor (
    const QColor & c
) 


function setTickCount

Sets the target major tick count to count .

void QAccelPlot::AxisTicker::setTickCount (
    int count
) 


function setTickLabelColor

Sets the tick-label color to c . An invalid color restores the tickColor fallback.

void QAccelPlot::AxisTicker::setTickLabelColor (
    const QColor & c
) 


function setTickLabelFont

Sets the tick label font to f .

void QAccelPlot::AxisTicker::setTickLabelFont (
    const QFont & f
) 


function setTickLabelFormatter

Sets the tick label formatter to formatter .

void QAccelPlot::AxisTicker::setTickLabelFormatter (
    TickLabelFormatter * formatter
) 


function setTickLabelPadding

Sets the tick label padding to padding .

void QAccelPlot::AxisTicker::setTickLabelPadding (
    qreal padding
) 


function setTickLabelRotation

Sets the tick label rotation to rotation degrees.

void QAccelPlot::AxisTicker::setTickLabelRotation (
    qreal rotation
) 


function setTickLength

Sets both tickLengthIn andtickLengthOut to__length .

void QAccelPlot::AxisTicker::setTickLength (
    qreal length
) 


function setTickLengthIn

Sets the inward major tick length to length .

void QAccelPlot::AxisTicker::setTickLengthIn (
    qreal length
) 


function setTickLengthOut

Sets the outward major tick length to length .

void QAccelPlot::AxisTicker::setTickLengthOut (
    qreal length
) 


function setTickWidth

Sets the major tick line width to width .

void QAccelPlot::AxisTicker::setTickWidth (
    qreal width
) 


function subtickColor

Returns the sub-tick color.

QColor QAccelPlot::AxisTicker::subtickColor () const


function subtickCount

Returns the sub-tick interval count.

int QAccelPlot::AxisTicker::subtickCount () const


function subtickLength

Returns the shared inward+outward sub-tick length (reads subtickLengthIn ).

qreal QAccelPlot::AxisTicker::subtickLength () const


function subtickLengthIn

Returns the inward sub-tick length.

qreal QAccelPlot::AxisTicker::subtickLengthIn () const


function subtickLengthOut

Returns the outward sub-tick length.

qreal QAccelPlot::AxisTicker::subtickLengthOut () const


function subtickWidth

Returns the sub-tick line width.

qreal QAccelPlot::AxisTicker::subtickWidth () const


function tickColor

Returns the major tick color.

QColor QAccelPlot::AxisTicker::tickColor () const


function tickCount

Returns the target number of major ticks.

int QAccelPlot::AxisTicker::tickCount () const


function tickLabelColor

Returns the tick-label color, or an invalid color when it follows tickColor.

QColor QAccelPlot::AxisTicker::tickLabelColor () const


function tickLabelFont

Returns the tick label font.

QFont QAccelPlot::AxisTicker::tickLabelFont () const


function tickLabelFormatter

Returns the custom tick label formatter, or nullptr if using the default.

TickLabelFormatter * QAccelPlot::AxisTicker::tickLabelFormatter () const


function tickLabelPadding

Returns the tick label padding.

qreal QAccelPlot::AxisTicker::tickLabelPadding () const


function tickLabelRotation

Returns the tick label rotation in degrees.

qreal QAccelPlot::AxisTicker::tickLabelRotation () const


function tickLength

Returns the shared inward+outward tick length (reads tickLengthIn ).

qreal QAccelPlot::AxisTicker::tickLength () const


function tickLengthIn

Returns the inward major tick length.

qreal QAccelPlot::AxisTicker::tickLengthIn () const


function tickLengthOut

Returns the outward major tick length.

qreal QAccelPlot::AxisTicker::tickLengthOut () const


function tickWidth

Returns the major tick line width.

qreal QAccelPlot::AxisTicker::tickWidth () const



The documentation for this class was generated from the following file QAccelPlot/src/QAccelPlot/axis/AxisTicker.hpp