Results 1 to 4 of 4

Thread: QTableView and checkboxes

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Feb 2008
    Location
    South Korea
    Posts
    14
    Thanks
    3
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows

    Default QTableView and checkboxes

    Hi all,

    I have a QTableView where I've created my own delegate to draw checkboxes for a column. I re-implemented paint() and use drawCheck(...) inside.

    I have two problems;

    1) The checkox is not immediately accessible when I click on a cell, I have to double-click the cell to activate the editor. What can I do to make the checkbox active immediately so the the user can just click once to toggle the value?

    2) The editor becomes left-justified in the cell (see attachment). I want it to be centered just like the paint() method draws them.


    Any advice would be appreciated.

    Thanks,
    Ingemar
    Attached Images Attached Images

Similar Threads

  1. Replies: 2
    Last Post: 23rd February 2008, 01:58
  2. QTableView with a checkbox
    By maxpower in forum Qt Programming
    Replies: 17
    Last Post: 18th February 2007, 09:45

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.