[Bug]: Persisted serverColor / serverTextColor break tray menu theming (white text on white background)
- Dominant language
- C++
- Stars
- 3.9k
- Forks
- 1k
- Avg merge
- 1d 17h
- Merged PRs (30d)
- 123
Description
### ⚠️ Before submitting, please verify the following: ⚠️
- [x] This is a **bug**, not a question or a configuration issue.
- [x] This issue is **not** already reported on Github (I've searched it).
- [x] Nextcloud Server and Desktop Client are **up to date**. See [Server Maintenance and Release Schedule](https://github.com/nextcloud/server/wiki/Maintenance-and-Release-Schedule) and [Desktop Releases](https://nextcloud.com/install/#install-clients) for supported versions.
- [x] I agree to follow Nextcloud's [Code of Conduct](https://nextcloud.com/contribute/code-of-conduct/)
### Bug description
The Nextcloud Desktop Client shows **white text on white background** in the system tray account menu (e.g. *Pause sync*, *Settings*, *Exit*).
The issue persists across restarts and **ignores all Qt / GTK theming overrides**.
The problem is caused by **persisted color values** (`serverColor`, `serverTextColor`) stored in the client configuration file.
* `~/.config/Nextcloud/nextcloud.cfg`
```ini
[Accounts]
0\serverColor=...
0\serverTextColor=...
```
see also: [nextcloud.cfg.txt](https://github.com/user-attachments/files/24523003/nextcloud.cfg.txt)
When these values are present, the tray menu is rendered with explicit palette overrides instead of using the platform theme.
Removing these keys immediately fixes the issue.
### Steps to reproduce
1. Use Nextcloud Desktop Client with an existing account configuration
2. Open the system tray menu → *My Account*
3. Observe white text on white background in tray menu entries
4. Hover over a menu entry
→ background changes and text becomes readable
5. Restart client
→ issue persists
**Workaround to fix:**
```bash
sed -i '/serverColor/d;/serverTextColor/d' ~/.config/Nextcloud/nextcloud.cfg
```
After removal, the tray menu uses correct theme colors again.
### Expected behavior
* Tray menus should follow the active Qt / GTK theme
* Persisted account branding colors must **not override global UI palette**
* Theme changes (dark/light) should invalidate stored palette overrides
* Tray menu text should always be readable
### Which files are affected by this bug
~/.config/Nextcloud/nextcloud.cfg
### Operating system
Linux
### Which version of the operating system you are running.
Ubuntu 22.04
### Package
Official PPA
### Nextcloud Server version
32.0.3 (AIO)
### Nextcloud Desktop Client version
4.0.4
### Is this bug present after an update or on a fresh install?
Updated to a major version (ex. 3.16.3 to 3.17.0)
### Are you using the Nextcloud Server Encryption module?
Encryption is Disabled
### Are you using an external user-backend?
- [x] Default internal user-backend
- [ ] LDAP/ Active Directory
- [ ] SSO - SAML
- [ ] Other
### Nextcloud Server logs
```shell
```
### Additional info
Contributor guide
Assessment
This issue has not been assessed yet.