I got this piece of code:
import QtQuick 2.7
import QtQuick.Controls 1.5
ApplicationWindow {
visible: true
width: 640
height: 480
title: qsTr("spinbox trouble")
SpinBox{
anchors.centerIn: parent
value: 5
minimumValue: 1
maximumValue: 10
}
}
Everything is fine. Now I want to use SwipeView
. To use it I need use QtQuick.Controls 2.1
. But when I use version 2.1, I cannot find [minimum/maximum]Value in SpinBox.
Questions :
1. What is reason to drop this properties in QtQuick.Controls 2.1
?
2. Is there any way to use both SwipeView
and SpinBox
with [minimum/maximum]Value property?
查看Qt文档,我想说您可以使用from
和to
属性来代替minimumValue
和maximumValue
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.