38 lines
789 B
QML
38 lines
789 B
QML
|
|
import QtQuick
|
||
|
|
import QtQuick.Controls
|
||
|
|
import QtQuick.Layouts
|
||
|
|
|
||
|
|
Rectangle {
|
||
|
|
width: 554
|
||
|
|
height: 36
|
||
|
|
radius: 7
|
||
|
|
property var text: ""
|
||
|
|
property var value: ""
|
||
|
|
property var readonly: false
|
||
|
|
clip: true
|
||
|
|
border.width: 1
|
||
|
|
border.color: "#BFBFBF"
|
||
|
|
|
||
|
|
TextInput
|
||
|
|
{
|
||
|
|
id: tf
|
||
|
|
height: parent.height
|
||
|
|
anchors.left: parent.left
|
||
|
|
anchors.leftMargin: 25
|
||
|
|
anchors.right: parent.right
|
||
|
|
anchors.rightMargin: 25
|
||
|
|
color: "#262626"
|
||
|
|
font.pixelSize: 14
|
||
|
|
font.family: customFontLoader.name
|
||
|
|
font.weight: Font.Medium
|
||
|
|
verticalAlignment: TextInput.AlignVCenter
|
||
|
|
text: parent.text
|
||
|
|
enabled:!parent.readonly
|
||
|
|
onEditingFinished: {
|
||
|
|
parent.value = text;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
|