-
Notifications
You must be signed in to change notification settings - Fork 30
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
Visual selection utility fixes #265
Conversation
39da4f0
to
7c5bcbf
Compare
7c5bcbf
to
01a5554
Compare
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.
thank you so much for the fixes! Requested changes are mostly renames 😄
Thanks so much for the review! I applied the requested changes 😄 |
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.
Only one tiny nitpick about mentioning strict
param in help doc. Otherwise all good!
Ah, nice catch. Just added the parameter to the docs |
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.
great!
While playing around with the visual selection functionality I found a couple bugs.
update_prefills
I noticed that the current method for "leave visual mode" actually puts you into selection mode in the already open instance of grug-far which is very disorienting. This changes the method of leaving visual mode before getting the selection so that when updating the prefills you end up in the mode you expect in the grug-far window. While fixing this, I also normalized the use of this functionality to a utility function so there is a single place to change how to "leave visual mode"get_current_visual_selection_split
. This is useful internally and could be useful for the end user.get_current_visual_selection_split
so the logic is centralized and easier to maintain in the future and to populate bug fixes across all locations in the code.Let me know what you think!