In questa pagina

QPressureSensor Class

La classe QPressureSensor è un wrapper di comodità che avvolge QSensor. Per saperne di più...

Intestazione: #include <QPressureSensor>
CMake: find_package(Qt6 REQUIRED COMPONENTS Sensors)
target_link_libraries(mytarget PRIVATE Qt6::Sensors)
qmake: QT += sensors
Eredita: QSensor

Funzioni pubbliche

QPressureSensor(QObject *parent = nullptr)
virtual ~QPressureSensor()
QPressureReading *reading() const

Descrizione dettagliata

L'unica differenza comportamentale è che questa classe imposta correttamente il tipo.

Questa classe dispone inoltre di una funzione reading() che restituisce un QPressureReading anziché un QSensorReading.

Per i dettagli sul funzionamento del sensore, consultare QPressureReading.

Vedi anche QPressureReading.

Documentazione sulle funzioni membro

[explicit] QPressureSensor::QPressureSensor(QObject *parent = nullptr)

Crea il sensore come elemento figlio di parent.

[virtual noexcept] QPressureSensor::~QPressureSensor()

Distruggi il sensore. Arresta il sensore, se non è già stato arrestato.

QPressureReading *QPressureSensor::reading() const

Restituisce la classe di lettura per questo sensore.

Vedi anche QSensor::reading().

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.