Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. ListView issue in QML
QtWS25 Last Chance

ListView issue in QML

Scheduled Pinned Locked Moved QML and Qt Quick
3 Posts 3 Posters 1.4k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    Craig27
    wrote on last edited by
    #1

    I'm trying to design scrollable list of digits using snapMode in ListView, sort of spinning list control.
    The only issue am finding is the list doesn't get repeats on scrolling when the we scroll to end item

    How can i scroll the items while scrolling in a loop

    below is the code snippet of the implementation

    @import QtQuick 1.1

    Rectangle {
    id: mSpinner

        anchors.centerIn: parent
        width: 300
        height: width
        color: "gray"
    
        ListView {
            id: list
            anchors.fill: parent
    
            snapMode: ListView.SnapToItem
            model: 5
            delegate: Rectangle{
              width: list.width
              height: list.height
              color: "transparent"
    
              Text {
                  anchors.centerIn: parent
                  horizontalAlignment: Text.AlignHCenter
                  text: index
                  font.pixelSize: list.width
              }
            }
        }
    

    }@

    1 Reply Last reply
    0
    • T Offline
      T Offline
      tolszak
      wrote on last edited by
      #2

      I suppose that by repeating scrolling you mean element like PathView (Qt 4.8).

      1 Reply Last reply
      0
      • M Offline
        M Offline
        mivoligo
        wrote on last edited by
        #3

        I don't know if you still need the answer, but I came across this: http://qt-project.org/wiki/QML_Scrolling_Digits

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved