mirror of
https://github.com/Qsgs-Fans/FreeKill.git
synced 2024-11-16 03:32:34 +08:00
be03b04ef0
- 修复了虚拟牌点数相加的bug - 修复cleaner出错直接爆炸 - QML的代码将宽度控制到80以内
64 lines
1.2 KiB
QML
64 lines
1.2 KiB
QML
// SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
import QtQuick
|
|
import QtQuick.Controls
|
|
import QtQuick.Layouts
|
|
import Fk.RoomElement
|
|
|
|
Flickable {
|
|
id: root
|
|
anchors.fill: parent
|
|
property var extra_data: ({})
|
|
|
|
signal finish()
|
|
|
|
contentHeight: details.height
|
|
ScrollBar.vertical: ScrollBar {}
|
|
|
|
RowLayout {
|
|
id: details
|
|
width: parent.width - 40
|
|
x: 20
|
|
spacing: 20
|
|
|
|
CardItem {
|
|
id: cardPic
|
|
Layout.alignment: Qt.AlignTop
|
|
Layout.topMargin: 10
|
|
cid: 0
|
|
}
|
|
|
|
ColumnLayout {
|
|
Text {
|
|
id: screenName
|
|
Layout.fillWidth: true
|
|
font.pixelSize: 18
|
|
color: "#E4D5A0"
|
|
}
|
|
|
|
TextEdit {
|
|
id: skillDesc
|
|
|
|
Layout.fillWidth: true
|
|
font.pixelSize: 18
|
|
color: "#E4D5A0"
|
|
|
|
readOnly: true
|
|
selectByKeyboard: true
|
|
selectByMouse: false
|
|
wrapMode: TextEdit.WordWrap
|
|
textFormat: TextEdit.RichText
|
|
}
|
|
}
|
|
}
|
|
|
|
onExtra_dataChanged: {
|
|
const card = extra_data.card;
|
|
if (!card) return;
|
|
cardPic.setData(card.toData());
|
|
const name = card.virt_name ? card.virt_name : card.name;
|
|
screenName.text = luatr(name);
|
|
skillDesc.text = luatr(":" + name);
|
|
}
|
|
}
|