Details
-
Suggestion
-
Resolution: Done
-
P2: Important
-
None
-
5.7.0 Beta
-
None
Description
Arbitrary model item count, control geometry, and configurable fonts make the concept of "visible item count" a bit confusing and problematic. I'm always unsure what to specify, and seeing the property immediately raises questions like:
- What if the items don't fit? Do they overlap?
- Why can't Tumbler calculate a suitable value for me?
- What if the model item count is less than the visible item count?
Therefore, I'd like to propose removing/deprecating the visibleItemCount property. Tumbler should calculate something that fits the available geometry. Furthermore, there probably should be a bool wrap -property that is by default:
- false when the model item count is less than the calculated ideal visible item count
- true when the model item count is greater or equal than the calculated ideal visible item count
This implies that we either implement non-wrapping PathView, or add an internal helper type that automatically chooses between PathView and ListView. This way Hours+Minutes+AM/PM type of tumblers would work nicely out of the box: http://blog.ittybittyapps.com/images/posts/lifting-the-lid-on-ios-7s-uipicker/UIDatePickerComparison.jpg
Attachments
Issue Links
- resulted from
-
QTBUG-53519 API review findings to be fixed before the release
-
- Closed
-
For Gerrit Dashboard: QTBUG-53587 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
160627,43 | Tumbler: add wrap property | dev | qt/qtquickcontrols2 | Status: MERGED | -2 | 0 |
162805,16 | Tumbler: make wrap property depend on count by default | dev | qt/qtquickcontrols2 | Status: MERGED | -2 | 0 |