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. Detecting system tray background color
QtWS25 Last Chance

Detecting system tray background color

Scheduled Pinned Locked Moved Solved General and Desktop
qtwidgetstrayqsystemtrayiconstylingcolors
4 Posts 2 Posters 265 Views
  • 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.
  • W Offline
    W Offline
    Wintermute
    wrote on 12 Dec 2024, 19:44 last edited by
    #1

    Hello,

    I'm trying to implement monochrome tray icons for my Qt app, and to make it work I need to choose a correct icon depending on the tray color scheme. I can't rely on the system's light / dark theme, because it doesn't necessarily reflect the color of the tray. For example, the tray is always dark on macOS regardless of the theme, while on KDE Breeze its color follows the theme by default.

    Is there a good way of choosing monochrome icons color? Will appreciate your ideas, because I don't have any.

    / Constantine

    P 1 Reply Last reply 12 Dec 2024, 23:43
    0
    • W Wintermute
      12 Dec 2024, 19:44

      Hello,

      I'm trying to implement monochrome tray icons for my Qt app, and to make it work I need to choose a correct icon depending on the tray color scheme. I can't rely on the system's light / dark theme, because it doesn't necessarily reflect the color of the tray. For example, the tray is always dark on macOS regardless of the theme, while on KDE Breeze its color follows the theme by default.

      Is there a good way of choosing monochrome icons color? Will appreciate your ideas, because I don't have any.

      / Constantine

      P Online
      P Online
      Pl45m4
      wrote on 12 Dec 2024, 23:43 last edited by
      #2

      @Wintermute

      Hi,

      I don't think you can do this using Qt only... and probably there is no platform independent way to do this.


      If debugging is the process of removing software bugs, then programming must be the process of putting them in.

      ~E. W. Dijkstra

      1 Reply Last reply
      0
      • W Offline
        W Offline
        Wintermute
        wrote on 6 Jan 2025, 11:59 last edited by
        #3

        Just to follow up on this -- at the end of the day I left the tray color scheme selection to the user:
        Configurable tray
        (this is Flowkeeper, fwiw)

        / Constantine

        P 1 Reply Last reply 6 Jan 2025, 13:13
        1
        • W Wintermute has marked this topic as solved on 6 Jan 2025, 12:00
        • W Wintermute
          6 Jan 2025, 11:59

          Just to follow up on this -- at the end of the day I left the tray color scheme selection to the user:
          Configurable tray
          (this is Flowkeeper, fwiw)

          / Constantine

          P Online
          P Online
          Pl45m4
          wrote on 6 Jan 2025, 13:13 last edited by
          #4

          @Wintermute said in Detecting system tray background color:

          (this is Flowkeeper, fwiw)

          This is great :)
          I could have used this during my studies, as most time/task planners and ToDo tools are crap :D


          If debugging is the process of removing software bugs, then programming must be the process of putting them in.

          ~E. W. Dijkstra

          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