Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need way to switch between Dark and Light Mode regardless of System Mode #21421

Open
ObedPM opened this issue Sep 30, 2024 · 24 comments
Open

Need way to switch between Dark and Light Mode regardless of System Mode #21421

ObedPM opened this issue Sep 30, 2024 · 24 comments
Labels
GUI GUI-related issues/changes has workaround Look and feel Affect UI "Look and feel" only without changing the logic

Comments

@ObedPM
Copy link

ObedPM commented Sep 30, 2024

qBittorrent & operating system versions

qBittorrent: 5.0.0 x64
Operating system: Windows 10 Pro

What is the problem?

How can i change the dark theme? Is set up by default!

Steps to reproduce

No response

Additional context

No response

Log(s) & preferences file(s)

No response

@vivadavid
Copy link

Hi,

I have the same problem. I've just updated to version 5.0.0 and, out of the blue, dark mode is enabled by default and I can't find a way to switch back to light mode.

My Windows 11 has always been in dark mode, but, generally speaking, I prefer to have my programmes in light mode.

Is there a way to tell QbitTorrent 5.0.0 that, despite having dark mode in Windows 11, I prefer the programme in light mode?

Thanks!

@Pentaphon
Copy link

@ObedPM you should change the title of this issue to something like "Need way to switch between Dark and Light Mode regardless of System Mode".

@qBittUser
Copy link

@ObedPM

Is set up by default!

Yes, that's not a bug, qBittorrent v5+ changes theme based on your OS settings. It was made so to resolve Windows qBit users old feature request to have qBittorrent automatically support native Windows theme.

How can I change the dark theme?

  1. Open qBittorrent > Tools > Options
  2. Choose if you want to use a custom theme file or select Customizing UI Theme...

List of custom UI theme files are here:
https://github.com/qbittorrent/qBittorrent/wiki/List-of-known-qBittorrent-themes

If you dislike using custom UI theme files to switch between Light or Dark, then change your OS settings and qBittorrent v5+ will automatically switch to be similar to native system theme.

To customize Windows 10 & 11 theme:

  1. Select Start > Settings or Right-click on your Desktop empty area.
  2. Select Personalization > Colors.
  3. In the list for Choose your mode, select it to be Custom, Light or Dark.

If you or anyone else wants more settings and theme related options to be built-in to qBittorrent, then you should create a new feature request.

Alternatively if you want to discuss and share ideas or wish to get more complex workarounds to make qBittorrent look how you want, then please use the Discussions page.

@ObedPM ObedPM changed the title Dark theme Need way to switch between Dark and Light Mode regardless of System Mode Sep 30, 2024
@xavier2k6
Copy link
Member

xavier2k6 commented Sep 30, 2024

For those that don't want qBittorrent v5 to automatically switch to Dark "App" mode, here are some choices:

  1. Personalisation->Colours->Choose your color->Custom->Choose your default app mode->Light
    Screenshot 2024-09-30 091440

  2. Modify qt.conf file with WindowsArguments = darkmode=0 (this will disable qBittorrent's dark "app" mode support.)
    Screenshot 2024-09-30 091956

@sledgehammer999
Copy link
Member

sledgehammer999 commented Sep 30, 2024

If you want the native style (used in v4.6.x)
Launch qbittorrent.exe like this: <path-to-qbt>/qbittorrent.exe -style WindowsVista
The WindowsVista has limited supported for dark mode, if any at all.

The darkmode possible values are explained here: https://doc.qt.io/qt-6/qguiapplication.html#platform-specific-arguments

@sledgehammer999
Copy link
Member

I wonder if we should provide an UI setting "Use native UI style (may disable dark mode)".

@sledgehammer999 sledgehammer999 added GUI GUI-related issues/changes Look and feel Affect UI "Look and feel" only without changing the logic labels Sep 30, 2024
@xavier2k6
Copy link
Member

I wonder if we should provide an UI setting "Use native UI style (may disable dark mode)".

and hinder HiDPI support as previously discussed

@sledgehammer999
Copy link
Member

and hinder HiDPI support as previously discussed

Citation? I run HiDPI with fractional scaling and native style since qt5 and I haven't had issues. Can you point me to them?

@xavier2k6
Copy link
Member

Revisit PR #19051

@electrifying
Copy link

If you want the native style (used in v4.6.x) Launch qbittorrent.exe like this: <path-to-qbt>/qbittorrent.exe -style WindowsVista The WindowsVista has limited supported for dark mode, if any at all.

The darkmode possible values are explained here: https://doc.qt.io/qt-6/qguiapplication.html#platform-specific-arguments

now we will always have to do this to get a non-broken interface?

@sledgehammer999
Copy link
Member

Revisit PR #19051

AFAICT, you mentioned HiDPI here and I answered here. Aka Qt6 doesn't have a recommendation for Fusion+hidpi anymore.

@qBittUser
Copy link

@electrifying

now we will always have to do this to get a non-broken interface?

If something is broken, then a proper new issue report needs to be made.

@xavier2k6
Copy link
Member

@electrifying

now we will always have to do this to get a non-broken interface?

If something is broken, then a proper new issue report needs to be made.

they came here from #21423

@xavier2k6
Copy link
Member

Revisit PR #19051

AFAICT, you mentioned HiDPI here and I answered here. Aka Qt6 doesn't have a recommendation for Fusion+hidpi anymore.

ok, but Qt still prefer it (fusion style) in Qt 6 for Windows 11 (although....since then they now also have introduces a windows11 style)
#19051 (comment)

@xavier2k6
Copy link
Member

Also, see my other #19051 (comment)

@sledgehammer999
Copy link
Member

Revisit PR #19051

AFAICT, you mentioned HiDPI here and I answered here. Aka Qt6 doesn't have a recommendation for Fusion+hidpi anymore.

ok, but Qt still prefer it (fusion style) in Qt 6 for Windows 11 (although....since then they now also have introduces a windows11 style) #19051 (comment)

Sure. They recommend it for dark mode, regardless of hidpi.

@xavier2k6
Copy link
Member

Qt 6 is Per-Monitor DPI Aware V2

https://doc.qt.io/qt-6/highdpi.html

Qt 5 was not.

@sledgehammer999
Copy link
Member

Qt 6 is Per-Monitor DPI Aware V2

https://doc.qt.io/qt-6/highdpi.html

Qt 5 was not.

We have officially dropped qt5 support.

@sledgehammer999
Copy link
Member

sledgehammer999 commented Sep 30, 2024

Of relevance to this issue:

It seems that 6.8 introduces a setter for the colorscheme to hint to the system the color mode an application wants. The system may not respect that. And it isn't clear from the docs if Windows will follow it.
Link: https://doc-snapshots.qt.io/qt6-6.8/qstylehints.html#colorScheme-prop

@xavier2k6
Copy link
Member

Qt are always changing what they are doing/don't fully document changed behaviour etc...

look at what was happening to qBittorrent in earlier Qt 6.5 dark "app" mode support with accent color & I believe, it's changed again now.......talking about Windows here.

@vivadavid
Copy link

Thanks, @xavier2k6 : editing the config file worked for me. If light mode can be forced this way, is there a chance the feature can be accessed via the settings of the programme in a future release?

@xavier2k6
Copy link
Member

is there a chance the feature can be accessed via the settings of the programme in a future release?

I'm not sure the config file can be edited during runtime but no doubt there'll be another solution provided in near future.

@vivadavid
Copy link

is there a chance the feature can be accessed via the settings of the programme in a future release?

I'm not sure the config file can be edited during runtime but no doubt there'll be another solution provided in near future.

I keep my fingers crossed! :-)

@SkiFire13
Copy link

Launch qbittorrent.exe like this: <path-to-qbt>/qbittorrent.exe -style WindowsVista

Is there a way to set this on autostart (hopefully in a way that's persistent after upgrades) and that doesn't require to set a global environment variable (i.e. QT_STYLE_OVERRIDE) that affects all Qt programs?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
GUI GUI-related issues/changes has workaround Look and feel Affect UI "Look and feel" only without changing the logic
Projects
None yet
Development

No branches or pull requests

8 participants