Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
QQuickRangeSliderNodePrivate Class Reference

Used to select a range of values by sliding two handles along a track. More...

Inheritance diagram for QQuickRangeSliderNodePrivate:
Collaboration diagram for QQuickRangeSliderNodePrivate:

Public Member Functions

 QQuickRangeSliderNodePrivate (qreal value, QQuickRangeSlider *slider)
bool isFirst () const
void setPosition (qreal position, bool ignoreOtherPosition=false)
void updatePosition (bool ignoreOtherPosition=false)
void cancelHandle ()
void executeHandle (bool complete=false)
 QQuickRangeSliderNodePrivate (qreal value, QQuickRangeSlider *slider)
bool isFirst () const
void setPosition (qreal position, bool ignoreOtherPosition=false)
void updatePosition (bool ignoreOtherPosition=false)
void cancelHandle ()
void executeHandle (bool complete=false)
Public Member Functions inherited from QObjectPrivate
void ensureExtraData ()
void setObjectNameWithoutBindings (const QString &name)
 QObjectPrivate (decltype(QObjectPrivateVersion) version=QObjectPrivateVersion)
virtual ~QObjectPrivate ()
void deleteChildren ()
void clearBindingStorage ()
void setParent_helper (QObject *)
void moveToThread_helper ()
void setThreadData_helper (QThreadData *currentData, QThreadData *targetData, QBindingStatus *status)
QObjectList receiverList (const char *signal) const
void ensureConnectionData ()
void addConnection (int signal, Connection *c)
int signalIndex (const char *signalName, const QMetaObject **meta=nullptr) const
bool isSignalConnected (uint signalIdx, bool checkDeclarative=true) const
bool maybeSignalConnected (uint signalIndex) const
bool isDeclarativeSignalConnected (uint signalIdx) const
void connectNotify (const QMetaMethod &signal)
void disconnectNotify (const QMetaMethod &signal)
void reinitBindingStorageAfterThreadMove ()
virtual std::string flagsForDumping () const
virtual void writeToDebugStream (QDebug &) const
QtPrivate::QPropertyAdaptorSlotObjectgetPropertyAdaptorSlotObject (const QMetaProperty &property)
Public Member Functions inherited from QObjectData
 QObjectData ()=default
virtual ~QObjectData ()=0
const QMetaObjectdynamicMetaObject () const

Static Public Member Functions

static QQuickRangeSliderNodePrivateget (QQuickRangeSliderNode *node)
static QQuickRangeSliderNodePrivateget (QQuickRangeSliderNode *node)
Static Public Member Functions inherited from QObjectPrivate
static bool removeConnection (Connection *c)
static QObjectPrivateget (QObject *o)
static const QObjectPrivateget (const QObject *o)
template<typename Func1, typename Func2>
static QMetaObject::Connection connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot, Qt::ConnectionType type=Qt::AutoConnection)
template<typename Func1, typename Func2>
static bool disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiverPrivate, Func2 slot)
static QMetaObject::Connection connectImpl (const QObject *sender, int signal_index, const QObject *receiver, void **slot, QtPrivate::QSlotObjectBase *slotObj, int type, const int *types, const QMetaObject *senderMetaObject)
static QMetaObject::Connection connect (const QObject *sender, int signal_index, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type)
static QMetaObject::Connection connect (const QObject *sender, int signal_index, const QObject *receiver, QtPrivate::QSlotObjectBase *slotObj, Qt::ConnectionType type)
static bool disconnect (const QObject *sender, int signal_index, void **slot)
static bool disconnect (const QObject *sender, int signal_index, const QObject *receiver, void **slot)

Public Attributes

qreal value = 0
bool isPendingValue = false
qreal pendingValue = 0
qreal position = 0
QQuickDeferredPointer< QQuickItemhandle
QQuickRangeSliderslider = nullptr
bool pressed = false
bool hovered = false
int touchId = -1
Public Attributes inherited from QObjectPrivate
ExtraDataextraData
QAtomicPointer< QThreadDatathreadData
QAtomicPointer< ConnectionDataconnections
union { 
   QObject *   currentChildBeingDeleted 
   QAbstractDeclarativeData *   declarativeData 
}; 
QAtomicPointer< QtSharedPointer::ExternalRefCountDatasharedRefcount
Public Attributes inherited from QObjectData
QObjectq_ptr
QObjectparent
QObjectList children
uint isWidget: 1
uint blockSig: 1
uint wasDeleted: 1
uint isDeletingChildren: 1
uint sendChildEvents: 1
uint receiveChildEvents: 1
uint isWindow: 1
uint deleteLaterCalled: 1
uint isQuickItem: 1
uint willBeWidget: 1
uint wasWidget: 1
uint receiveParentEvents: 1
uint unused: 20
QAtomicInt postedEvents
QDynamicMetaObjectDatametaObject
QBindingStorage bindingStorage

Additional Inherited Members

Public Types inherited from QObjectPrivate
typedef void(* StaticMetaCallFunction) (QObject *, QMetaObject::Call, int, void **)
using ConnectionDataPointer = QExplicitlySharedDataPointer<ConnectionData>

Detailed Description

Used to select a range of values by sliding two handles along a track.

\qmltype RangeSlider
\inherits Control

! \nativetype QQuickRangeSlider \inqmlmodule QtQuick.Controls

Since
5.7

RangeSlider is used to select a range specified by two values, by sliding each handle along a track.

In the example below, custom \l from and \l to values are set, and the initial positions of the \l first and \l second handles are set:

RangeSlider {
from: 1
to: 100
first.value: 25
second.value: 75
}
GLint first

In order to perform an action when the value for a particular handle changes, use the following syntax:

first.onMoved: console.log("first.value changed to " + first.value)

The \l {first.position} and \l {second.position} properties are expressed as fractions of the control's size, in the range {0.0 - 1.0}. The \l {first.visualPosition} and \l {second.visualPosition} properties are the same, except that they are reversed in a \l {Right-to-left User Interfaces}{right-to-left} application. The visualPosition is useful for positioning the handles when styling RangeSlider. In the example above, \l {first.visualPosition} will be 0.24 in a left-to-right application, and 0.76 in a right-to-left application.

For a slider that allows the user to select a single value, see \l Slider.

See also
{Customizing RangeSlider}, {Input Controls}, {Focus Management in Qt Quick Controls}

Definition at line 63 of file qquickrangeslider.cpp.

Constructor & Destructor Documentation

◆ QQuickRangeSliderNodePrivate() [1/2]

QQuickRangeSliderNodePrivate::QQuickRangeSliderNodePrivate ( qreal value,
QQuickRangeSlider * slider )
inline

Definition at line 67 of file qquickrangeslider.cpp.

◆ QQuickRangeSliderNodePrivate() [2/2]

QQuickRangeSliderNodePrivate::QQuickRangeSliderNodePrivate ( qreal value,
QQuickRangeSlider * slider )
inline

Definition at line 67 of file qquickrangeslider.cpp.

Member Function Documentation

◆ cancelHandle() [1/2]

void QQuickRangeSliderNodePrivate::cancelHandle ( )

Definition at line 121 of file qquickrangeslider.cpp.

◆ cancelHandle() [2/2]

void QQuickRangeSliderNodePrivate::cancelHandle ( )

◆ executeHandle() [1/2]

void QQuickRangeSliderNodePrivate::executeHandle ( bool complete = false)

Definition at line 127 of file qquickrangeslider.cpp.

◆ executeHandle() [2/2]

void QQuickRangeSliderNodePrivate::executeHandle ( bool complete = false)

◆ get() [1/2]

QQuickRangeSliderNodePrivate * QQuickRangeSliderNodePrivate::get ( QQuickRangeSliderNode * node)
static

Definition at line 139 of file qquickrangeslider.cpp.

Referenced by QQuickRangeSliderPrivate::handleMove(), QQuickRangeSliderPrivate::handleRelease(), QQuickRangeSliderPrivate::handleUngrab(), and QQuickRangeSliderPrivate::pressedNode().

Here is the caller graph for this function:

◆ get() [2/2]

QQuickRangeSliderNodePrivate * QQuickRangeSliderNodePrivate::get ( QQuickRangeSliderNode * node)
static

◆ isFirst() [1/2]

bool QQuickRangeSliderNodePrivate::isFirst ( ) const

Definition at line 94 of file qquickrangeslider.cpp.

◆ isFirst() [2/2]

bool QQuickRangeSliderNodePrivate::isFirst ( ) const

◆ setPosition() [1/2]

void QQuickRangeSliderNodePrivate::setPosition ( qreal position,
bool ignoreOtherPosition = false )

Definition at line 99 of file qquickrangeslider.cpp.

◆ setPosition() [2/2]

void QQuickRangeSliderNodePrivate::setPosition ( qreal position,
bool ignoreOtherPosition = false )

◆ updatePosition() [1/2]

void QQuickRangeSliderNodePrivate::updatePosition ( bool ignoreOtherPosition = false)

Definition at line 113 of file qquickrangeslider.cpp.

◆ updatePosition() [2/2]

void QQuickRangeSliderNodePrivate::updatePosition ( bool ignoreOtherPosition = false)

Member Data Documentation

◆ handle

QQuickDeferredPointer< QQuickItem > QQuickRangeSliderNodePrivate::handle

Definition at line 87 of file qquickrangeslider.cpp.

◆ hovered

bool QQuickRangeSliderNodePrivate::hovered = false

Definition at line 90 of file qquickrangeslider.cpp.

◆ isPendingValue

bool QQuickRangeSliderNodePrivate::isPendingValue = false

Definition at line 84 of file qquickrangeslider.cpp.

◆ pendingValue

qreal QQuickRangeSliderNodePrivate::pendingValue = 0

Definition at line 85 of file qquickrangeslider.cpp.

◆ position

qreal QQuickRangeSliderNodePrivate::position = 0

Definition at line 86 of file qquickrangeslider.cpp.

◆ pressed

bool QQuickRangeSliderNodePrivate::pressed = false

Definition at line 89 of file qquickrangeslider.cpp.

◆ slider

QQuickRangeSlider * QQuickRangeSliderNodePrivate::slider = nullptr

Definition at line 88 of file qquickrangeslider.cpp.

◆ touchId

int QQuickRangeSliderNodePrivate::touchId = -1

◆ value

qreal QQuickRangeSliderNodePrivate::value = 0

Definition at line 83 of file qquickrangeslider.cpp.


The documentation for this class was generated from the following file: