brummer10 / guitarix

guitarix virtual versatile amplification for Jack/Linux
236 stars 24 forks source link

Close X button in tittlebar don't match with gnome theme. #101

Closed arumihsnek closed 4 months ago

arumihsnek commented 2 years ago

Why the X to close the swindow is not the same of other gtk aplications? Captura de pantalla de 2021-12-14 13-29-04

Thanks for this amazing plugin!

brummer10 commented 2 years ago

That depend on your desktop manager, guitarix is GTK3 based, when you sue a QT based desktop manager you may need a gtk3 theme like Breeze or Adwaita. https://wiki.archlinux.org/title/Uniform_look_for_Qt_and_GTK_applications may help

arumihsnek commented 2 years ago

Strange, I have an other theme, but i tried with adwaita too. I'm in gnome wayland, and guitarrix es the only program that show the X like that. Even the qt programs look uniform.

brummer10 commented 2 years ago

I've no experience with wayland, I've just gnome with X-server, there the guitarix window decoration is the same as all other apps. So you may need to find out how to set the window decoration for gtk3 apps under wayland.

hfiguiere commented 2 years ago

it's a theming issue - on Guitarix side. Nothing to do with the graphics subsystem.

brummer10 commented 2 years ago

How to you come to that conclusion? guitarix does nothing in it's theme for window decoration, and, with other desktop managers using the X-server there is not such a issue. Window decoration is added by the desktop-manager.

hfiguiere commented 2 years ago

If you use Mutter/gnome-shell as a compositor (GNOME default) and Gtk3, the window decorations are influenced by the themeing from inside the app.

brummer10 commented 2 years ago

As I said, there is nothing inside the guitarix theme files which will influence the window decoration. And, there is no issue under gnome with the X-server. If wayland require anything from the app theme file for window decoration, then it should have a mechanism to use a fallback.

hfiguiere commented 2 years ago

I checked again and was mistaken, it's only when running using Wayland (the Gdk backend) and how CSD are handled in that case.

hfiguiere commented 2 years ago

Another thing I see here is that when the Guitarix window is not in the front, the title bar is dark colour (using the default Guitarix skin)

This is not a workaround suggestion

If you use the gtk inspector, you can change the visual style of that button, using the following CSS rule:

button.close.titlebutton, button.close.titlebutton > image {
}

I'll see if I can provide a patch to the skin CSS for Guitarix.

brummer10 commented 2 years ago

I looked a bit deeper into that, but don't find a other solution (doable from inside the CSS file) then hiding the titelbar complete. It seems that this one: https://github.com/PCMan/gtk3-nocsd is the way to go to solve (work around) that issue more general.

brummer10 commented 2 years ago

A other way is to force Xwayland by start guitarix like this env WAYLAND_DISPLAY= guitarix