-
-
Notifications
You must be signed in to change notification settings - Fork 113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add focus-column-or-monitor-left
, focus-column-or-monitor-right
#456
Conversation
Well, it seems both A couple of things about the implementation:
Now, about the test... I'm not quite sure how to write it properly. I attempted to provide some, but I am unsure if they make any sense. This was very fun, so I wouldn't mind rewriting anything you think could be improved. Also, feel free to take it from here. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for taking so long to review, just some minor changes needed.
I'm not entirely sure if using a boolean here is the most idiomatic approach
It's alright.
Now, about the test... I'm not quite sure how to write it properly. I attempted to provide some, but I am unsure if they make any sense.
Seems correct. Just random index should be from 1 because the output random indices are 1 to 5.
Co-authored-by: Ivan Molodetskikh <yalterz@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wait, I just realized. Could you rename Window to Column throughout? Left-Right focus goes by columns, not by windows, and other actions are also focus-column-left, etc.
Sure! I had the same thought initially. We might have been influenced by the initial request. Thanks for catching this. |
May I move them next to the other Column variables? |
Yeah |
focus-window-or-monitor-left
, focus-window-or-monitor-right
focus-column-or-monitor-left
, focus-column-or-monitor-right
Thanks! |
Partially addresses: #296
This is a preliminary sketch for implementing
focus-column-or-monitor-left
andfocus-column-or-monitor-right
, which expand the default left and and right focus behaviors. If a window is available in the target direction, it receives focus; otherwise, the focus shifts to the corresponding monitor.Current state: it kinda works, but there are cases that still need to be fixed. I will try to provide a better description soon.
To be completely honest, I'm new to the Niri codebase, so there's a lot I'm still unsure about. I was hoping to provide a good starting point for this PR, but it seems like I still have a lot to learn.
Any feedback would be greatly appreciated.