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. QML Listview delegate recycling

QML Listview delegate recycling

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
3 Posts 3 Posters 1.7k 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.
  • DonCoderD Offline
    DonCoderD Offline
    DonCoder
    wrote on last edited by
    #1

    In QML Listview, i am creating contact list which has 1000 contacts.
    While scrolling through list view i observed many delegate items are getting created and and getting destroyed while moving to non visible area.

    This is a major performance impact on the application. while scrolling rapidly application responds very slowly. An suggestions please ...

    E 1 Reply Last reply
    0
    • ? Offline
      ? Offline
      A Former User
      wrote on last edited by
      #2

      Hi! Here is a list of general advice to improve delegate performance:

      • implement as much as possible in C++, including the model and the GUI logic
      • avoid JavaScript as much as possible
      • reduce the amount of QML to a minimum
      • use Loader for parallel delegate instantiation
      • for everything that is only needed after the user interacts with a delegate (clicks on it etc) use Loader to instantiate those parts only on demand
      1 Reply Last reply
      1
      • DonCoderD DonCoder

        In QML Listview, i am creating contact list which has 1000 contacts.
        While scrolling through list view i observed many delegate items are getting created and and getting destroyed while moving to non visible area.

        This is a major performance impact on the application. while scrolling rapidly application responds very slowly. An suggestions please ...

        E Offline
        E Offline
        Eeli K
        wrote on last edited by
        #3

        @DonCoder See also the documentation for 'cacheBuffer' property of ListView:

        Note: Setting this property is not a replacement for creating efficient delegates. It can improve the smoothness of scrolling behavior at the expense of additional memory usage. The fewer objects and bindings in a delegate, the faster a view can be scrolled. It is important to realize that setting a cacheBuffer will only postpone issues caused by slow-loading delegates, it is not a solution for this scenario.

        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