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

Feature Request: Toggle Between Screen Line and Text Line Navigation #560

Open
someoneonsmile opened this issue Aug 25, 2024 · 0 comments
Open

Comments

@someoneonsmile
Copy link

Description:
I would like to propose a feature that allows less to toggle between navigating by screen lines and text lines. Currently, navigation in less by default is done by screen lines (e.g., using the arrow keys or j), which can be confusing when dealing with wrapped lines. Instead of introducing new keybindings, I suggest using a toggle or flag to switch between these two modes.

Proposed Solution:

  • Implement a toggle (possibly a command-line flag or an in-session toggle key) that allows users to switch between screen line navigation and text line navigation.
  • When the toggle is set to screen line mode, less would behave as it currently does, navigating by screen lines.
  • When switched to text line mode, navigation commands like j would move by actual text lines, ignoring line wrapping on the screen.

Use Case:
This feature would be particularly useful when viewing files with long lines that wrap on the screen. It would provide users the flexibility to choose the most appropriate navigation method for their needs, especially those familiar with Vim’s navigation behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants