Warning, /frameworks/kirigami/src/controls/private/DefaultPageTitleDelegate.qml is written in an unsupported language. File is not indexed.

0001 /*
0002  *  SPDX-FileCopyrightText: 2023 ivan tkachenko <me@ratijas.tk>
0003  *
0004  *  SPDX-License-Identifier: LGPL-2.0-or-later
0005  */
0006 
0007 import QtQuick
0008 import QtQuick.Layouts
0009 import org.kde.kirigami as Kirigami
0010 
0011 /**
0012  * This component is used as a default representation for a page title within
0013  * page's header/toolbar. It is just a Heading item with shrinking + eliding
0014  * behavior.
0015  *
0016  * \private
0017  */
0018 Item {
0019     property alias text: heading.text
0020 
0021     Layout.fillWidth: true
0022     Layout.minimumWidth: 0
0023     Layout.maximumWidth: implicitWidth
0024 
0025     implicitWidth: Math.ceil(heading.implicitWidth)
0026     implicitHeight: Math.ceil(heading.implicitHeight)
0027 
0028     Kirigami.Heading {
0029         id: heading
0030 
0031         anchors.fill: parent
0032         maximumLineCount: 1
0033         elide: Text.ElideRight
0034         textFormat: Text.PlainText
0035     }
0036 }