Warning, /frameworks/kirigami/src/controls/FlexColumn.qml is written in an unsupported language. File is not indexed.
0001 /* 0002 * SPDX-FileCopyrightText: 2020 Carson Black <uhhadd@gmail.com> 0003 * 0004 * SPDX-License-Identifier: LGPL-2.0-or-later 0005 */ 0006 0007 import QtQuick 2.12 0008 import QtQuick.Layouts 1.12 0009 import org.kde.kirigami 2.13 as Kirigami 0010 0011 //TODO KF6: how much is this used? can be removed? 0012 /** 0013 * @brief FlexColumn is a column that grows in width to a fixed cap. 0014 * @warning This might be removed in KF6 due to not being used. 0015 * @inherit QtQuick.Layouts.ColumnLayout 0016 */ 0017 ColumnLayout { 0018 id: __outer 0019 0020 default property alias columnChildren: __inner.children 0021 0022 /** 0023 * @brief This property holds the column's offset from the cross axis. 0024 * 0025 * Note that padding is applied on both sides 0026 * when the column is aligned to a centered cross axis. 0027 * 0028 * default: ``Kirigami.Units.largeSpacing`` 0029 */ 0030 property real padding: Kirigami.Units.largeSpacing 0031 0032 /** 0033 * @brief This property holds maximum column width. 0034 * 0035 * default: ``Kirigami.Units.gridUnit * 50`` 0036 */ 0037 property real maximumWidth: Kirigami.Units.gridUnit * 50 0038 0039 /** 0040 * @brief This property sets column's alignment when it hits its maximum width. 0041 * 0042 * default: ``Qt.AlignHCenter | Qt.AlignTop`` 0043 * 0044 * @property Qt::Alignment alignment 0045 */ 0046 property int alignment: Qt.AlignHCenter | Qt.AlignTop 0047 0048 Layout.fillWidth: true 0049 Layout.fillHeight: true 0050 0051 enum CrossAxis { 0052 Left, 0053 Center, 0054 Right 0055 } 0056 0057 ColumnLayout { 0058 id: __inner 0059 spacing: __outer.spacing 0060 Layout.maximumWidth: __outer.maximumWidth 0061 Layout.leftMargin: __outer.alignment & Qt.AlignLeft || __outer.alignment & Qt.AlignHCenter ? __outer.padding : 0 0062 Layout.rightMargin: __outer.alignment & Qt.AlignRight || __outer.alignment & Qt.AlignHCenter ? __outer.padding : 0 0063 Layout.alignment: __outer.alignment 0064 } 0065 }