Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QTreeWidgetItem checkbox tick color changes with setForeground
Forum Updated to NodeBB v4.3 + New Features

QTreeWidgetItem checkbox tick color changes with setForeground

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 265 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N Offline
    N Offline
    nunojpg
    wrote on last edited by
    #1

    I am changing the background of QTreeWidgetItems with checkbox.

    It changes the label background only as expected (not the checkbox).

    When the background is too dark I need to set the label foreground to white.

    That changes also the checkbox tick to white. See the last line in the image below:

    Screenshot from 2020-05-17 16-38-03.png

    This is undesirable...and probably a bug?

    Can I workaround it?

    VRoninV 1 Reply Last reply
    0
    • N nunojpg

      I am changing the background of QTreeWidgetItems with checkbox.

      It changes the label background only as expected (not the checkbox).

      When the background is too dark I need to set the label foreground to white.

      That changes also the checkbox tick to white. See the last line in the image below:

      Screenshot from 2020-05-17 16-38-03.png

      This is undesirable...and probably a bug?

      Can I workaround it?

      VRoninV Offline
      VRoninV Offline
      VRonin
      wrote on last edited by
      #2

      @nunojpg said in QTreeWidgetItem checkbox tick color changes with setForeground:

      When the background is too dark I need to set the label foreground to white.

      Can you show us how you achieve this?

      "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
      ~Napoleon Bonaparte

      On a crusade to banish setIndexWidget() from the holy land of Qt

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved