Nesta página

ToolSeparator QML Type

Separa um grupo de itens em uma barra de ferramentas dos itens adjacentes. Mais...

Import Statement: import QtQuick.Controls
Inherits:

Control

Propriedades

Descrição detalhada

O ToolSeparator é usado para distinguir visualmente entre grupos de itens em uma barra de ferramentas, separando-os com uma linha. Ele pode ser usado em barras de ferramentas horizontais ou verticais, definindo a propriedade ` orientation ` como ` Qt.Vertical ` ou ` Qt.Horizontal`, respectivamente.

Separador de ferramentas que divide os botões da barra de ferramentas

ToolBar {
    RowLayout {
        anchors.fill: parent

        ToolButton {
            text: qsTr("Action 1")
        }
        ToolButton {
            text: qsTr("Action 2")
        }

        ToolSeparator {}

        ToolButton {
            text: qsTr("Action 3")
        }
        ToolButton {
            text: qsTr("Action 4")
        }

        ToolSeparator {}

        ToolButton {
            text: qsTr("Action 5")
        }
        ToolButton {
            text: qsTr("Action 6")
        }

        Item {
            Layout.fillWidth: true
        }
    }
}

Veja também Personalização dos controlesToolSeparator e Separator.

Documentação da propriedade

horizontal : bool [read-only]

Essa propriedade é válida se orientation for igual a Qt.Horizontal.

É útil para personalizar o ToolSeparator.

Veja também orientation e vertical.

orientation : enumeration

Esta propriedade define a orientação do separador de ferramentas.

Valores possíveis:

ConstanteDescrição
Qt.HorizontalUm separador horizontal é usado em uma barra de ferramentas vertical.
Qt.VerticalUm separador vertical é usado em uma barra de ferramentas horizontal. (padrão)

vertical : bool [read-only]

Essa propriedade é válida se orientation for igual a Qt.Vertical.

É útil para personalizar o ToolSeparator.

Veja também orientation e horizontal.

© 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.