Results 1 to 2 of 2

Thread: Exist a 'fullpath' property for an QtreeWidgetitem ???

  1. #1
    Join Date
    Sep 2010
    Posts
    654
    Qt products
    Qt4
    Platforms
    Windows
    Thanks
    56
    Thanked 1 Time in 1 Post

    Default Exist a 'fullpath' property for an QtreeWidgetitem ???

    I dont find a fullpath property for an item selected on a QTreeWidget.
    Any help ? It does not exist ?
    Have I to get the parents to build the path myself ?

  2. #2
    Join Date
    Nov 2010
    Location
    iran/isfahan
    Posts
    13
    Qt products
    Qt4
    Platforms
    Windows Symbian S60
    Thanks
    3
    Thanked 3 Times in 3 Posts

    Default Re: Exist a 'fullpath' property for an QtreeWidgetitem ???

    No. There is no method. but it's better to write your own subclass of QTreeWidgetItemand use it instead of writing related code more than one time in your code.

    QList<QTreeWidgetItem*> myTreeWidgetItem:: pathToRoot(){
    QTreeWidgetItem* current = this;
    QList<QTreeWidgetItem*> ret;
    while(current)
    {
    ret.push_back(current);
    current = current.parent();
    }
    return ret;
    }

Similar Threads

  1. IS this allright + how to see if it exist
    By Nazgul in forum Newbie
    Replies: 15
    Last Post: 19th March 2011, 00:01
  2. rcc: File does not exist
    By lyuts in forum Qt Programming
    Replies: 2
    Last Post: 18th October 2010, 09:26
  3. Replies: 5
    Last Post: 23rd September 2010, 14:58
  4. Application does not exist when I debug
    By learning_qt in forum Qt for Embedded and Mobile
    Replies: 1
    Last Post: 23rd September 2008, 17:26
  5. XML Database: eXist
    By Lykurg in forum Qt Programming
    Replies: 3
    Last Post: 7th March 2007, 00:22

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.