Warning, /rolisteam/rolisteam/src/libraries/qml_views/CustomItems/PersonEdit.qml is written in an unsupported language. File is not indexed.

0001 import QtQuick 2.15
0002 import QtQuick.Controls 2.15
0003 import QtQuick.Layouts 1.15
0004 import CustomItems 1.0
0005 import Profile 1.0
0006 
0007 GridLayout {
0008     id: _root
0009     columns: 3
0010     property alias imageData: _img.imageData
0011     property alias characterName: _nameField.text
0012     property alias color: _color.color
0013     property alias validInput: _nameField.validInput
0014     property alias isSquare: _img.isSquare
0015     signal clicked
0016     signal nameEdited(string name)
0017     signal colorEdited(color col)
0018 
0019     property alias line : _colorLine.data
0020 
0021    // implicitHeight: childrenRect.height//Math.max(_img.height,_nameField.height+_colorLine.implicitHeight)
0022     ImageSelector {
0023         id: _img
0024         Layout.rowSpan: 2
0025         Layout.preferredHeight: 80
0026         Layout.preferredWidth: 80
0027         onMouseClicked:  _root.clicked()
0028     }
0029     Label {
0030         text: qsTr("Name:")
0031     }
0032     RequiredTextField {
0033         id: _nameField
0034         Layout.fillWidth: true
0035         onTextEdited: _root.nameEdited(_nameField.text)
0036     }
0037     Label {
0038         text: qsTr("Color:")
0039     }
0040     RowLayout {
0041         id: _colorLine
0042         ColorPicker {
0043             id: _color
0044             Layout.preferredHeight: 30
0045             Layout.preferredWidth: 30
0046             onColorEdited: (col)=> _root.colorEdited(col)
0047         }
0048 
0049     }
0050 
0051 }