Results 1 to 3 of 3

Thread: Draw grid in QListView

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jun 2007
    Location
    India
    Posts
    1,042
    Thanks
    8
    Thanked 133 Times in 128 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: Draw grid in QListView

    opt.rect.height(), opt.rect.width(), opt.rect.height()
    will always return the same numbers.. u need opt.rect.x() opt.rect.y()

  2. #2
    Join Date
    Mar 2010
    Posts
    36
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Draw grid in QListView

    thanks!

    I used some functions of QRect:
    Qt Code:
    1. painter->drawLine(opt.rect.bottomLeft(), opt.rect.bottomRight());
    To copy to clipboard, switch view to plain text mode 
    Using Qt 4.7
    Developping on Win 7 and XP
    Using Qt Creator, Eclipse and Visual Studio
    Target Platforms Win, Linux and soon OS X

Similar Threads

  1. Replies: 0
    Last Post: 30th August 2010, 19:08
  2. Cant't draw custom grid
    By Tottish in forum Qwt
    Replies: 4
    Last Post: 1st May 2010, 09:55
  3. Replies: 5
    Last Post: 21st January 2010, 15:55
  4. How do draw a frame in QListView?
    By someralex in forum Qt Programming
    Replies: 24
    Last Post: 21st December 2006, 11:56

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.