mirror of
https://github.com/zhuzichu520/FluentUI.git
synced 2025-01-22 20:04:32 +08:00
update
This commit is contained in:
parent
f88b330f8e
commit
7a1776407f
@ -46,7 +46,6 @@ FluScrollablePage{
|
||||
}
|
||||
FluComboBox {
|
||||
editable: true
|
||||
font:FluTextStyle.BodyStrong
|
||||
model: ListModel {
|
||||
id: model_2
|
||||
ListElement { text: "Banana" }
|
||||
|
@ -47,7 +47,6 @@ FluScrollablePage{
|
||||
}
|
||||
FluComboBox {
|
||||
editable: true
|
||||
font:FluTextStyle.BodyStrong
|
||||
model: ListModel {
|
||||
id: model_2
|
||||
ListElement { text: "Banana" }
|
||||
|
@ -4,7 +4,7 @@ import QtQuick.Window 2.15
|
||||
import FluentUI 1.0
|
||||
import QtQuick.Templates 2.15 as T
|
||||
|
||||
ComboBox {
|
||||
T.ComboBox {
|
||||
id: control
|
||||
signal commit(string text)
|
||||
property bool disabled: false
|
||||
@ -72,6 +72,7 @@ ComboBox {
|
||||
Keys.onReturnPressed:(event)=> handleCommit(event)
|
||||
function handleCommit(event){
|
||||
control.commit(control.editText)
|
||||
accepted()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -4,28 +4,28 @@ import FluentUI 1.0
|
||||
|
||||
T.ItemDelegate {
|
||||
id: control
|
||||
|
||||
implicitWidth: Math.max(implicitBackgroundWidth + leftInset + rightInset,
|
||||
implicitContentWidth + leftPadding + rightPadding)
|
||||
implicitHeight: Math.max(implicitBackgroundHeight + topInset + bottomInset,
|
||||
implicitContentHeight + topPadding + bottomPadding,
|
||||
implicitIndicatorHeight + topPadding + bottomPadding)
|
||||
|
||||
padding: 12
|
||||
spacing: 8
|
||||
|
||||
icon.width: 24
|
||||
icon.height: 24
|
||||
padding: 0
|
||||
verticalPadding: 8
|
||||
horizontalPadding: 10
|
||||
icon.color: control.palette.text
|
||||
|
||||
contentItem: FluText {
|
||||
contentItem:FluText {
|
||||
text: control.text
|
||||
font: control.font
|
||||
color:{
|
||||
if(control.down){
|
||||
return FluTheme.dark ? FluColors.Grey80 : FluColors.Grey120
|
||||
}
|
||||
return FluTheme.dark ? FluColors.White : FluColors.Grey220
|
||||
}
|
||||
}
|
||||
|
||||
background: Rectangle {
|
||||
implicitWidth: 100
|
||||
implicitHeight: 40
|
||||
implicitHeight: 30
|
||||
color:{
|
||||
if(FluTheme.dark){
|
||||
return Qt.rgba(1,1,1,0.05)
|
||||
|
@ -4,7 +4,7 @@ import QtQuick.Controls.Basic
|
||||
import FluentUI
|
||||
import QtQuick.Templates as T
|
||||
|
||||
ComboBox {
|
||||
T.ComboBox {
|
||||
id: control
|
||||
signal commit(string text)
|
||||
property bool disabled: false
|
||||
@ -72,6 +72,7 @@ ComboBox {
|
||||
Keys.onReturnPressed:(event)=> handleCommit(event)
|
||||
function handleCommit(event){
|
||||
control.commit(control.editText)
|
||||
accepted()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -5,28 +5,28 @@ import FluentUI
|
||||
|
||||
T.ItemDelegate {
|
||||
id: control
|
||||
|
||||
implicitWidth: Math.max(implicitBackgroundWidth + leftInset + rightInset,
|
||||
implicitContentWidth + leftPadding + rightPadding)
|
||||
implicitHeight: Math.max(implicitBackgroundHeight + topInset + bottomInset,
|
||||
implicitContentHeight + topPadding + bottomPadding,
|
||||
implicitIndicatorHeight + topPadding + bottomPadding)
|
||||
|
||||
padding: 12
|
||||
spacing: 8
|
||||
|
||||
icon.width: 24
|
||||
icon.height: 24
|
||||
padding: 0
|
||||
verticalPadding: 8
|
||||
horizontalPadding: 10
|
||||
icon.color: control.palette.text
|
||||
|
||||
contentItem: FluText {
|
||||
contentItem:FluText {
|
||||
text: control.text
|
||||
font: control.font
|
||||
color:{
|
||||
if(control.down){
|
||||
return FluTheme.dark ? FluColors.Grey80 : FluColors.Grey120
|
||||
}
|
||||
return FluTheme.dark ? FluColors.White : FluColors.Grey220
|
||||
}
|
||||
}
|
||||
|
||||
background: Rectangle {
|
||||
implicitWidth: 100
|
||||
implicitHeight: 40
|
||||
implicitHeight: 30
|
||||
color:{
|
||||
if(FluTheme.dark){
|
||||
return Qt.rgba(1,1,1,0.05)
|
||||
|
Loading…
Reference in New Issue
Block a user