mart created this revision. mart added reviewers: Plasma, Kirigami. Restricted Application added projects: Plasma, Kirigami. Restricted Application added a subscriber: plasma-devel.
REVISION SUMMARY Add a new component called FormLayout, which aims to behave similar to Qwidget's QFormLayout: 2 columns with labels aligned accordingly to the HIG when the available space is too small, collapse to one column only, intended especially for mobile. intended usage is based on the FormData attached property: FormLayout { TextField { FormData.label: "Label:" } //separed by a line, no titles Kirigami.Separator { Kirigami.FormData.isSection: true } TextField { FormData.label: "Label2:" } //separed by a line, and a title Kirigami.Separator { Kirigami.FormData.isSection: true Kirigami.FormData.label: "Section title" } } TEST PLAN the gallery has a FormLayout page used to test it REPOSITORY R169 Kirigami BRANCH mart/formlayout REVISION DETAIL https://phabricator.kde.org/D8641 AFFECTED FILES examples/galleryapp/resources.qrc examples/gallerydata/contents/ui/MainPage.qml examples/gallerydata/contents/ui/gallery/FormLayoutGallery.qml examples/gallerydata/contents/ui/gallery/TextFieldGallery.qml kirigami.qrc src/CMakeLists.txt src/controls/FormLayout.qml src/formlayoutattached.cpp src/formlayoutattached.h src/kirigamiplugin.cpp To: mart, #plasma, #kirigami Cc: plasma-devel, ZrenBot, progwolff, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, davidedmundson, mart, hein