mylinuxforwork / dotfiles

The ML4W Dotfiles for Hyprland - An advanced and full-featured configuration for the dynamic tiling window manager Hyprland including an easy to use installation script for Arch based Linux distributions.
GNU General Public License v3.0
1.2k stars 95 forks source link

[BUG] - ML4W Settings App does not work *when* using display scaling #258

Closed armenr closed 2 months ago

armenr commented 2 months ago

Describe the bug ML4W Settings App and various other apps (Calculator, Files, etc) all crash/break if using any scaling settings for display in hyprland.

To Reproduce Use some setting like this:

#monitor = eDP-1, 3072x1920@60, 0x0, 1.5
monitor = eDP-1, 3072x1920@120, 0x0, 1.333333

Then attempt to open one ML4WSettings App or gnome-text-editor

❯ gnome-text-editor

(gnome-text-editor:79526): Adwaita-WARNING **: 17:00:53.743: Using GtkSettings:gtk-application-prefer-dark-theme with libadwaita is unsupported. Please use AdwStyleManager:color-scheme instead.

(gnome-text-editor:79526): libenchant-WARNING **: 17:00:53.849: broker.vala:159: Error loading plugin: libaspell.so.15: cannot open shared object file: No such file or directory

(gnome-text-editor:79526): libenchant-WARNING **: 17:00:53.849: broker.vala:159: Error loading plugin: libhspell.so.0: cannot open shared object file: No such file or directory

(gnome-text-editor:79526): libenchant-WARNING **: 17:00:53.850: broker.vala:159: Error loading plugin: libnuspell.so.5: cannot open shared object file: No such file or directory

(gnome-text-editor:79526): libenchant-WARNING **: 17:00:53.850: broker.vala:159: Error loading plugin: libvoikko.so.1: cannot open shared object file: No such file or directory
MESA-INTEL: warning: ../mesa-24.2.3/src/intel/vulkan/anv_formats.c:763: FINISHME: support YUV colorspace with DRM format modifiers
MESA-INTEL: warning: ../mesa-24.2.3/src/intel/vulkan/anv_formats.c:794: FINISHME: support more multi-planar formats with DRM modifiers
fish: Job 1, 'gnome-text-editor' terminated by signal SIGSEGV (Address boundary error)

Expected behavior Uncertain whether this is actually related to ML4W Dotfiles/settings or not, or whether it can be addressed by it. :-\

Distribution (please complete the following information):

Additional context Using the dark-mode enabled settings ( I think it uses gtk-portal?)

mylinuxforwork commented 2 months ago

@armenr Is it working correctly with scaling 1 or 2?

mylinuxforwork commented 2 months ago

I guess it’s because of fractional scaling. Maybe you need to set a gnome environment variable to enable it. https://forum.endeavouros.com/t/fractional-scaling-on-gnome/57254/2

ffoebel commented 2 months ago

Seems to be a GTK bug: https://gitlab.gnome.org/GNOME/gtk/-/issues/7022

armenr commented 2 months ago

@mylinuxforwork - if scaling is set to 1, it does not happen. If it's anything other than 1 (including whole numbers like 2), it happens.

I will look at the link you shared. Thank you!

@ffoebel - Thank you, I will have a look here as well!

armenr commented 2 months ago

@ffoebel - I can confirm that GDK_DISABLE=vulkan gnome-calculator works.

@mylinuxforwork -- I have just one (silly) question, since I'm still a bit of a newb to some of this.

When I run gsettings set org.gnome.mutter experimental-features "['scale-monitor-framebuffer']" the return is: No such schema “org.gnome.mutter”

In our case, using hypr + ml4w, what should I do to try to enable that?

Also, in my conf/custom.conf, I added the following:

# Workaround for Gnome + Vulkan b0rkness
# ref: https://gitlab.gnome.org/GNOME/gtk/-/issues/7022

env = GDK_DISABLE,vulkan

...but it doesn't seem to persist/help. Is there a better way (or more correct way) that I should be setting this environment variable with hypr + ML4W?

Thanks so much for the quick help to both of you!

armenr commented 2 months ago

Dropping this off in ml4w's custom.conf file did the trick:

# Workaround for Gnome + Vulkan b0rkness
# ref: https://gitlab.gnome.org/GNOME/gtk/-/issues/7022
# ref: https://github.com/hyprwm/Hyprland/issues/7854
env=GSK_RENDERER,ngl

Thanks for the help!

mylinuxforwork commented 2 months ago

@armenr Do you think there are any negative side effects when I put it as default into the environment.conf

armenr commented 2 months ago

Check out this comment: https://github.com/hyprwm/Hyprland/issues/7854#issuecomment-2363260275

Looks like the default was never vulkan to begin with. I think adding that default setting should be fine, at least according to what's in this thread 😎