* Making the 'set-option' command help more descriptive.
* Adding the generated docs
* Making the message multi-line
* Replace newline with break in generated docs
* add reflow command
Users need to be able to hard-wrap text for many applications, including
comments in code, git commit messages, plaintext documentation, etc. It
often falls to the user to manually insert line breaks where appropriate
in order to hard-wrap text.
This commit introduces the "reflow" command (both in the TUI and core
library) to automatically hard-wrap selected text to a given number of
characters (defined by Unicode "extended grapheme clusters"). It handles
lines with a repeated prefix, such as comments ("//") and indentation.
* reflow: consider newlines to be word separators
* replace custom reflow impl with textwrap crate
* Sync reflow command docs with book
* reflow: add default max_line_len language setting
Co-authored-by: Vince Mutolo <vince@mutolo.org>
Allow tab-completion to continue when there is only a single, unambigous
completion target which is a directory. This allows e.g. nested directories
to be quickly drilled down just by hitting <tab> instead of first selecting
the completion then hitting <enter>.
* add run_shell_command
* docgen
* fix command name
Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
* refactored Info::new
* show 'Command failed' if execution fails
* TypedCommand takes care of error handling and printing the error to the statusline.
* docgen
* use Popup instead of autoinfo
* remove to_string in format!
* Revert chage in info.rs
* Show "Command succeed" when success
* Fix info.rs
Co-authored-by: Blaž Hrastnik <blaz@mxxn.io>
When fiddling with paths in a :o prompt, one usually would want Ctrl-W to erase a path segment
rather than the whole path. This is how Ctrl-W works in e.g. (neo)vim out of the box.
Currently A-left move one word left and the behavior will be more
consistent for people coming GUI world if the key was changed to control
given that both browsers and editors like vscode uses C-left right by
default to move word rather than alt.
A-hl currently is not very consistent with hl when next object is
selected, since it may go up/down or left/right and this behavior is
confusing such that some people think it should swap the keys with A-jk,
so it is better to use A-pn since that only specifies two direction.
A-jk have the same issue as in it usually moves right and is not
consistent with the behavior of jk so people may think A-hl is better,
maybe A-oi is better here since A-hl will be swapped to A-pn, A-oi can
convey the meaning of in and out, similar to some window manager keys?
* Adds tutorial sections for multiple areas including:
- Changing selections to uppercase / lowercase
- yanking and pasting
- macros
- selecting to chars with t and f
PS: I got kind of carried away and put off commiting for a while,
will commit to commit more often in the future.
* Changed section titles to all uppercase
* Added recap and section about jumplist
* Added sections for searching in file, joining lines and indenting lines.
* Removed some trailing whitespace
* Evened out the space between sections to all be 5 lines
* Add section on opening lines (o) and recap
* Changed the amount of lines between sections
This is so that - on a 24 line terminal -
only one section is visible at a time and
page up/page down goes straight to the next
section keeping the header at the top.
* Punctuation error
Co-authored-by: Omnikar <omkar.subramaniam@icloud.com>
* Punctuation error
Co-authored-by: Omnikar <omkar.subramaniam@icloud.com>
* Spelling error
Co-authored-by: Omnikar <omkar.subramaniam@icloud.com>
* Remove unnecessary word
Co-authored-by: Omnikar <omkar.subramaniam@icloud.com>
* Reword note about searches
Co-authored-by: Omnikar <omkar.subramaniam@icloud.com>
* Change word
Co-authored-by: Omnikar <omkar.subramaniam@icloud.com>
* Update tutor file
* Made some small changes suggested by Omnikar
* Added better demo for macros.
* Small changes
- Add newlines at the end
- Make "MACROS" section fit into 22 lines
- Correct mistake of saying helix copied to clipboard in "COPYING AND PASTING TEXT"
* Reformatted notes in copying/pasting section to fit in screen
* Add a note about n and N and their difference to Vim.
* Combine f and t commands into one section.
* Removed t/T section which was merged into the f/F section.
* Merge sections on manipulating case into one.
* Gave section's numbers
* Convert 'press' to 'type' in some places
* Added examples of how prompt lines should look.
* Reformatted notes in copy/pasting section.
* More rewording to more comfortably fit sections on screen.
* Grammatical error.
* Missing periods.
* Missing capital + small reformat
* Fix mis-numbered section
* Reworded to use these conventions when referring to inputs:
- "Press" for single keypresses
- "Type" for multiple keypresses / modifiers
- "Use" when referencing two inputs as a pair.
* till not 'til
* Say 'press' instead of 'type' when referring to symbols
* 'outdent' not 'unindent'
* Typo and grammar.
* Replace all 'press's with 'type's (apart from places it would make no sense in).
* Improve examples for joining and indenting lines.
* Section alignment.
Co-authored-by: Omnikar <omkar.subramaniam@icloud.com>