Styled text label with inherited font. 更多...
| import 語句: |
import QtQuick.Controls
|
| 繼承: |
(since QtQuick.Controls 2.5 (Qt 5.12))
(since QtQuick.Controls 2.5 (Qt 5.12))
(since QtQuick.Controls 2.5 (Qt 5.12))
(since QtQuick.Controls 2.5 (Qt 5.12))
(since QtQuick.Controls 2.5 (Qt 5.12))
(since QtQuick.Controls 2.5 (Qt 5.12))
Label extends 文本 with styling and font inheritance. The default colors and font are style specific. Label can also have a visual background 項。
Label { text: "Label" }
You can use the properties of 文本 to change the appearance of the text as desired:
Label { text: "Hello world" font.pixelSize: 22 font.italic: true }
另請參閱 Customizing Label .
|
background : Item |
此特性保持背景項。
注意: If the background item has no explicit size specified, it automatically follows the control's size. In most cases, there is no need to specify width or height for a background item.
另請參閱 Customizing Label .
|
bottomInset
:
real
|
This property holds the bottom inset for the background.
該特性在 QtQuick.Controls 2.5 (Qt 5.12) 引入。
另請參閱 Control Layout and topInset .
|
implicitBackgroundHeight
:
real
|
This property holds the implicit background height.
值等於
background ? background.implicitHeight : 0
.
該特性在 QtQuick.Controls 2.5 (Qt 5.12) 引入。
另請參閱 implicitBackgroundWidth .
|
implicitBackgroundWidth
:
real
|
This property holds the implicit background width.
值等於
background ? background.implicitWidth : 0
.
該特性在 QtQuick.Controls 2.5 (Qt 5.12) 引入。
另請參閱 implicitBackgroundHeight .
|
leftInset
:
real
|
This property holds the left inset for the background.
該特性在 QtQuick.Controls 2.5 (Qt 5.12) 引入。
另請參閱 Control Layout and rightInset .
|
rightInset
:
real
|
This property holds the right inset for the background.
該特性在 QtQuick.Controls 2.5 (Qt 5.12) 引入。
另請參閱 Control Layout and leftInset .
|
topInset
:
real
|
This property holds the top inset for the background.
該特性在 QtQuick.Controls 2.5 (Qt 5.12) 引入。
另請參閱 Control Layout and bottomInset .