Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    ListView scrolling automatically

    QML and Qt Quick
    2
    7
    1794
    Loading More Posts
    • 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.
    • J
      joanaguimas last edited by

      Hi, I have a ListView with a lot of items, and I want to know if it has a way to see the items without scrolling. Like, just appear one item at the time, until the end of the list always in the same space. I can do this with pathview, but the items are overlapping and I can't see them.

      Thanks.

      1 Reply Last reply Reply Quote 0
      • I
        Iktwo last edited by

        When you say scrolling automatically do you mean moving the position on the list without scrolling it with touch events or mouse? Are you asking for a circular list? that you can move to the end and it will start again? I believe you need pathview for this, what is the path that you have where the items overlap?

        J 1 Reply Last reply Reply Quote 0
        • J
          joanaguimas @Iktwo last edited by

          @Iktwo yes, this is what I want, it's basically like the example set shown on this page: http://doc.qt.io/qt-5/qml-qtquick-pathview.html
          but I have a lot of items and they are overlapping, and I can not change it ..

          1 Reply Last reply Reply Quote 0
          • I
            Iktwo last edited by

            Have you tried setting pathItemCount?

            J 1 Reply Last reply Reply Quote 0
            • J
              joanaguimas @Iktwo last edited by

              @Iktwo Yes I tried. But if I put pathItemCount: 3 , just appear the first 3 items of the list, and if I put 100, they are overlapping..

              1 Reply Last reply Reply Quote 0
              • I
                Iktwo last edited by

                And you want to see them all, correct? Could you share the Path that you are using?

                J 1 Reply Last reply Reply Quote 0
                • J
                  joanaguimas @Iktwo last edited by

                  @Iktwo Yes I want to see them all, but one by one..

                  I have this:

                                      height: 200
                                      width: parent.width
                                      color: "blue"
                                      anchors.top: parent.top
                                      border.color: "black"
                                      border.width: 1
                                      radius: 5
                                      clip: true
                  
                  
                  
                                      PathView {
                                              anchors.fill: parent
                                              model: latContent
                  
                                              pathItemCount: 3
                                              //currentIndex : 2
                                              delegate: Component {
                                                              Text {
                                                                    font.pointSize: 14
                                                                    text: modelData
                                                           }
                                                        }
                  
                  
                                                      path: Path {
                                                          startX: 120; startY: 100
                                                          PathQuad { x: 120; y: 25; controlX: 260; controlY: 75 }
                                                          PathQuad { x: 120; y: 100; controlX: -20; controlY: 75 }
                                                      }
                                                  }
                                              }
                  
                  latContent is my list from Bluetoothsocket, so basically my list could be 'infinite'.
                  1 Reply Last reply Reply Quote 0
                  • First post
                    Last post