mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
man.vim: g:man_hardwrap #9633
This option allows restoring the behaviour prior to #9023. Fixes #9583 Closes #9633
This commit is contained in:
parent
ece19b459c
commit
40f5a6c4da
@ -150,8 +150,9 @@ endfunction
|
||||
|
||||
function! s:get_page(path) abort
|
||||
" Disable hard-wrap by using a big $MANWIDTH (max 1000 on some systems #9065).
|
||||
" We use soft wrap: ftplugin/man.vim sets wrap/breakindent/….
|
||||
let manwidth = 999
|
||||
" Soft-wrap: ftplugin/man.vim sets wrap/breakindent/….
|
||||
" Hard-wrap: driven by `man`.
|
||||
let manwidth = !get(g:,'man_hardwrap') ? 999 : (empty($MANWIDTH) ? winwidth(0) : $MANWIDTH)
|
||||
" Force MANPAGER=cat to ensure Vim is not recursively invoked (by man-db).
|
||||
" http://comments.gmane.org/gmane.editors.vim.devel/29085
|
||||
" Set MAN_KEEP_FORMATTING so Debian man doesn't discard backspaces.
|
||||
|
@ -552,6 +552,7 @@ Variables:
|
||||
*b:man_default_sects* Comma-separated, ordered list of preferred sections.
|
||||
For example in C one usually wants section 3 or 2: >
|
||||
:let b:man_default_sections = '3,2'
|
||||
*g:man_hardwrap* Hard-wrap to $MANWIDTH. May improve layout.
|
||||
|
||||
PDF *ft-pdf-plugin*
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user