PySide6.QtSensors.QOrientationSensor

class QOrientationSensor

QOrientationSensor 类是 QSensor 的一个便捷封装。更多

PySide6.QtSensors.QOrientationSensor 的继承图

概要

方法

注意

本文档可能包含从C++自动翻译到Python的代码片段。我们始终欢迎对代码片段翻译的贡献。如果您发现翻译问题,您也可以通过在我们的https:/bugreports.qt.io/projects/PYSIDE上创建工单来告知我们。

详细描述

唯一的行为差异是这个类正确地设置了类型。

这个类还包含一个reading()函数,它返回一个QOrientationReading而不是QSensorReading

有关传感器工作原理的详细信息,请参见QOrientationReading

另请参阅

QOrientationReading

PySide6.QtSensors.QOrientationSensor.sensorType
__init__([parent=None])
Parameters:

父对象QObject

将传感器构造为parent的子级。