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. Multiple declarativeviews
Forum Updated to NodeBB v4.3 + New Features

Multiple declarativeviews

Scheduled Pinned Locked Moved QML and Qt Quick
2 Posts 2 Posters 2.0k Views 1 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.
  • I Offline
    I Offline
    interf3ctor
    wrote on last edited by
    #1

    Hi,

    i'm (at the moment) using a GridView for displaying and arranging my abstractitemmodel-subclass.
    The GridViews delegate then is used to display PathViews as items of this GridView. This just works as intended.
    As I proceed now it would be nice to replace the GridView and place it's Items on a Circle. I thought about using another PathView for that purpose.
    The UI should then work like this: On startup there should be like 5 items (depending on the underlying structure) placed on a circle in the center of the application. Clicking one of these items should then display the children of the clicked item (on a nice circle again), moving the rest of the items to a corner on the screen but still having them displayed somewhere. Just changing the rootitem of my model would not help i guess.

    My Idea now was to put every circle in its own declarativeview, managing and placing them in c++ and not qml anymore.
    My Question now is: Is there a nicer way to place my items in qml without having multiple declarativeviews or (if it has to be that way) is there a quick way to create these views from inside qml like in the corresponding delegate or something like that?

    Looking forward to any help!

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mbrasser
      wrote on last edited by
      #2

      Have you seen the photoviewer demo (in demos/declarative/photoviewer)? It uses the following techniques, which should be relevant to what you are trying to accomplish:

      • multiple layers of Views within delegates
      • packages, which allow smooth transitions of items from one view to another

      For example, you might have an empty PathView of a single point sitting in the corner, which gets filled with the contents of the original circle PathView when transitioning to the next circle PathView. Packages can sometimes be hard to get started with, so I'd suggest also looking at the simple example in examples/declarative/modelviews/package.

      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