mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-31 20:31:19 -03:00
edit_command_buffer: speed up setting cursor position by line/column
alt-e restores the cursor position received from the editor, moving by one character at a time. This can be super slow on large commandlines, even on release builds. Let's fix that by setting the coordinates directly.
This commit is contained in:
@@ -97,7 +97,12 @@ If ``commandline`` is called during a call to complete a given string using ``co
|
||||
The following options output metadata about the commandline state:
|
||||
|
||||
**-L** or **--line**
|
||||
Print the line that the cursor is on, with the topmost line starting at 1.
|
||||
If no argument is given, print the line that the cursor is on, with the topmost line starting at 1.
|
||||
Otherwise, set the cursor to the given line.
|
||||
|
||||
**--column**
|
||||
If no argument is given, print the 1-based offset from the start of the line to the cursor position in Unicode code points.
|
||||
Otherwise, set the cursor to the given code point offset.
|
||||
|
||||
**-S** or **--search-mode**
|
||||
Evaluates to true if the commandline is performing a history search.
|
||||
|
||||
Reference in New Issue
Block a user