Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QTreeView Processing Strings to get QFileSystemModel-like Style ?

QTreeView Processing Strings to get QFileSystemModel-like Style ?

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 892 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.
  • E Offline
    E Offline
    exiled
    wrote on last edited by
    #1

    I have a list of strings that are almost like file paths ("some/folder/path/file.ext") and I need to process them so that it basically ends up behaving like it does for a QFileSystemModel. I'm not sure if I can use an exist model or would I have to create my own ?

    1 Reply Last reply
    0
    • S Offline
      S Offline
      ScottR
      wrote on last edited by
      #2

      I don't think that QTreeView will do it itself. However, you can create a tree QStandardItemModel "(example making a tree)":http://qt-project.org/doc/qt-5/qstandarditemmodel.html#details and pass that to a QTreeView.

      You would need to parse the strings yourself.

      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