Skip to content
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

add ctrl+arrow up/ctrl+arrow down keybinding to go first/end row #91

Conversation

wugeer
Copy link
Contributor

@wugeer wugeer commented Oct 8, 2024

This PR simply adds support for Home/End keys for moving to first/last row.

@jacek-kurlit
Copy link
Owner

Hi!
Thank you for PR
The problem is that Home and End are already taken by tui-textarea create that handles input
https://docs.rs/tui-textarea/latest/tui_textarea/#minimal-usage
Currently pressing Home and End will move caret at the beginning and end of search input which may be more intuitive that jumping at top and last row in processes table
If you find this KyeMap useful you may think about other key combination like Ctrl + g/G

@wugeer
Copy link
Contributor Author

wugeer commented Oct 8, 2024

Hi! Thank you for PR The problem is that Home and End are already taken by tui-textarea create that handles input https://docs.rs/tui-textarea/latest/tui_textarea/#minimal-usage Currently pressing Home and End will move caret at the beginning and end of search input which may be more intuitive that jumping at top and last row in processes table If you find this KyeMap useful you may think about other key combination like Ctrl + g/G

Good idea! But I prefer Ctrl + Up/Down keys to move to the beginning/end, while pressing the Up/Down keys alone represents moving one line. :)

src/tui/rendering.rs Outdated Show resolved Hide resolved
src/tui.rs Show resolved Hide resolved
@wugeer wugeer force-pushed the feat_add_keybinding_to_go_first_and_last_row branch from ee0b763 to f86f875 Compare October 8, 2024 09:16
@wugeer wugeer changed the title add Home/End keybinding to go first/end row add ctrl+arrow up/ctrl+arrow down keybinding to go first/end row Oct 8, 2024
@jacek-kurlit jacek-kurlit added the enhancement New feature or request label Oct 8, 2024
@jacek-kurlit jacek-kurlit merged commit a3829ad into jacek-kurlit:main Oct 8, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants