Results 1 to 3 of 3

Thread: disable highlighting of qtableview cells

  1. #1
    Join Date
    Jun 2015
    Location
    California, USA
    Posts
    61
    Thanks
    43
    Thanked 1 Time in 1 Post
    Qt products
    Qt5
    Platforms
    MacOS X Unix/X11

    Default disable highlighting of qtableview cells

    In LibreCAD the Layers list is represented by a QTableView.
    Each row is a layer, and it has columns / cells with icons for toggling visibility and locking the layer.
    The issue is that when you click+hold+drag on a visibility icon's cell that cell becomes highlighted,
    and the cell that has the layer's name becomes un-highlighted.

    It's not that people intentionally click+hold+drag,
    but that in the milliseconds before they release the mouse button,
    moving the mouse a few pixels is enough to highlight the cell.

    Is there anything that can be done?

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: disable highlighting of qtableview cells

    Does the underlying model include the Qt::ItemIsSelectable for these cells?
    If yes, maybe it shouldn't?

    Cheers,
    _

  3. The following user says thank you to anda_skoa for this useful post:

    ravas (25th May 2016)

  4. #3
    Join Date
    Jun 2015
    Location
    California, USA
    Posts
    61
    Thanks
    43
    Thanked 1 Time in 1 Post
    Qt products
    Qt5
    Platforms
    MacOS X Unix/X11

    Default Re: disable highlighting of qtableview cells

    Yes, thank you!
    I really appreciate the help on this forum;
    hopefully I can reciprocate eventually.

    https://github.com/LibreCAD/LibreCAD...078673a50877af

Similar Threads

  1. How do i change background of QTableView cells
    By .:saeed:. in forum Qt Programming
    Replies: 1
    Last Post: 9th February 2011, 15:42
  2. Can't edit my QTableView cells
    By MattPhillips in forum Newbie
    Replies: 4
    Last Post: 2nd February 2011, 14:49
  3. Understanding highlighting in a QTableView
    By scarleton in forum Qt Programming
    Replies: 7
    Last Post: 11th July 2010, 14:32
  4. Text in QTableView cells not visible
    By juliarg in forum Newbie
    Replies: 2
    Last Post: 22nd March 2007, 16:49
  5. Editable cells in QTableView
    By TheRonin in forum Qt Programming
    Replies: 1
    Last Post: 29th November 2006, 18:39

Tags for this Thread

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.