This commit is contained in:
朱子楚\zhuzi 2024-03-19 18:06:58 +08:00
parent 89c183afd5
commit ea8f25ff73
7 changed files with 55 additions and 31 deletions

View File

@ -1982,17 +1982,17 @@ My only desire is to be permitted to drive out the traitors and restore the Han.
<translation type="unfinished"></translation>
</message>
<message>
<location filename="qml/page/T_TableView.qml" line="512"/>
<location filename="qml/page/T_TableView.qml" line="513"/>
<source>Options</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="qml/page/T_TableView.qml" line="531"/>
<location filename="qml/page/T_TableView.qml" line="532"/>
<source>&lt;Previous</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="qml/page/T_TableView.qml" line="532"/>
<location filename="qml/page/T_TableView.qml" line="533"/>
<source>Next&gt;</source>
<translation type="unfinished"></translation>
</message>

View File

@ -2052,17 +2052,17 @@ My only desire is to be permitted to drive out the traitors and restore the Han.
<translation type="unfinished"></translation>
</message>
<message>
<location filename="qml/page/T_TableView.qml" line="512"/>
<location filename="qml/page/T_TableView.qml" line="513"/>
<source>Options</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="qml/page/T_TableView.qml" line="531"/>
<location filename="qml/page/T_TableView.qml" line="532"/>
<source>&lt;Previous</source>
<translation type="unfinished">&lt;</translation>
</message>
<message>
<location filename="qml/page/T_TableView.qml" line="532"/>
<location filename="qml/page/T_TableView.qml" line="533"/>
<source>Next&gt;</source>
<translation type="unfinished">&gt;</translation>
</message>

View File

@ -506,7 +506,8 @@ FluContentPage{
dataIndex: 'longstring',
width:200,
minimumWidth:100,
maximumWidth:300
maximumWidth:300,
editMultiline: true
},
{
title: qsTr("Options"),

View File

@ -97,27 +97,23 @@ Rectangle {
id:com_edit_multiline
Item{
anchors.fill: parent
ScrollView{
Flickable{
id:item_scroll
clip: true
anchors.fill: parent
ScrollBar.vertical: FluScrollBar{
parent: item_scroll
x: item_scroll.mirrored ? 0 : item_scroll.width - width
y: item_scroll.topPadding
height: item_scroll.availableHeight
active: item_scroll.ScrollBar.horizontal.active
}
FluMultilineTextBox {
ScrollBar.vertical: multiline_text_srcoll_bar
boundsBehavior: Flickable.StopAtBounds
TextArea.flickable: FluMultilineTextBox {
id:text_box
text: display
text: String(display)
readOnly: true === d.columns_data[column].readOnly
verticalAlignment: TextInput.AlignVCenter
isCtrlEnterForNewline: true
Component.onCompleted: {
forceActiveFocus()
selectAll()
}
rightPadding: 24
rightPadding: 34
onCommit: {
if(!readOnly){
editTextChaged(text_box.text)
@ -131,6 +127,9 @@ Rectangle {
iconSize: 10
width: 20
height: 20
padding: 0
verticalPadding: 0
horizontalPadding: 0
visible: {
if(text_box.readOnly)
return false
@ -139,12 +138,23 @@ Rectangle {
anchors{
verticalCenter: parent.verticalCenter
right: parent.right
rightMargin: 5
rightMargin: 15
}
onClicked:{
text_box.text = ""
}
}
FluScrollBar{
id:multiline_text_srcoll_bar
anchors{
right: parent.right
rightMargin: 5
top: parent.top
bottom: parent.bottom
topMargin: 3
bottomMargin: 3
}
}
}
}
Component{

View File

@ -27,6 +27,7 @@ FluWindow {
function showDialog(){
var x = transientParent.x + (transientParent.width - width)/2
var y = transientParent.y + (transientParent.height - height)/2
control.stayTop = Qt.binding(function(){return transientParent.stayTop})
setGeometry(x,y,width,height)
visible = true
}

View File

@ -98,27 +98,23 @@ Rectangle {
id:com_edit_multiline
Item{
anchors.fill: parent
ScrollView{
Flickable{
id:item_scroll
clip: true
anchors.fill: parent
ScrollBar.vertical: FluScrollBar{
parent: item_scroll
x: item_scroll.mirrored ? 0 : item_scroll.width - width
y: item_scroll.topPadding
height: item_scroll.availableHeight
active: item_scroll.ScrollBar.horizontal.active
}
FluMultilineTextBox {
ScrollBar.vertical: multiline_text_srcoll_bar
boundsBehavior: Flickable.StopAtBounds
TextArea.flickable: FluMultilineTextBox {
id:text_box
text: display
text: String(display)
readOnly: true === d.columns_data[column].readOnly
verticalAlignment: TextInput.AlignVCenter
isCtrlEnterForNewline: true
Component.onCompleted: {
forceActiveFocus()
selectAll()
}
rightPadding: 24
rightPadding: 34
onCommit: {
if(!readOnly){
editTextChaged(text_box.text)
@ -132,6 +128,9 @@ Rectangle {
iconSize: 10
width: 20
height: 20
padding: 0
verticalPadding: 0
horizontalPadding: 0
visible: {
if(text_box.readOnly)
return false
@ -140,12 +139,23 @@ Rectangle {
anchors{
verticalCenter: parent.verticalCenter
right: parent.right
rightMargin: 5
rightMargin: 15
}
onClicked:{
text_box.text = ""
}
}
FluScrollBar{
id:multiline_text_srcoll_bar
anchors{
right: parent.right
rightMargin: 5
top: parent.top
bottom: parent.bottom
topMargin: 3
bottomMargin: 3
}
}
}
}
Component{

View File

@ -10,6 +10,7 @@ FluWindow {
autoVisible: false
autoCenter: false
autoDestory: true
stayTop: true
fixSize: true
Loader{
anchors.fill: parent
@ -27,6 +28,7 @@ FluWindow {
function showDialog(){
var x = transientParent.x + (transientParent.width - width)/2
var y = transientParent.y + (transientParent.height - height)/2
control.stayTop = Qt.binding(function(){return transientParent.stayTop})
setGeometry(x,y,width,height)
visible = true
}