lbonn / rofi

Rofi: A window switcher, run dialog and dmenu replacement - fork with wayland support
Other
927 stars 36 forks source link

[BUG] dmenu mode broken #59

Closed Yaroslav-95 closed 1 year ago

Yaroslav-95 commented 1 year ago

Rofi version (rofi -v)

1.7.5 and latest commit on wayland branch

Configuration

https://gist.github.com/Yaroslav-95/f48adff91924cb2b2cea8d7ed396e49c

Launch command

rofi dmenu

Step to reproduce

Launch a script that makes use of the dmenu mode, e.g. https://github.com/firecat53/networkmanager-dmenu

Expected behavior

Normal rofi window.

Actual behavior

Rofi window that cuts off before the list, therefore, not showing the elements from the list, can still type and enter-guess the options.

Additional information

Tested under Artix Linux with Sway 1.7, if it's of any use.

Yaroslav-95 commented 1 year ago

Here's a screenshot for a better idea of the problem scrot

Yaroslav-95 commented 1 year ago

Some more information to help debug this. Commit/merge 853c8c9a appears to have introduced this bug, prio to that merge (commit 1e8c22b4) the bug wasn't present.

2goodAP commented 1 year ago

Hey @Yaroslav-95, thank you for opening this issue. I was about to open a similar one but thought I'd just add onto it.

It seems that this window clipping behavior is not specific to dmenu mode. I'm on NixOS, using the 1.7.5+wayland1 version from nixpkgs-unstable, which seems to be the release version (commit 9ec8622). I've managed to narrow the config down to the following lines:

    configuration {
        modi: ["drun", "run", "filebrowser", "ssh", "combi"];
    }

    window {
        border: 5px;
        border-radius: 20px;
    }

    mainbox {
        children: ["inputbar", "message", "mode-switcher", "listview"];
    }

Case I

With the above config, when I start in filebrowser mode, the message container appears and the window behaves normally as show in the screenshot below. In this case, I can switch to other modes just fine there is no window clipping behavior happening.

Screenshot_20220917_070311

Case II

However, when I launch with the same config in drun (or any other mode that is not filebrowser), the message element is not visible initially.

Screenshot_20220917_065430

So, when I switch to filebrowser mode in this case, message shows up and then the window fails to draw/expand properly downwards which causes this clipping behavior that @Yaroslav-95 also mentioned.

Screenshot_20220917_065453

Some More Things

I have also tried other fancier configs and moving the message element around a bit. While doing so, it almost seemed to me that the rofi window moves/relocates upwards just fine but cannot expand downwards causing the clipping. Idk how correct/helpful this information may be for you @lbonn.

Aleksanaa commented 1 year ago

Some more information to help debug this. Commit/merge 853c8c9 appears to have introduced this bug, prio to that merge (commit 1e8c22b) the bug wasn't present.

Are you sure? I'm using 1e8c22 and the problem is still there.

Aleksanaa commented 1 year ago

For anyone who gets annoyed by this bug, you can still have similar functionalities with rofi script mode!

lbonn commented 1 year ago

I can reproduce the bug reported by @2goodAP but not the original report. Do you have more detailed reproduction instructions @Aleksanaa, @Yaroslav-95 ?

lbonn commented 1 year ago

It should be fixed in master

Yaroslav-95 commented 1 year ago

On 23/02/10 03:54PM, lbonn wrote:

Closed #59 as completed.

Can confirm it's fixed for me. Thanks a lot!

--

Yaroslav de la Peña Smirnov