Dark Theme for External Applications

Hi there. Sometimes when we open other external applications they think that a system theme is clear/white by default. So if we can't setup those external applications we will have a white theme forever for those apps. What I want to know is how can we say that the current theme is dark and the value isn't system or clear whithout installing any software, but by only defining system wide variable that the current theme is dark. Perhaps a config property inside a text value can be set to say that ?

System:
Kernel: 5.18.7-zen1-1-zen arch: x86_64 bits: 64 compiler: gcc v: 12.1.0
parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen
root=UUID=fdd54764-dc63-4cb3-8f1d-285b3a23a1a2 rw [email protected]
quiet
cryptdevice=UUID=ad284741-3436-4f92-a2c7-fbcc5651743c:luks-ad284741-3436-4f92-a2c7-fbcc5651743c
root=/dev/mapper/luks-ad284741-3436-4f92-a2c7-fbcc5651743c quiet splash
rd.udev.log_priority=3 vt.global_cursor_default=0
resume=/dev/mapper/luks-8305d0a2-1387-4295-af6b-7e3ae209092b loglevel=3
Desktop: KDE Plasma v: 5.25.2 tk: Qt v: 5.15.5 info: latte-dock
wm: kwin_x11 vt: 1 dm: SDDM Distro: Garuda Linux base: Arch Linux
Machine:
Type: Desktop System: Dell product: Inspiron 5680 v: 2.4.0
serial: <superuser required> Chassis: type: 3 serial: <superuser required>
Mobo: Dell model: 0M8K4M v: A00 serial: <superuser required> UEFI: Dell
v: 2.4.0 date: 06/16/2020
CPU:
Info: model: Intel Core i7-8700 bits: 64 type: MT MCP arch: Coffee Lake
gen: core 8 built: 2018 process: Intel 14nm family: 6 model-id: 0x9E (158)
stepping: 0xA (10) microcode: 0xF0
Topology: cpus: 1x cores: 6 tpc: 2 threads: 12 smt: enabled cache:
L1: 384 KiB desc: d-6x32 KiB; i-6x32 KiB L2: 1.5 MiB desc: 6x256 KiB
L3: 12 MiB desc: 1x12 MiB
Speed (MHz): avg: 2497 high: 2900 min/max: 800/4600 scaling:
driver: intel_pstate governor: powersave cores: 1: 2900 2: 2900 3: 2600
4: 2311 5: 2300 6: 2300 7: 2300 8: 2302 9: 2273 10: 2300 11: 2878
12: 2600 bogomips: 76799
Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
Vulnerabilities:
Type: itlb_multihit status: KVM: VMX disabled
Type: l1tf
mitigation: PTE Inversion; VMX: conditional cache flushes, SMT vulnerable
Type: mds mitigation: Clear CPU buffers; SMT vulnerable
Type: meltdown mitigation: PTI
Type: mmio_stale_data mitigation: Clear CPU buffers; SMT vulnerable
Type: spec_store_bypass
mitigation: Speculative Store Bypass disabled via prctl
Type: spectre_v1
mitigation: usercopy/swapgs barriers and __user pointer sanitization
Type: spectre_v2 mitigation: Retpolines, IBPB: conditional, IBRS_FW,
STIBP: conditional, RSB filling
Type: srbds mitigation: Microcode
Type: tsx_async_abort mitigation: TSX disabled
Graphics:
Device-1: NVIDIA GP106 [GeForce GTX 1060 6GB] vendor: Dell driver: nouveau
v: kernel non-free: 515.xx+ status: current (as of 2022-06) arch: Pascal
process: TSMC 16nm built: 2016-21 pcie: gen: 1 speed: 2.5 GT/s lanes: 16
link-max: gen: 3 speed: 8 GT/s ports: active: HDMI-A-1
empty: DP-1, DP-2, DP-3, DVI-D-1 bus-ID: 01:00.0 chip-ID: 10de:1c03
class-ID: 0300
Display: x11 server: X.Org v: 21.1.3 with: Xwayland v: 22.1.2
compositor: kwin_x11 driver: X: loaded: nouveau unloaded: modesetting
alternate: fbdev,nv,vesa gpu: nouveau display-ID: :0 screens: 1
Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.00x11.22")
s-diag: 582mm (22.93")
Monitor-1: HDMI-A-1 mapped: HDMI-1 model: LG (GoldStar) 23MP55
built: 2014 res: 1920x1080 hz: 60 dpi: 96 gamma: 1.2
size: 510x290mm (20.08x11.42") diag: 587mm (23.1") ratio: 16:9 modes:
max: 1920x1080 min: 640x480
OpenGL: renderer: NV136 v: 4.3 Mesa 22.1.2 direct render: Yes
Audio:
Device-1: Intel 200 Series PCH HD Audio vendor: Dell driver: snd_hda_intel
v: kernel bus-ID: 00:1f.3 chip-ID: 8086:a2f0 class-ID: 0403
Device-2: NVIDIA GP106 High Definition Audio vendor: Dell
driver: snd_hda_intel v: kernel pcie: gen: 1 speed: 2.5 GT/s lanes: 16
link-max: gen: 3 speed: 8 GT/s bus-ID: 01:00.1 chip-ID: 10de:10f1
class-ID: 0403
Sound Server-1: ALSA v: k5.18.7-zen1-1-zen running: yes
Sound Server-2: PulseAudio v: 16.1 running: no
Sound Server-3: PipeWire v: 0.3.52 running: yes
Network:
Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
vendor: Dell driver: r8169 v: kernel pcie: gen: 1 speed: 2.5 GT/s lanes: 1
port: d000 bus-ID: 02:00.0 chip-ID: 10ec:8168 class-ID: 0200
IF: enp2s0 state: up speed: 1000 Mbps duplex: full mac: <filter>
Device-2: Qualcomm Atheros QCA9377 802.11ac Wireless Network Adapter
vendor: Dell driver: ath10k_pci v: kernel pcie: gen: 1 speed: 2.5 GT/s
lanes: 1 bus-ID: 03:00.0 chip-ID: 168c:0042 class-ID: 0280
IF: wlp3s0 state: up mac: <filter>
Bluetooth:
Device-1: Qualcomm Atheros type: USB driver: btusb v: 0.8 bus-ID: 1-12:4
chip-ID: 0cf3:e009 class-ID: e001
Report: bt-adapter ID: hci0 rfk-id: 0 state: up address: <filter>
RAID:
Hardware-1: Intel SATA Controller [RAID mode] driver: ahci v: 3.0
port: f020 bus-ID: 00:17.0 chip-ID: 8086:2822 rev: class-ID: 0104
Drives:
Local Storage: total: 1.24 TiB used: 143.91 GiB (11.3%)
SMART Message: Unable to run smartctl. Root privileges required.
ID-1: /dev/sda maj-min: 8:0 vendor: Western Digital
model: WDS240G2G0A-00JH30 size: 223.57 GiB block-size: physical: 512 B
logical: 512 B speed: 6.0 Gb/s type: SSD serial: <filter> rev: 0400
scheme: GPT
ID-2: /dev/sdb maj-min: 8:16 vendor: Western Digital
model: WD10EZEX-75WN4A0 size: 931.51 GiB block-size: physical: 4096 B
logical: 512 B speed: 6.0 Gb/s type: HDD rpm: 7200 serial: <filter>
rev: 1A02 scheme: GPT
ID-3: /dev/sdc maj-min: 8:32 vendor: SK Hynix model: SC311 SATA 128GB
size: 119.24 GiB block-size: physical: 4096 B logical: 512 B
speed: 6.0 Gb/s type: SSD serial: <filter> rev: 0P10 scheme: GPT
Partition:
ID-1: / raw-size: 206.31 GiB size: 206.31 GiB (100.00%)
used: 13.97 GiB (6.8%) fs: btrfs dev: /dev/dm-0 maj-min: 254:0
mapped: luks-ad284741-3436-4f92-a2c7-fbcc5651743c
ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
used: 720 KiB (0.2%) fs: vfat dev: /dev/sda1 maj-min: 8:1
ID-3: /home raw-size: 206.31 GiB size: 206.31 GiB (100.00%)
used: 13.97 GiB (6.8%) fs: btrfs dev: /dev/dm-0 maj-min: 254:0
mapped: luks-ad284741-3436-4f92-a2c7-fbcc5651743c
ID-4: /var/log raw-size: 206.31 GiB size: 206.31 GiB (100.00%)
used: 13.97 GiB (6.8%) fs: btrfs dev: /dev/dm-0 maj-min: 254:0
mapped: luks-ad284741-3436-4f92-a2c7-fbcc5651743c
ID-5: /var/tmp raw-size: 206.31 GiB size: 206.31 GiB (100.00%)
used: 13.97 GiB (6.8%) fs: btrfs dev: /dev/dm-0 maj-min: 254:0
mapped: luks-ad284741-3436-4f92-a2c7-fbcc5651743c
Swap:
Kernel: swappiness: 133 (default 60) cache-pressure: 100 (default)
ID-1: swap-1 type: zram size: 15.42 GiB used: 0 KiB (0.0%) priority: 100
dev: /dev/zram0
ID-2: swap-2 type: partition size: 16.96 GiB used: 0 KiB (0.0%)
priority: -2 dev: /dev/dm-1 maj-min: 254:1
mapped: luks-8305d0a2-1387-4295-af6b-7e3ae209092b
Sensors:
System Temperatures: cpu: 42.0 C mobo: N/A gpu: nouveau temp: 40.0 C
Fan Speeds (RPM): cpu: 1179 fan-2: 984 gpu: nouveau fan: 1015
Info:
Processes: 302 Uptime: 2h 41m wakeups: 0 Memory: 15.42 GiB
used: 2.71 GiB (17.6%) Init: systemd v: 251 default: graphical
tool: systemctl Compilers: gcc: 12.1.0 Packages: pacman: 1359 lib: 367
Shell: fish v: 3.4.1 default: Bash v: 5.1.16 running-in: konsole
inxi: 3.3.19
Garuda (2.6.4-2):
System install date:     2022-07-01
Last full system update: 2022-07-02
Is partially upgraded:   No
Relevant software:       NetworkManager
Windows dual boot:       No/Undetected
Snapshots:               Snapper
Failed units:

Check/search qt5ct and kvantum.

qt5 settings gui.

kvantum manager

2 Likes

Which external applications? Are they installed via repositories (pacman), flatpak, appimage or something else?

1 Like

For example, Chrome, or CTk (SustomTkinter)

Correction: CustomTkinter and NOT "SustomTkinter" !

Go to Chrome settings and change theme from Classic to GTK+
If that's not enough, go to chrome://flags and enable dark mode.
I don't know if Garuda has a theme for Tkinter at all.

1 Like

Even thought your suggestion works and it is a answer for chrome, one reason to ask what I asked, is to force setting up every application to use the dark theme, in a way that we set only at a single global variable and all other applications which can read what system theme is being used configurates itself to automatically use the dark theme. Otherwise, if we have 40 apps we will need to setup every app to use the dark theme. It seems to be something which an OS should do it. This is something Mac does by itself, and if I remember correct some Windows 11 apps are also doing it.
But thanks for answering !

So far this is the answer for the question. Though, I was imagining to setup inside a file like .bashrc, or .profile, whatsoever is the file name, something like USED_THEME_MODE = "DARK THEME" and not installing an app to do this for me.
Thank you, your answer solves my request!

1 Like

One would have to complain to the programmers, who, by the way, make all programmes available for free, and not to the operating system.
Linux is free, the programmers are free.
Everyone can change everything according to their wishes if they don't like something.
Not so with M$ where, for example, black is not a taskbar colour.
With the other OSs, everything is standardised and the programmers have to stick to the OS's specifications.

Now you can choose what you like better, you are completely free in your decision. :slight_smile:

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.