Results 1 to 20 of 22

Thread: custom painting in QListWidget

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #6
    Join Date
    Mar 2007
    Posts
    13
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: custom painting in QListWidget

    thanks.
    i simply could not see that.
    but now i seem to have another problem.

    Qt Code:
    1. void MyDelegate::paint ( ..)
    2. {
    3. QStyleOptionViewItem newOption( option );
    4. newOption.rect.translate(QPoint(40,40));
    5.  
    6. QItemDelegate::paint(painter, newOption, index);
    7. }
    To copy to clipboard, switch view to plain text mode 

    when i select items the widget doesnt display the items correctly.
    for example, if i select the 2nd item, the horizontal lower half of the first item is erased but the selected item is displayed ok.
    but after i play around with selection the whole thing becomes a bigger mess.

    what do you think ?
    is delegate an option for modifying ListWidget items position ?
    is this possible ?

    thanks
    Last edited by wysota; 29th March 2007 at 06:25. Reason: missing [code] tags

Similar Threads

  1. custom widgets painting image formats
    By TheKedge in forum Qt Programming
    Replies: 1
    Last Post: 12th March 2007, 10:33
  2. Replies: 1
    Last Post: 5th March 2007, 20:50
  3. Replies: 13
    Last Post: 15th December 2006, 11:52
  4. keypress while editing an item in QListWidget
    By Beluvius in forum Qt Programming
    Replies: 3
    Last Post: 4th April 2006, 09:56
  5. Replies: 16
    Last Post: 7th March 2006, 15:57

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.