Guake / guake

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

Guake change position on toggle #2180

Open AurelReb opened 1 year ago

AurelReb commented 1 year ago

Describe the bug

Guake terminal's position changes on every toggle, moving step by step to the bottom-right corner of my screen. I get this bug since the last release of guake (3.10) installed with pacman.

Here is the output of guake --support :

$ guake --support Guake Version: 3.11.dev0 Vte Version: 0.72.1 Vte Runtime Version: 0.72.1 -------------------------------------------------- GTK+ Version: 3.24.37 GDK Backend:

I'm using archlinux

Expected behavior

Guake opens everytime at the same position on the screen

Actual behavior

First toggle: image

After 7 toggles : image

To Reproduce

Run guake version 3.10 with a fully updated archlinux system, with i3wm.

trinaldi commented 1 year ago

Same here. I have the same specs (i3wn + X11 + Arch).

Every time I hit F12 (toggle), the terminal drops a few pixels. Toggling fullscreen reverts the position.

I reverted back to 3.9 and added guake to ignore list on pacman.conf (Intructions)

szmktk commented 1 year ago

Same here - I encountered the same behavior on both of my machines:

Thanks to trinaldi I mitigated this issue by downgrading, but fixing this issue would be most appreciated.

BTW this issue seems to be a duplicate of https://github.com/Guake/guake/issues/2177

palytoxin commented 1 year ago

I have two computers. (KDE/i3wm)

The new version has fixed the issue of width on KDE. But i3wm also same problem as upon

https://github.com/Guake/guake/assets/1829328/1afe27b9-2de8-4265-adbf-76682418dfd8

liqiang0330 commented 1 year ago

@trinaldi trinaldi thank u.

guake 3.10 have a bug. downgrade to guake 3.9

1, sudo vim /etc/pacman.conf add guake to ingore pkg. 2, sudo downgrade guake choose guake 3.9

trinaldi commented 1 year ago

Piggybacking on @liqiang0330

You can get the 3.9 version from the Arch Archive

  1. sudoedit /etc/pacman.conf and add guake to IgnorePkg (line 25 for me):

    ...
    IgnorePkg   = guake
    ...
  2. Inside the directory where you downloaded the guake-3.9.0-3-any.pkg.tar.zst file, run

sudo pacman -U guake-3.9.0-3-any.pkg.tar.zst

madhur commented 1 year ago

I have switched to kitty terminal due to this bug

On Mon, Jun 19, 2023, 22:30 Tiago Rinaldi @.***> wrote:

Piggybacking on @liqiang0330 https://github.com/liqiang0330

You can get the 3.9 version from the Arch Archive https://archive.archlinux.org/packages/g/guake/

  1. sudoedit /etc/pacman.conf and add guake to IgnorePkg (line 25 for me):

... IgnorePkg = guake ...

  1. Inside the directory where you downloaded the guake-3.9.0-3-any.pkg.tar.zst file, run

sudo pacman -U guake-3.9.0-3-any.pkg.tar.zst

— Reply to this email directly, view it on GitHub https://github.com/Guake/guake/issues/2180#issuecomment-1597494583, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAD4L54DCLFPBB6FBVLFGCDXMCATLANCNFSM6AAAAAAYPKMFGA . You are receiving this because you are subscribed to this thread.Message ID: @.***>

Enr1g commented 9 months ago

i3-wm fix without downgrading ($HOME/.config/i3/config):

for_window [class="Guake"] move window to position 0 px 0 px

UPD: doesn't work in multi-monitor setup. Try using xrandr + xdotool like this:

for_window [class="Guake"] exec --no-startup-id top_left.py
#!/usr/bin/env python
import subprocess
from dataclasses import dataclass
import re

GREP = re.compile(r"^(?P<name>[^ ]+) .* (?P<width>\d+)x(?P<height>\d+)\+(?P<x>\d+)\+(?P<y>\d+).*$")

@dataclass
class Monitor:
    name: str
    width: int
    height: int
    x: int
    y: int

    def contains(self, x, y):
        return self.x <= x <= self.x + self.width and self.y <= y <= self.y + self.height

def main():
    mx, my = None, None
    output = subprocess.check_output(["xdotool", "getmouselocation", "--shell"]).decode().split("\n")
    for line in output:
        line = line.split("=")

        match line[0]:
            case "X":
                mx = int(line[1])
            case "Y":
                my = int(line[1])

    print(f"mx = {mx}, my = {my}")
    if mx is None or my is None:
        return

    lines = subprocess.check_output(["xrandr", "--current"]).decode().split("\n")
    lines = filter(lambda line: " connected " in line, lines)

    for line in lines:
        gd = GREP.match(line).groupdict()
        print(f"Detected: {gd}")

        monitor = Monitor(name=gd["name"], width=int(gd["width"]), height=int(gd["height"]), x=int(gd["x"]), y=int(gd["y"]))

        if monitor.contains(mx, my):
            print(f"Current monitor: {monitor.name}")
            print(
                subprocess.check_output(["i3-msg", f'[class="Guake"] move position {monitor.x} px {monitor.y} px']).decode()
            )
            break
    else:
        print("Impossible...")

if __name__ == '__main__':
    main()
cowclaw commented 8 months ago

Same issue here on: xubuntu 23.10, X11 21.1.7-3ubuntu2.1, i3 wm 4.22-2, guake 3.10-1

elementary-charge commented 4 months ago

Based on previous answer for i3wm but for the BOTTOM screen side:

for_window [class="Guake"] move window to position 0 ppt 50 ppt, set resize 100 ppt 50 ppt

novaTopFlex commented 2 months ago

I believe that this may be an issue with your window manager or even your Xorg or Wayland configuration. I am currently using Xorg with Openbox as my window manager without a DE and do not have any issues with placement at all. On my Guake settings, my system respects my bottom-align desire, and the only issue that I have is with the tint2 application running, and even then, changing tabs often reverts the position to no longer cover excessive width.


In simpler terms, I am not suffering from any slight movement of this Guake terminal between showing and hiding of the terminal with Openbox on Xorg.