Results 1 to 5 of 5

Thread: Problem with tree widget

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Feb 2011
    Posts
    29
    Qt products
    Qt3 Qt4 Qt/Embedded Qt Jambi
    Platforms
    Unix/X11 Windows

    Default Problem with tree widget

    Hi friends

    I have currently take tree widget in QT designer form. Now i have add two item into it.
    I have write below sentence into style sheet. it changes back ground image.


    border-image:url(:/BG-Main.png);

    Now when i add items into it, it changes item color to white. and rest of the widget has back ground image. But item part lost image part and shows white back ground.

    I am not able to get what could be the problem Please let me know in this matter.

  2. #2
    Join Date
    Mar 2011
    Posts
    13
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Problem with tree widget

    if you don't set your items' bg color (or image), they must be transparent. With only that row in style sheet (border-image:url(:/BG-Main.png) even the tooltips take the same background. Just check out your code to be sure you're not setting any background in your items

  3. #3
    Join Date
    Feb 2011
    Posts
    29
    Qt products
    Qt3 Qt4 Qt/Embedded Qt Jambi
    Platforms
    Unix/X11 Windows

    Default Re: Problem with tree widget

    thanks for your reply...
    but can you tell me how to make tree widget item transparent... I don't know to do it...
    please give me some source code to make it transparent....

  4. #4
    Join Date
    Feb 2011
    Posts
    29
    Qt products
    Qt3 Qt4 Qt/Embedded Qt Jambi
    Platforms
    Unix/X11 Windows

    Default Re: Problem with tree widget

    helloooo is any body there to reply me for my problem.......
    i have already mention problem regarding tree widget.... I am really stuck with problem....
    I have create one tree widget... in designer form. I have add three item into it.... Now i change pallate color of tree widget...
    Now when i change back ground transparent of tree widget it works fine. but item shows in white colour only... I have change item colour also but that also not works...
    the other thing is when i click on item it shows highlight colour as marun colour. I don't want that selection colour also... How can i remove it...
    Please let me know solution plzzzzzz
    waiting for your reply guysssssssssss.

    thanks in advance...........

  5. #5
    Join Date
    Mar 2011
    Posts
    13
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Problem with tree widget

    When I read your first post I tried it in one of my projects. I did everything exactly as you did and here's how it worked: the tree widget had the background I gave it in design view, all the items I added by code were transparent until I start to edit them. But When I finish editing, they turn transparent again. I also have tool-tips there with no text, and they have the same bg as well.
    Check out this example. I'm sure you can find all you want there.

Similar Threads

  1. tree widget like designer's widget tree
    By nroberts in forum Newbie
    Replies: 1
    Last Post: 20th November 2010, 00:06
  2. Tree Widget
    By bismitapadhy in forum Qt Programming
    Replies: 1
    Last Post: 9th June 2009, 07:31
  3. Qt Tree Widget Question
    By alavtec in forum Qt Programming
    Replies: 2
    Last Post: 16th July 2008, 16:21
  4. Tree widget sorting
    By ganeshshenoy in forum Qt Programming
    Replies: 3
    Last Post: 11th February 2008, 13:06
  5. Drag from tree widget
    By EricF in forum Qt Programming
    Replies: 9
    Last Post: 17th December 2007, 23:09

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.