mirror of
https://github.com/preservim/vim-pencil.git
synced 2025-11-12 03:43:46 -05:00
Reprieve for original HardPencil and SoftPencil commands
PencilHard and PencilSoft benefited from autocomplete when you didn't know the commands, but they are awkward when you do know the commands. So, there's PencilHard and HardPencil. PencilSoft and SoftPencil PencilToggle and TogglePencil PencilOff and NoPencil Additional blacklist adjustment for the plasticboy plugin, though I'll be doing more work in the coming weeks to get things tuned better.
This commit is contained in:
@@ -79,7 +79,7 @@ if !exists('g:pencil#autoformat_blacklist')
|
||||
\ 'mkdRule',
|
||||
\ 'mkdDelimiter',
|
||||
\ 'mkdLink',
|
||||
\ 'mkdNonListItemBlock',
|
||||
\ 'mkdListItem',
|
||||
\ 'mkdIndentCode',
|
||||
\ 'htmlH[0-9]',
|
||||
\ 'markdownFencedCodeBlock',
|
||||
@@ -172,23 +172,23 @@ en
|
||||
|
||||
com -nargs=0 Pencil call pencil#init({'wrap': 'on' })
|
||||
com -nargs=0 PencilOff call pencil#init({'wrap': 'off' })
|
||||
com -nargs=0 NoPencil call pencil#init({'wrap': 'off' })
|
||||
com -nargs=0 HardPencil call pencil#init({'wrap': 'hard'})
|
||||
com -nargs=0 PencilHard call pencil#init({'wrap': 'hard'})
|
||||
com -nargs=0 SoftPencil call pencil#init({'wrap': 'soft'})
|
||||
com -nargs=0 PencilSoft call pencil#init({'wrap': 'soft'})
|
||||
com -nargs=0 PencilToggle call pencil#init({'wrap': 'toggle'})
|
||||
com -nargs=0 TogglePencil call pencil#init({'wrap': 'toggle'})
|
||||
com -nargs=0 PFormat call pencil#setAutoFormat(1)
|
||||
com -nargs=0 PFormatOff call pencil#setAutoFormat(0)
|
||||
com -nargs=0 PFormatToggle call pencil#setAutoFormat(-1)
|
||||
|
||||
" NOTE: legacy commands will be disabled by default at some point
|
||||
" NOTE: legacy commands will be disabled by default on 31-Dec-15
|
||||
if !exists('g:pencil#legacyCommands')
|
||||
let g:pencil#legacyCommands = 1
|
||||
en
|
||||
if g:pencil#legacyCommands
|
||||
com -nargs=0 HardPencil call pencil#init({'wrap': 'hard'})
|
||||
com -nargs=0 SoftPencil call pencil#init({'wrap': 'soft'})
|
||||
com -nargs=0 DropPencil call pencil#init({'wrap': 'off' })
|
||||
com -nargs=0 NoPencil call pencil#init({'wrap': 'off' })
|
||||
com -nargs=0 TogglePencil call pencil#init({'wrap': 'toggle'})
|
||||
com -nargs=0 AutoPencil call pencil#setAutoFormat(1)
|
||||
com -nargs=0 ManualPencil call pencil#setAutoFormat(0)
|
||||
com -nargs=0 ShiftPencil call pencil#setAutoFormat(-1)
|
||||
|
||||
Reference in New Issue
Block a user