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. How to let the column scrollable?
Forum Updated to NodeBB v4.3 + New Features

How to let the column scrollable?

Scheduled Pinned Locked Moved Solved QML and Qt Quick
5 Posts 3 Posters 1.1k Views 2 Watching
  • 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.
  • M Offline
    M Offline
    Mr Pang
    wrote on 28 Oct 2016, 07:25 last edited by
    #1

    My code is like this:

    Column {
        Repeater {
            model: 1000
            CheckBox {
                 text: "index " + index
            }
        }
    }
    
    1 Reply Last reply
    0
    • P Offline
      P Offline
      p3c0
      Moderators
      wrote on 28 Oct 2016, 07:36 last edited by p3c0
      #2

      @Mr-Pang Add it inside ScrollView. If you want it to be smooth and animated use Flickable inside it too.

      And then if you feel that there should be some built-in type for this then use ListView

      157

      M 1 Reply Last reply 28 Oct 2016, 08:25
      2
      • P p3c0
        28 Oct 2016, 07:36

        @Mr-Pang Add it inside ScrollView. If you want it to be smooth and animated use Flickable inside it too.

        And then if you feel that there should be some built-in type for this then use ListView

        M Offline
        M Offline
        Mr Pang
        wrote on 28 Oct 2016, 08:25 last edited by
        #3

        @p3c0
        But I don't know how to use Repeater inside ListView

        J 1 Reply Last reply 28 Oct 2016, 08:30
        0
        • M Mr Pang
          28 Oct 2016, 08:25

          @p3c0
          But I don't know how to use Repeater inside ListView

          J Offline
          J Offline
          Julien B
          wrote on 28 Oct 2016, 08:30 last edited by Julien B
          #4

          Hello @Mr-Pang,

          You don't need to use a repeater, but model and delegate.

          Have a look in the example provided here Move QML ListView via buttons

          M 1 Reply Last reply 28 Oct 2016, 09:20
          1
          • J Julien B
            28 Oct 2016, 08:30

            Hello @Mr-Pang,

            You don't need to use a repeater, but model and delegate.

            Have a look in the example provided here Move QML ListView via buttons

            M Offline
            M Offline
            Mr Pang
            wrote on 28 Oct 2016, 09:20 last edited by
            #5

            @Julien-B
            I see. model can be given a number directly.

            1 Reply Last reply
            0

            4/5

            28 Oct 2016, 08:30

            • Login

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