StatusIndicator QML 类型

指示器显示活动 (或不活动) 状态。 更多...

import 语句: import QtQuick.Extras 1.4
Since: Qt 5.5

特性

详细描述

A StatusIndicator in the active state

A StatusIndicator in the active state.

A StatusIndicator in the inactive state

A StatusIndicator in the inactive state.

The StatusIndicator displays active or inactive states. By using different colors via the color property, StatusIndicator can provide extra context to these states. For example:

QML 结果
import QtQuick 2.2
import QtQuick.Extras 1.4
Rectangle {
    width: 100
    height: 100
    color: "#cccccc"
    StatusIndicator {
        anchors.centerIn: parent
        color: "green"
    }
}
								
"Green StatusIndicator"

You can create a custom appearance for a StatusIndicator by assigning a StatusIndicatorStyle .

特性文档编制

active : bool

此特性指定指示器是活动的,还是不活动的。

默认值为 false (不活动)。

color : color

此特性指定指示器的颜色当它是活动的。

默认值为 "red" .