Guake / guake

Drop-down terminal for GNOME
https://guake.github.io
GNU General Public License v2.0
4.37k stars 577 forks source link

Window blurry under Wayland and with fractional scaling #2220

Open rmeissn opened 5 months ago

rmeissn commented 5 months ago

Describe the bug

The guake window is blurry on a hiDPI Display with fractional scaling under Gnome/Wayland, scaled to 150%.

When starting guake in wayland mode - wanted to test whether it behaves better - it won't start and errors with:

Guake not running, starting it
Loading Gnome schema from: /home/.../.local/lib/python3.12/site-packages/guake/data
Language previously loaded from: /home/.../.local/lib/python3.12/site-packages/guake/po
Guake Terminal 3.10
VTE 0.74.2
Gtk 3.24.39

(guake:236630): Gtk-CRITICAL **: 11:17:19.627: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed
created fresh notebook for workspace 0
Spawning new terminal at /home/...
current workspace is 0
can't bind show-focus key
Traceback (most recent call last):
  File "/usr/lib64/python3.12/site-packages/dbus/bus.py", line 173, in activate_name_owner
    return self.get_name_owner(bus_name)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.12/site-packages/dbus/bus.py", line 348, in get_name_owner
    return self.call_blocking(BUS_DAEMON_NAME, BUS_DAEMON_PATH,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.12/site-packages/dbus/connection.py", line 634, in call_blocking
    reply_message = self.send_message_with_reply_and_block(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.NameHasNoOwner: The name does not have an owner

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/.../.local/lib/python3.12/site-packages/guake/main.py", line 479, in main
    remote_object = bus.get_object(DBUS_NAME, DBUS_PATH)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.12/site-packages/dbus/bus.py", line 237, in get_object
    return self.ProxyObjectClass(self, bus_name, object_path,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.12/site-packages/dbus/proxies.py", line 250, in __init__
    self._named_service = conn.activate_name_owner(bus_name)
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.12/site-packages/dbus/bus.py", line 178, in activate_name_owner
    self.start_service_by_name(bus_name)
  File "/usr/lib64/python3.12/site-packages/dbus/bus.py", line 273, in start_service_by_name
    return (True, self.call_blocking(BUS_DAEMON_NAME, BUS_DAEMON_PATH,
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.12/site-packages/dbus/connection.py", line 634, in call_blocking
    reply_message = self.send_message_with_reply_and_block(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.ServiceUnknown: The name is not activatable

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/.../.local/bin/guake", line 8, in <module>
    sys.exit(exec_main())
             ^^^^^^^^^^^
  File "/home/.../.local/lib/python3.12/site-packages/guake/main.py", line 664, in exec_main
    if not main():
           ^^^^^^
  File "/home/.../.local/lib/python3.12/site-packages/guake/main.py", line 495, in main
    instance = Guake()
               ^^^^^^^
  File "/home/.../.local/lib/python3.12/site-packages/guake/guake_app.py", line 262, in __init__
    self.load_config()
  File "/home/.../.local/lib/python3.12/site-packages/guake/guake_app.py", line 817, in load_config
    self.settings.general.triggerOnChangedValue(
  File "/home/.../.local/lib/python3.12/site-packages/guake/settings.py", line 119, in triggerOnChangedValue
    func(settings, key, user_data)
  File "/home/.../.local/lib/python3.12/site-packages/guake/gsettings.py", line 157, in size_changed
    RectCalculator.set_final_window_rect(self.settings, self.guake.window)
  File "/home/.../.local/lib/python3.12/site-packages/guake/utils.py", line 275, in set_final_window_rect
    window_rect = monitor.get_workarea()
                  ^^^^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'get_workarea'

Expected behavior

The guake windows is crisp and sharp, just like most other applications on a hiDPI Display with fractional scaling under Gnome/Wayland, scaled to 150%.

To Reproduce

  1. start gnome/wayland
  2. enable fractional scaling and scale to 150%
  3. install latest guake from pypi
  4. open guake and print some directories (to have some text visible)

X11:

$ guake --support Guake Version: 3.10 Vte Version: 0.74.2 Vte Runtime Version: 0.74.2 -------------------------------------------------- GTK+ Version: 3.24.39 GDK Backend: $ guake --support Guake Version: 3.10 Vte Version: 0.74.2 Vte Runtime Version: 0.74.2 -------------------------------------------------- GTK+ Version: 3.24.39 GDK Backend: <__gi__.GdkWaylandDisplay -------------------------------------------------- Desktop Session: gnome -------------------------------------------------- Display: wayland-0 RGBA visual: True Composited: True * Monitor: 0 - BOE 0x095f * Geometry: 1503 x 1002 % 2 at 0, 0 * Size: 280 x 190 mm² * Primary: False * Refresh rate: 59.998000000000005 Hz * Subpixel layout: unknown