| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
Indenting text is a common task in plugins/scripts for
presentation/formatting, yet vim has no way of doing it (especially
"dedent", and especially non-buffer text).
Solution:
Introduce `vim.text.indent()`. It sets the *exact* indentation because
that's a more difficult (and thus more useful) task than merely
"increasing the current indent" (which is somewhat easy with a `gsub()`
one-liner).
|
|
|
| |
Co-authored-by: glepnir <glephunter@gmail.com>
|
|
|
|
|
|
|
|
| |
Lua's string.byte has a maximum (undocumented) allowable length, so
vim.text.hencode fails on large strings with the error "string slice too
long".
Instead of converting the string to an array of bytes up front, convert
each character to a byte one at a time.
|
|
|
|
| |
Instead, return nil plus an error message if the input is invalid.
|
| |
|
|
|
|
|
| |
These non-docstring comments can be included into doxygen's brief
description and then appear in the succeeding function documentation.
|
|
|