hyprland-plugins icon indicating copy to clipboard operation
hyprland-plugins copied to clipboard

expo: add a scroll overview

Open vaxerski opened this issue 2 months ago • 19 comments

Fixes https://github.com/hyprwm/hyprland-plugins/issues/480

Needs some testing.

TODOs:

  • [ ] Trackpad gesture

Will automatically use the new scroll overview if you have a scrolling layout set

cc @taylorstools @clotodex can you guys test this?

vaxerski avatar Oct 04 '25 14:10 vaxerski

1° scrolling zooms in and out instead of cycling workspaces. It's a cool feature I think but now you can't scroll up and down to see other workspaces. Maybe leave as is and go up/down when changing workspace ?

bindd = $mainMod CTRL, right, Go to workspace +1, workspace, m+1 bindd = $mainMod CTRL, left, Go to workspace -1, workspace, m-1

I don't really use scrolling layout nor niri so idk what ppl expects

2° floating windows are not displayed

https://github.com/user-attachments/assets/7d9de1e5-e8dd-47ce-a10e-e9a3b341f937

3° hyprexpo in master is not working anymore?

https://github.com/user-attachments/assets/d233352b-d78f-411a-9595-5ad4851c2d34

it looks very cool ngl.

aphelei avatar Oct 04 '25 15:10 aphelei

fixed 2 and 3, idk about 1 I'd need input. I dont mind.

vaxerski avatar Oct 04 '25 17:10 vaxerski

idk might be nvidia but it's got a few bugs on my end.

  1. currently the overview doesn't limit window operations, so doing 'killactive' semi-crashes us, or doing 'fullscreen, 0' while in overview bugs out and doing 'fullscreen, 1' from there makes it flicker

  2. zooming doesn't work right, if I scroll slowly it's fine, but if I scroll fast it zooms in/out really slowly, my mouse freezes unless I'm using the zoom too: https://github.com/user-attachments/assets/47dc990b-b1b7-412e-a6df-45b39a2062ff

  3. floating vs fullscreen window is not right: https://github.com/user-attachments/assets/71922c79-9c93-4d35-a642-84cd98938137 https://github.com/user-attachments/assets/17342471-10fc-421a-82ec-c623d35f38ac

I didn't use expo before because it was too limited, it just doesn't work if hyprland is about keybinds but then I have to rely on the mouse, it needs to work with bindings, like scrolling the workspaces overview up and down one by one on a keybinding, the zoom can stay in but it is way less useful than scrolling the workspaces vertically themselves.

(also live overviews would be mega based and make sense here, esp if we want to make killing and moving around windows in the overview possible, might want to see how niri does it, hyprland is already better but could be really competitive in this feature but it needs work right now.)

Kwepoi avatar Oct 05 '25 19:10 Kwepoi

Also got around to test it now (disclaimer, not a normal expo user, so things could be user-issue):

  • looks great! (especially also seeing the other workspaces)
  • cursor is broken while in expo mode, it just simply does not move
  • I dont understand how to flip through windows or generally how to navigate in the mode
  • if I try to select a window using the scrolling focus, then the overview flickers like crazy but does not change view
  • like @aphelei said, scrolling=zooming was unintuitive/unexpected. I dont know if I need the ability to zoom, instead scrolling through windows would have felt more natural - however this is gutfeeling, not an expectation. I would rather like to control the "default" zoom as a config value and dont expect to change it all too much otherwise

EDIT:

  • the cursor actually is moving, but the movement not rendering (using custom cursor, so that might play a part). So when I move, then zoom, the cursor jumps to the position i moved it to when the zoom starts
  • if we want to stick with the zoom, I also found that it does not zoom to the center of the cursor position but only to the center of the screen

clotodex avatar Oct 06 '25 07:10 clotodex

This looks great.

In niri, mouse scrolling up moves up a workspace, mouse scrolling down moves down one. When you reach the first or last workspace, it stops instead of looping back around. Behavior like this, or maybe constantly cycling workspaces when scrolling, would be preferred behavior imo for mouse scroll. Or you could let it be configurable, or maybe a pinch-to-zoom gesture for zoom-in/out and mouse/touchpad scroll to scroll workspaces. Afaik there is no zoom-in/out in Niri's overview, but it makes sense here and I like it, especially if a workspace is filled with windows.

I replicated the issue Kwepoi has with killactive while in overview, hyprland crashes.

I'm guessing that adding touchpad gestures would add this capability?: click and drag windows with mouse/touchpad to change the order/position of windows on current workspace, or click and drag windows to move to different workspace.

Minor things:

  • Having window blur in overview would be nice
  • Having Hyprbars visible in overview with working buttons would also be nice

taylorstools avatar Oct 08 '25 06:10 taylorstools

you can now flip plugin:hyprexpo:scrolling:scroll_moves_up_down to true to get scroll moves workspace

vaxerski avatar Oct 12 '25 12:10 vaxerski

Added default_zoom next to that and flipped scroll moves up and down to true by default

vaxerski avatar Oct 12 '25 12:10 vaxerski

live previews done, windows now update.

vaxerski avatar Oct 12 '25 12:10 vaxerski

anything else outside of the gesture?

vaxerski avatar Oct 12 '25 12:10 vaxerski

Trying to killactive while in overview still crashes Hyprland.

I also have this weird behavior when trying to scroll with my laptop touchpad. Attempting to scroll down just causes it to flick back up. It works as expected with mouse scrolling though. Wondering if other laptop users can replicate:

https://github.com/user-attachments/assets/9efaf0cf-f0cb-4809-b004-85f617a163fd

taylorstools avatar Oct 12 '25 23:10 taylorstools

I can replicate @taylorstools . Also when switching focus between Windows (which works now) - i have a crazy jitter, as if the rendering does either not animate properly (lag) or if there is some greedy loop. Let me know if I should record it or if it is anyways still wip. Otherwise my other issues also still persist.

clotodex avatar Oct 13 '25 12:10 clotodex

wdym switching focus between windows? I am unsure if I understand what that means in this case

vaxerski avatar Oct 13 '25 14:10 vaxerski

I am looking for 3 base features and 2 extended features with Hyprexpo + scrolling:

  • render an overview (done - exactly what I was looking for)
  • scroll or move between workspaces (I experience @taylorstools bug of it moving but snapping back)
  • scroll or move between windows IN a workspace - so "left to right" - using the focus layoutmessage (horizontal scroll does not work for me, using the keybinds to move the focus between windows works, but jitters and lags) <- this is what i was referencing The extended (optional) features
  • "jumping" to a different window, i.e. switching focus - ideally with keyboard navigation, similar to what hyprscroller had with its vim-easymotion style jumping
  • moving windows, both within a workspace as well as across workspaces - with mouse or keyboard

Hope this makes it more clear

clotodex avatar Oct 14 '25 07:10 clotodex

moving within workspace now works for me, moving between workspaces works, crash fixed

IDK if I'll implement drag-and-drop window functionality in this MR, regular expo doesnt have it either.

vaxerski avatar Oct 15 '25 12:10 vaxerski

Moving within the workspace works for me now. Will there be ability to assign gesture to horizontally navigating in a workspace in overview in this MR?

Even with this new commit, I still have the bug with scrolling with touchpad, where it flicks back up to the top workspace. And killactive while the overview is open still makes Hyprland crash.

taylorstools avatar Oct 16 '25 06:10 taylorstools

1° i can't scroll workspace with my keyboard eg bindd = $mainMod CTRL, right, Go to workspace +1, workspace, m+1 bindd = $mainMod CTRL, left, Go to workspace -1, workspace, m-1

https://github.com/user-attachments/assets/7c46e422-4edc-4d69-ac2b-c1124733e05a

2° blur and windows decorations aren't displayed (group bar, borders) (see vid)

3° it is displayed above the bar (see vid)

aphelei avatar Oct 16 '25 20:10 aphelei

4° windows become opaque when opening a new window

https://github.com/user-attachments/assets/ab53cc60-d170-468f-92b0-5329e5710b9a

5° layers not updated when in hyprexpo

https://github.com/user-attachments/assets/ed9a40c8-8e52-4c7b-b64d-47af31785aaa

aphelei avatar Oct 16 '25 20:10 aphelei

decorations cant be fixed atm would require some fixes in hl

vaxerski avatar Oct 19 '25 14:10 vaxerski

To me this is usable and would love to merge it, since this branch now diverged from hyprland main.

My main thing i am looking for is to fix navigation and extend the keybinds.

I realized the latter is also what others are missing from normal hyprexpo. I would argue this is more relevant to scroll users due to navigation being necessary since you cant see everything #195

clotodex avatar Oct 28 '25 06:10 clotodex

I've added swipe gestures but can't check just yet my laptop is updating. Feel free to check. It's also rebased and compatible with latest git.

vaxerski avatar Dec 08 '25 15:12 vaxerski