aboutsummaryrefslogtreecommitdiff
path: root/runtime
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2021-11-22 15:50:14 +0800
committerzeertzjq <zeertzjq@outlook.com>2021-11-22 15:50:14 +0800
commitd40db0edbdc7058c6096b8a389bee88d162329a9 (patch)
treeea3a5af4faa2b7c343cdf41ab4ca83b04102dcca /runtime
parent64abd7be7993ed3fa031b5d71a4482871108093a (diff)
downloadrneovim-d40db0edbdc7058c6096b8a389bee88d162329a9.tar.gz
rneovim-d40db0edbdc7058c6096b8a389bee88d162329a9.tar.bz2
rneovim-d40db0edbdc7058c6096b8a389bee88d162329a9.zip
vim-patch:8.1.1542: an OptionSet autocommand does not get enough info
Problem: An OptionSet autocommand does not get enough info. Solution: Add v:option_command, v:option_oldlocal and v:option_oldglobal. (Latrice Wilgus, closes vim/vim#4118) https://github.com/vim/vim/commit/d7c968794710f338d491072171df48f96612cf72
Diffstat (limited to 'runtime')
-rw-r--r--runtime/doc/eval.txt21
1 files changed, 20 insertions, 1 deletions
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt
index 58d5d30146..89688b36a7 100644
--- a/runtime/doc/eval.txt
+++ b/runtime/doc/eval.txt
@@ -2042,10 +2042,29 @@ v:option_new New value of the option. Valid while executing an |OptionSet|
autocommand.
*v:option_old*
v:option_old Old value of the option. Valid while executing an |OptionSet|
- autocommand.
+ autocommand. Depending on the command used for setting and the
+ kind of option this is either the local old value or the
+ global old value.
+ *v:option_oldlocal*
+v:option_oldlocal
+ Old local value of the option. Valid while executing an
+ |OptionSet| autocommand.
+ *v:option_oldglobal*
+v:option_oldglobal
+ Old global value of the option. Valid while executing an
+ |OptionSet| autocommand.
*v:option_type*
v:option_type Scope of the set command. Valid while executing an
|OptionSet| autocommand. Can be either "global" or "local"
+ *v:option_command*
+v:option_command
+ Command used to set the option. Valid while executing an
+ |OptionSet| autocommand.
+ value option was set via ~
+ "setlocal" |:setlocal| or ":let l:xxx"
+ "setglobal" |:setglobal| or ":let g:xxx"
+ "set" |:set| or |:let|
+ "modeline" |modeline|
*v:operator* *operator-variable*
v:operator The last operator given in Normal mode. This is a single
character except for commands starting with <g> or <z>,