Label QML Type
Etiqueta de texto con estilo y fuente heredada. Más...
| Import Statement: | import QtQuick.Controls |
| Inherits: |
Propiedades
- background : Item
- bottomInset : real
(since QtQuick.Controls 2.5 (Qt 5.12)) - implicitBackgroundHeight : real
(since QtQuick.Controls 2.5 (Qt 5.12)) - implicitBackgroundWidth : real
(since QtQuick.Controls 2.5 (Qt 5.12)) - leftInset : real
(since QtQuick.Controls 2.5 (Qt 5.12)) - rightInset : real
(since QtQuick.Controls 2.5 (Qt 5.12)) - topInset : real
(since QtQuick.Controls 2.5 (Qt 5.12))
Descripción detallada
El control «Label» amplía el control « Text » con estilos y herencia de « font ». Los colores y la fuente predeterminados dependen del estilo. El control «Label» también puede incluir un elemento visual de « background ».

Label {
text: "Label"
}Puedes utilizar las propiedades de « Text » para modificar el aspecto del texto según desees:
Label {
text: "Hello world"
font.pixelSize: 22
font.italic: true
}Véase también Personalización dela etiqueta.
Documentación de propiedades
background : Item
Esta propiedad contiene el elemento de fondo.
Nota: Si no se ha especificado ningún tamaño explícito para el elemento de fondo, este adoptará automáticamente el tamaño del control. En la mayoría de los casos, no es necesario especificar el ancho ni la altura de un elemento de fondo.
Véase también «Personalización deetiquetas».
bottomInset : real [since QtQuick.Controls 2.5 (Qt 5.12)]
Esta propiedad define el margen inferior del fondo.
Esta propiedad se introdujo en QtQuick.Controls 2.5 (Qt 5.12).
Véase también Control Layout y topInset.
implicitBackgroundHeight : real [read-only, since QtQuick.Controls 2.5 (Qt 5.12)]
Esta propiedad contiene la altura implícita del fondo.
El valor es igual a ` background ? background.implicitHeight : 0`.
Esta propiedad se introdujo en QtQuick.Controls 2.5 (Qt 5.12).
Véase también implicitBackgroundWidth.
implicitBackgroundWidth : real [read-only, since QtQuick.Controls 2.5 (Qt 5.12)]
Esta propiedad contiene el ancho implícito del fondo.
El valor es igual a « background ? background.implicitWidth : 0 ».
Esta propiedad se introdujo en QtQuick.Controls 2.5 (Qt 5.12).
Véase también implicitBackgroundHeight.
leftInset : real [since QtQuick.Controls 2.5 (Qt 5.12)]
Esta propiedad define el margen izquierdo del fondo.
Esta propiedad se introdujo en QtQuick.Controls 2.5 (Qt 5.12).
Véase también Control Layout y rightInset.
rightInset : real [since QtQuick.Controls 2.5 (Qt 5.12)]
Esta propiedad establece el margen derecho del fondo.
Esta propiedad se introdujo en QtQuick.Controls 2.5 (Qt 5.12).
Véase también Control Layout y leftInset.
topInset : real [since QtQuick.Controls 2.5 (Qt 5.12)]
Esta propiedad define el margen superior del fondo.
Esta propiedad se introdujo en QtQuick.Controls 2.5 (Qt 5.12).
Véase también Control Layout y bottomInset.
© 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.