Bug 435164 - Export gtk-error-bell=0 so that GTK apps don't sometimes make horrible jarring keeping sounds
Summary: Export gtk-error-bell=0 so that GTK apps don't sometimes make horrible jarrin...
Status: RESOLVED UPSTREAM
Alias: None
Product: systemsettings
Classification: Applications
Component: kcm_style (show other bugs)
Version: unspecified
Platform: Other Linux
: HI wishlist
Target Milestone: ---
Assignee: Plasma Bugs List
URL: https://gitlab.freedesktop.org/pipewi...
Keywords:
Depends on:
Blocks:
 
Reported: 2021-03-30 21:23 UTC by Nate Graham
Modified: 2022-09-15 00:12 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nate Graham 2021-03-30 21:23:37 UTC
nate@Liberator:~/kde/src/breeze-gtk$  (master) grep -ri bell .
./src/settings.ini:4:gtk-error-bell=0

nate@Liberator:~/kde/src/breeze-gtk$  (master) gri bell ~/.config/gtk*
[no output]


Not sure whether this is a bug in the theme itself, or in kde-gtk-config, or in the style KCM. But regardless, it isn't getting exported anymore, so my GTK applications are making disturbing sounds again.
Comment 1 Mikhail Zolotukhin 2021-03-30 21:46:15 UTC
"gtk-error-bell" was never exported in kde-gtk-config AFAIK.
Comment 2 Alois Wohlschlager 2021-03-31 16:57:51 UTC
Indeed this is not exported by kde-gtk-config, it is present in /usr/share/themes/Breeze/settings.ini. I do not know if/when Gtk loads this file though.
Comment 3 Nate Graham 2021-04-01 17:33:24 UTC
Hmm, I can confirm that it looks good on my system. Maybe GTK stopped reading that file? Is that possible?
Comment 4 Nate Graham 2021-05-28 19:58:34 UTC
Maybe kde-gtk-config can export that file to the settings.ini file in the user's homedir, where we can be sure it does get read?
Comment 5 Nate Graham 2022-09-14 21:14:34 UTC
(In reply to Alois Wohlschlager from comment #2)
> Indeed this is not exported by kde-gtk-config, it is present in
> /usr/share/themes/Breeze/settings.ini. I do not know if/when Gtk loads this
> file though.

Looks like it's set in breeze-gtk's ini file: https://invent.kde.org/plasma/breeze-gtk/-/blob/master/src/settings.ini
Comment 6 Nate Graham 2022-09-14 21:42:45 UTC
Looked into doing this in kde-gtk-config, and it works, but it just didn't feel like the right place to do it, as this would result in overriding user settings in the case that a user liked the bell and forced it to on.

Ultimately the best solution here is for the system to load the pulseaudio-x11-bell or pipewire-x11-bell module, both of which translate the awful bell sound into something nice.

For PipeWire, this module is not loaded by default: https://gitlab.freedesktop.org/pipewire/pipewire/-/blob/master/src/daemon/pipewire.conf.in#L162

I'll submit a patch to load it by default at the PipeWire level. If it's rejected, I'll ask distros to do it. :)