aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2019-06-23 23:36:07 +1200
committerTom Ryder <tom@sanctum.geek.nz>2019-06-23 23:36:07 +1200
commit9585a93c306d9309f6c86074d271772627e2b714 (patch)
tree1d0198a308dff449eb259288c4038a42a8a0c421 /doc
parentMerge branch 'release/v0.3.0' into develop (diff)
downloadvim-paste-insert-9585a93c306d9309f6c86074d271772627e2b714.tar.gz
vim-paste-insert-9585a93c306d9309f6c86074d271772627e2b714.zip
Remove the complex remapping attempt
It's more straightforward and probably less buggy just to rely on the user to set keys they haven't mapped. The defaults are sensible enough.
Diffstat (limited to 'doc')
-rw-r--r--doc/paste_insert.txt22
1 files changed, 8 insertions, 14 deletions
diff --git a/doc/paste_insert.txt b/doc/paste_insert.txt
index d9b2bb2..68f1ef9 100644
--- a/doc/paste_insert.txt
+++ b/doc/paste_insert.txt
@@ -2,13 +2,14 @@
DESCRIPTION *paste_insert*
-This small plugin provides a simple "one shot paste" method, with a command or
-mapping to prefix opening an insert, with the 'paste' option automatically set
-after the insert ends, to avoid the annoyances caused by forgetting to do so.
+This plugin implements a method for setting paste mode with the 'paste' option
+for only the duration of the next insert operation, to avoid the hassle of
+forgetting to unset the option after inserting.
It includes a timeout if insert mode isn't entered within 'updatetime'
seconds, or if the user navigates away from the buffer or window. It can also
-be cancelled with keys in normal mode, by default CTRL-C or Escape.
+be cancelled in normal mode with CTRL-C or Escape. These keys can be changed
+if they are already mapped or otherwise unsuitable.
REQUIREMENTS *paste_insert-requirements*
@@ -38,10 +39,9 @@ Set `g:paste_insert_cancel` to a |List| of the special codes for keys you want
to cancel the pending paste in normal mode. `['<C-C>', '<Esc>']` is the
default, for CTRL-C and Escape.
-The plugin will overwrite any existing normal mode maps for these keys during
-the normal mode phase of the operation, but will try to restore them
-afterwards. If you don't want your mappings touched at all, set this to the
-empty list, and the plugin will leave them alone.
+The plugin will complain on starting a paste operation if either of the keys
+are already mapped, globally or locally, so pick keys you never remap, or set
+this option to a blank |List| `[]` to disable it.
CAVEATS *paste_insert-caveats*
@@ -51,12 +51,6 @@ with CTRL-C, the |InsertLeave| event doesn't fire, and you'll still be in
window should fix it. Friends don't let friends use CTRL-C to break insert
mode!
-The map restoration for your chosen cancel keys works well in Vim v7.3.032 or
-newer, but before that patch, recursive maps and flags like <expr> or <silent>
-won't be restored correctly, although <buffer> should still work. If it's
-mangling your mappings and you don't want to change keys, your only option is
-to upgrade Vim.
-
AUTHOR *paste_insert-author*
Written and maintained by Tom Ryder <tom@sanctum.geek.nz>.