Download reference_qml/FunctionPanel/common/misc/CategoryButtonView.qml from Visecall/capcut-retouch-backup: direct link, hf CLI and curl.
- Browser
- Download file 2.02 kB
-
https://huggingface.co/Visecall/capcut-retouch-backup/resolve/main/reference_qml/FunctionPanel/common/misc/CategoryButtonView.qml
- Command line
-
hf download hf://Visecall/capcut-retouch-backup/reference_qml/FunctionPanel/common/misc/CategoryButtonView.qml
-
curl -L -o CategoryButtonView.qml https://huggingface.co/Visecall/capcut-retouch-backup/resolve/main/reference_qml/FunctionPanel/common/misc/CategoryButtonView.qml
2.02 kB
| import GeneralBiz | |
| import FusionUI | |
| import FunctionPanel | |
| import Purchase 1.0 | |
| import Qt5Compat.GraphicalEffects | |
| import QtQuick | |
| import QtQuick.Controls | |
| import QtQuick.Layouts | |
| import VECreator | |
| Item { | |
| id: root | |
| width: itemBackground.width | |
| height: itemBackground.height | |
| opacity: enabled ? 1 : 0.4 | |
| enabled: true | |
| property string title: "" | |
| property var contextId | |
| property bool selected: false | |
| property color fontColorActive: LVColor.White0_Text_Primary | |
| property color fontColorNormal: LVColor.Grey5_Text_Tertiary | |
| property color backgroundColorActive: LVColor.Fill_Button_Level3 | |
| property color backgroundColorNormal: LVColor.Fill_Button_Level2 | |
| property color backgroundColorHover: LVColor.Fill_Button_Level3 | |
| signal click(var contextId) | |
| Rectangle{ | |
| id: itemBackground | |
| width: text.contentWidth + 30 | |
| height: 24 | |
| color: backgroundColorNormal | |
| radius: 12 | |
| } | |
| Text{ | |
| id: text | |
| anchors.horizontalCenter: itemBackground.horizontalCenter | |
| anchors.verticalCenter: itemBackground.verticalCenter | |
| text: title | |
| font: LVFont.ButtonSemibold11 | |
| color: fontColorNormal | |
| } | |
| onSelectedChanged: { | |
| itemBackground.color = selected ? backgroundColorActive : backgroundColorNormal; | |
| text.color = selected ? fontColorActive : fontColorNormal | |
| } | |
| MouseArea{ | |
| id: mouseArea | |
| anchors.fill: parent | |
| cursorShape: Qt.PointingHandCursor | |
| hoverEnabled: root.enabled | |
| onEntered: { | |
| if(!selected){ | |
| text.color = fontColorActive | |
| itemBackground.color = backgroundColorHover | |
| } | |
| } | |
| onExited: { | |
| if(!selected){ | |
| text.color = fontColorNormal | |
| itemBackground.color = backgroundColorNormal | |
| } | |
| } | |
| onPressed: { | |
| root.click(contextId) | |
| } | |
| } | |
| } | |