mirror of
https://github.com/zoriya/vim.git
synced 2025-12-24 16:15:21 +00:00
Compare commits
469 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9f5d600723 | ||
|
|
ac499e3116 | ||
|
|
78b5957439 | ||
|
|
f4258308e2 | ||
|
|
4f2109d782 | ||
|
|
bc41196bdc | ||
|
|
de71b5658f | ||
|
|
525666f282 | ||
|
|
307aa16a69 | ||
|
|
b122e9798e | ||
|
|
69afb7bf0a | ||
|
|
5de820b916 | ||
|
|
efb23f26e8 | ||
|
|
0418811869 | ||
|
|
61602c5bfe | ||
|
|
543b7ef700 | ||
|
|
3737fc1c30 | ||
|
|
75d7a06920 | ||
|
|
36b3a011d3 | ||
|
|
54dafde170 | ||
|
|
4b78063368 | ||
|
|
14f55c6f67 | ||
|
|
99dc19d1cc | ||
|
|
ca982c8d45 | ||
|
|
96c7dfd806 | ||
|
|
b06e20e6ba | ||
|
|
35eacd7180 | ||
|
|
2d5e112284 | ||
|
|
021e147b70 | ||
|
|
f62d942e54 | ||
|
|
16299b57cb | ||
|
|
4b6ebe6dce | ||
|
|
428e987b61 | ||
|
|
fdde880b02 | ||
|
|
fc714b35c6 | ||
|
|
018acca3bd | ||
|
|
305b2fde13 | ||
|
|
8600e40a67 | ||
|
|
bcb40977c3 | ||
|
|
494ff7e850 | ||
|
|
355fd9b468 | ||
|
|
78cddbe271 | ||
|
|
a9922d62e6 | ||
|
|
a5b725c3f6 | ||
|
|
1a3b56953e | ||
|
|
a1544c00c8 | ||
|
|
01a7a720ad | ||
|
|
9bb77d6fe6 | ||
|
|
bad704fa04 | ||
|
|
7e28384a9a | ||
|
|
07b8864111 | ||
|
|
1bcabe19a2 | ||
|
|
a03e631120 | ||
|
|
c8366790e8 | ||
|
|
c37b6ecd60 | ||
|
|
b38caae26c | ||
|
|
dd8aca664d | ||
|
|
432b09c84d | ||
|
|
21642ed1b4 | ||
|
|
9e822c00b1 | ||
|
|
3e734ea2c7 | ||
|
|
e9ba516be2 | ||
|
|
1bc2428e1f | ||
|
|
0014a53ad1 | ||
|
|
423532e10d | ||
|
|
28c2191949 | ||
|
|
75eb1610e1 | ||
|
|
f9e56b2b03 | ||
|
|
4ac6676cee | ||
|
|
51a2983904 | ||
|
|
5714b80032 | ||
|
|
e0fea9c405 | ||
|
|
eb3ecae23a | ||
|
|
2cb8feb880 | ||
|
|
26c2f3fc4e | ||
|
|
963fee2d69 | ||
|
|
c4912e555b | ||
|
|
e23febdb85 | ||
|
|
61db8b5108 | ||
|
|
57a285b105 | ||
|
|
3451d66244 | ||
|
|
7cd4d9c17c | ||
|
|
3f1682e808 | ||
|
|
fdb6dc1105 | ||
|
|
47196581b8 | ||
|
|
aae4883e01 | ||
|
|
4b41706477 | ||
|
|
f47ca63dbc | ||
|
|
56d58d51bf | ||
|
|
152e7890c1 | ||
|
|
d6c11cb3e0 | ||
|
|
fad8de084a | ||
|
|
3c577f26cd | ||
|
|
1d814754c0 | ||
|
|
425154d888 | ||
|
|
02e26d9807 | ||
|
|
a03dbed9e9 | ||
|
|
307d10a2fb | ||
|
|
35b2386a8e | ||
|
|
c96ebe75e5 | ||
|
|
2a0f3d3fb2 | ||
|
|
0b9aecc3a5 | ||
|
|
673af4d304 | ||
|
|
2eec59e30b | ||
|
|
f878bf0da2 | ||
|
|
e6ae6225b4 | ||
|
|
774267bbb9 | ||
|
|
a7b64ce74e | ||
|
|
cac867ad18 | ||
|
|
1dc28783fa | ||
|
|
182dc4f2ab | ||
|
|
e64faa6645 | ||
|
|
d6e391862c | ||
|
|
b52f4c02e6 | ||
|
|
b09d983c78 | ||
|
|
12e4014092 | ||
|
|
66e83d7db0 | ||
|
|
d2470e9fbe | ||
|
|
d7a06b1d71 | ||
|
|
8dd7901a66 | ||
|
|
9bad29decf | ||
|
|
080504921d | ||
|
|
0fabe3fdbe | ||
|
|
09ea9fcf3f | ||
|
|
745fc029ba | ||
|
|
e3c7b86aab | ||
|
|
7fcff1f781 | ||
|
|
ca12d7c004 | ||
|
|
053bb60f44 | ||
|
|
bc0ea8f75e | ||
|
|
10f3a79e89 | ||
|
|
ba40447ab1 | ||
|
|
097c992c46 | ||
|
|
884f6e44e0 | ||
|
|
fbc0d2ea1e | ||
|
|
6fa41fb374 | ||
|
|
7533fddd09 | ||
|
|
9e74e30b5f | ||
|
|
ad3b366c82 | ||
|
|
d620aa9be4 | ||
|
|
cfef5ff23e | ||
|
|
cabf80ff2f | ||
|
|
105bc355a6 | ||
|
|
55b8ad3dab | ||
|
|
c24c1acd82 | ||
|
|
07729b25bf | ||
|
|
54e8f00581 | ||
|
|
2cd7362e30 | ||
|
|
3dab2806fe | ||
|
|
71700b8903 | ||
|
|
a4720019cf | ||
|
|
b983f75d22 | ||
|
|
d5f729cada | ||
|
|
e761459eb6 | ||
|
|
8661b17843 | ||
|
|
4d188da22b | ||
|
|
5e538ecd5e | ||
|
|
03db85b398 | ||
|
|
b6c589a529 | ||
|
|
46a7561f3a | ||
|
|
dfa38d4e45 | ||
|
|
29607acff6 | ||
|
|
bd80f35bc5 | ||
|
|
8f1723de47 | ||
|
|
3d0c52db9c | ||
|
|
4e5dfb5700 | ||
|
|
99add41656 | ||
|
|
6d21645f46 | ||
|
|
971db46799 | ||
|
|
3b9abb6cc2 | ||
|
|
76a86063ca | ||
|
|
82e803b055 | ||
|
|
99685e6a7e | ||
|
|
6800186a03 | ||
|
|
09bb33dde9 | ||
|
|
290424868d | ||
|
|
51ac8a27e5 | ||
|
|
161fb5e302 | ||
|
|
531da5955e | ||
|
|
229f8dbf7a | ||
|
|
49e649fc2e | ||
|
|
84a05acc8c | ||
|
|
84e0f6ca9a | ||
|
|
d1864597a0 | ||
|
|
8fadd8b840 | ||
|
|
29f49ee8d7 | ||
|
|
4e0d974645 | ||
|
|
02938a970c | ||
|
|
ff0341946e | ||
|
|
7afea82f50 | ||
|
|
811fe63f39 | ||
|
|
567199b68f | ||
|
|
e8d9530b0e | ||
|
|
2ab0713279 | ||
|
|
f687cf3f36 | ||
|
|
ec38d6932c | ||
|
|
230bb3f09d | ||
|
|
335e0b6974 | ||
|
|
4d1da49cfe | ||
|
|
7a26dd860a | ||
|
|
af6abb9d93 | ||
|
|
3f99152276 | ||
|
|
b70a473e24 | ||
|
|
3bb28557e1 | ||
|
|
a8565fecc6 | ||
|
|
4c7e9db0d6 | ||
|
|
687a29c5e2 | ||
|
|
f6dcbb245b | ||
|
|
f8de161090 | ||
|
|
54c34fa6f5 | ||
|
|
768baacdc8 | ||
|
|
b376647bb1 | ||
|
|
332ac0621c | ||
|
|
84b0493c34 | ||
|
|
429fa85392 | ||
|
|
07219f911c | ||
|
|
6f852a557d | ||
|
|
7311c6932c | ||
|
|
0bcdd6e709 | ||
|
|
0187ca0bdf | ||
|
|
38ec50bea8 | ||
|
|
e3e6e573d1 | ||
|
|
8185111125 | ||
|
|
644cf03b7e | ||
|
|
126bdeeabe | ||
|
|
2a66a07b29 | ||
|
|
25a6df90df | ||
|
|
bf88493c09 | ||
|
|
68879258d9 | ||
|
|
24b11fb173 | ||
|
|
b3049f4a34 | ||
|
|
d7fbfe107d | ||
|
|
91fc43d3f9 | ||
|
|
7bcb30e913 | ||
|
|
cdffbeae2b | ||
|
|
95a5135118 | ||
|
|
d0e2d94589 | ||
|
|
c2c355df6f | ||
|
|
71afbfe6cd | ||
|
|
db333a5b8d | ||
|
|
af62ff3696 | ||
|
|
0c279bbb9c | ||
|
|
b59494cab1 | ||
|
|
186628f671 | ||
|
|
090cfc1b02 | ||
|
|
ac7bd63844 | ||
|
|
b897871ce9 | ||
|
|
a5be25e1db | ||
|
|
e533bbe094 | ||
|
|
2526ef276b | ||
|
|
20754027b3 | ||
|
|
1e284f5155 | ||
|
|
9584b31aae | ||
|
|
a390bb6ad3 | ||
|
|
4f8301f641 | ||
|
|
1a0316ca2a | ||
|
|
b3cb982162 | ||
|
|
3978e08fbe | ||
|
|
db813951c4 | ||
|
|
e2e663f67d | ||
|
|
210f3704f7 | ||
|
|
60abe75379 | ||
|
|
c389fd3a49 | ||
|
|
db3fbe5228 | ||
|
|
4e3c70d241 | ||
|
|
84e80b51d1 | ||
|
|
d999db2f1e | ||
|
|
34700a6a15 | ||
|
|
7534221eba | ||
|
|
b8f8461d94 | ||
|
|
988232fabb | ||
|
|
e17c260335 | ||
|
|
f5e44a7e90 | ||
|
|
e468e266c4 | ||
|
|
fdf447b286 | ||
|
|
f13f45d59b | ||
|
|
693e40c2cd | ||
|
|
53eb37e9f9 | ||
|
|
886ed691d2 | ||
|
|
40cf4b44ed | ||
|
|
5c9626301b | ||
|
|
26402cb2de | ||
|
|
63dbda1caa | ||
|
|
558ddad8e8 | ||
|
|
187d3acb7f | ||
|
|
8738fc1be8 | ||
|
|
995a8cd181 | ||
|
|
445f3037ea | ||
|
|
4d36987c25 | ||
|
|
2142e5d851 | ||
|
|
452ff5bdc7 | ||
|
|
6d47df7ca0 | ||
|
|
5004e8846e | ||
|
|
feeaa688eb | ||
|
|
b2c5a5ac79 | ||
|
|
707060e2ee | ||
|
|
caca92be8a | ||
|
|
f6ecd99cec | ||
|
|
af9aeb9250 | ||
|
|
c2149ea7cd | ||
|
|
ffeedec023 | ||
|
|
a3914327f7 | ||
|
|
00154508de | ||
|
|
8fe8d9ed06 | ||
|
|
be9c627666 | ||
|
|
f4e5e86627 | ||
|
|
181ace28ed | ||
|
|
76d711c3b5 | ||
|
|
51971b3398 | ||
|
|
e9d47cd08b | ||
|
|
07e1da6bbd | ||
|
|
fffcfea984 | ||
|
|
11cb6e6e13 | ||
|
|
fa13eef3c9 | ||
|
|
309379fc98 | ||
|
|
530e7dfafd | ||
|
|
b6a76ffc4c | ||
|
|
9c2e6cc6ed | ||
|
|
39d7d51bcd | ||
|
|
04e5b5a228 | ||
|
|
e337e5f634 | ||
|
|
d214221375 | ||
|
|
a50e5866b0 | ||
|
|
8ceb1735a2 | ||
|
|
4bc8cf0e7c | ||
|
|
7567646f13 | ||
|
|
a3e6bc93d1 | ||
|
|
52f85b730e | ||
|
|
f813a1883f | ||
|
|
8d61617238 | ||
|
|
700e7345de | ||
|
|
02366255c9 | ||
|
|
2f315ab7be | ||
|
|
826763f87b | ||
|
|
15364d74ca | ||
|
|
0f2721223e | ||
|
|
4593396625 | ||
|
|
d35d784e91 | ||
|
|
55b7b7eeb5 | ||
|
|
94a8adfdd8 | ||
|
|
3be71ce28d | ||
|
|
9d182dd0a6 | ||
|
|
4da70dbc4d | ||
|
|
f939c4e6b1 | ||
|
|
b5f7bf6ed9 | ||
|
|
8c4fbd1a15 | ||
|
|
0936502538 | ||
|
|
08ed30eca7 | ||
|
|
8c7694a864 | ||
|
|
3e37fd0950 | ||
|
|
8fae8e658f | ||
|
|
117f2c4b91 | ||
|
|
802418d5eb | ||
|
|
c4fba6f881 | ||
|
|
8754deb3b6 | ||
|
|
14e28811b3 | ||
|
|
ba6e858556 | ||
|
|
83dadafdd7 | ||
|
|
4b166d0a6d | ||
|
|
cfde76c74d | ||
|
|
27356ad4f4 | ||
|
|
321a9ec680 | ||
|
|
09ba6d766b | ||
|
|
52cc266dae | ||
|
|
21691f896a | ||
|
|
34feacbcce | ||
|
|
32c8f1cb19 | ||
|
|
60ec5f35a5 | ||
|
|
57e4ee4d38 | ||
|
|
a54bf40017 | ||
|
|
9750bb199e | ||
|
|
0f9d0869c7 | ||
|
|
81484f4215 | ||
|
|
15d55dec03 | ||
|
|
862cfa356d | ||
|
|
2a94225c23 | ||
|
|
f135435f80 | ||
|
|
2e18a12780 | ||
|
|
97d4ea71d6 | ||
|
|
f4f1956724 | ||
|
|
2df58b4a58 | ||
|
|
9411615985 | ||
|
|
d4ad0d4e21 | ||
|
|
b347963869 | ||
|
|
dd53a41553 | ||
|
|
442b5c48fd | ||
|
|
8866d277c9 | ||
|
|
02e14d67b9 | ||
|
|
7854e3abcf | ||
|
|
c83a44bf8f | ||
|
|
ff8cf2be66 | ||
|
|
fe9fb927ae | ||
|
|
7331304fd3 | ||
|
|
ef6585abef | ||
|
|
77642c0fef | ||
|
|
65d7396cb4 | ||
|
|
8d4eecc5e8 | ||
|
|
d59762dcb6 | ||
|
|
c0d4759373 | ||
|
|
7c5f120410 | ||
|
|
8288149866 | ||
|
|
0ac24e1ef4 | ||
|
|
b031626427 | ||
|
|
99a547d3a1 | ||
|
|
97d62497f5 | ||
|
|
41b884b273 | ||
|
|
b826ddb034 | ||
|
|
3ab72c5c72 | ||
|
|
e3a2246227 | ||
|
|
9c9cbf1351 | ||
|
|
12a753a5ca | ||
|
|
95e09eaaad | ||
|
|
a80888d296 | ||
|
|
17aa8cc255 | ||
|
|
a9a2d8f4d0 | ||
|
|
707cfb82dc | ||
|
|
f00dc2627b | ||
|
|
e8d8fd2add | ||
|
|
3a0d8090b1 | ||
|
|
67a4f6cfb4 | ||
|
|
faca84059a | ||
|
|
cfb807026f | ||
|
|
bffa06ddb8 | ||
|
|
003d14a267 | ||
|
|
c4b98fbb3e | ||
|
|
f3408e76fb | ||
|
|
b6101cf77f | ||
|
|
2d17fa3ebd | ||
|
|
9f340fa57b | ||
|
|
205f9f5e2d | ||
|
|
b88adbf844 | ||
|
|
dac7569612 | ||
|
|
d04da7cb4a | ||
|
|
7bc4f93c07 | ||
|
|
172ddb60c2 | ||
|
|
b73568149f | ||
|
|
0c17875ef3 | ||
|
|
b35c338f96 | ||
|
|
0c5fa7d740 | ||
|
|
d1f13fd597 | ||
|
|
4ccb265bd4 | ||
|
|
7d11244c99 | ||
|
|
97cc2384c0 | ||
|
|
14f5827940 | ||
|
|
8139889a5f | ||
|
|
6f3d6b48a6 | ||
|
|
e1704bada4 | ||
|
|
b213da0b57 | ||
|
|
ec3cfeb199 | ||
|
|
1e91f2606b | ||
|
|
718f007499 | ||
|
|
d09acef44b | ||
|
|
66b7985ec9 | ||
|
|
770456589e | ||
|
|
696c2116dc | ||
|
|
f94a13c286 | ||
|
|
01c10524d2 | ||
|
|
f5fe79a5f3 | ||
|
|
6f586de755 | ||
|
|
2b017fae8f | ||
|
|
4fabd7dd4a | ||
|
|
be1e9e9fc1 | ||
|
|
2623b4f412 | ||
|
|
e8cdcef875 | ||
|
|
fca93c093e | ||
|
|
c11073c9aa | ||
|
|
afa6b9af86 | ||
|
|
cdab905136 | ||
|
|
77fceb8908 |
2
.gitignore
vendored
2
.gitignore
vendored
@@ -30,6 +30,7 @@ src/auto/pathdef.c
|
||||
*.suo
|
||||
*.res
|
||||
*.RES
|
||||
src/if_perl.c
|
||||
src/pathdef.c
|
||||
src/Obj*/pathdef.c
|
||||
gvimext.dll
|
||||
@@ -41,6 +42,7 @@ gvimext.lib
|
||||
*.mo
|
||||
*.swp
|
||||
*~
|
||||
src/po/vim.pot
|
||||
|
||||
# Generated by "make test"
|
||||
src/po/*.ck
|
||||
|
||||
18
Filelist
18
Filelist
@@ -57,6 +57,7 @@ SRC_ALL = \
|
||||
src/popupmnu.c \
|
||||
src/quickfix.c \
|
||||
src/regexp.c \
|
||||
src/regexp_nfa.c \
|
||||
src/regexp.h \
|
||||
src/screen.c \
|
||||
src/search.c \
|
||||
@@ -73,6 +74,7 @@ SRC_ALL = \
|
||||
src/version.c \
|
||||
src/version.h \
|
||||
src/vim.h \
|
||||
src/winclip.c \
|
||||
src/window.c \
|
||||
src/xxd/xxd.c \
|
||||
src/main.aap \
|
||||
@@ -130,6 +132,7 @@ SRC_ALL = \
|
||||
src/proto/ui.pro \
|
||||
src/proto/undo.pro \
|
||||
src/proto/version.pro \
|
||||
src/proto/winclip.pro \
|
||||
src/proto/window.pro \
|
||||
|
||||
|
||||
@@ -261,6 +264,7 @@ SRC_DOS = \
|
||||
src/Make_mvc.mak \
|
||||
src/Make_w16.mak \
|
||||
src/bigvim.bat \
|
||||
src/bigvim64.bat \
|
||||
src/msvcsetup.bat \
|
||||
src/msvc2008.bat \
|
||||
src/msvc2010.bat \
|
||||
@@ -352,6 +356,7 @@ SRC_DOS_BIN = \
|
||||
src/xpm/COPYRIGHT \
|
||||
src/xpm/README.txt \
|
||||
src/xpm/include/*.h \
|
||||
src/xpm/x64/lib/libXpm.a \
|
||||
src/xpm/x64/lib/libXpm.lib \
|
||||
src/xpm/x86/lib/libXpm.a \
|
||||
src/xpm/x86/lib/libXpm.lib \
|
||||
@@ -442,6 +447,7 @@ SRC_EXTRA = \
|
||||
src/os_beos.c \
|
||||
src/os_beos.h \
|
||||
src/os_beos.rsrc \
|
||||
src/proto/os_beos.pro \
|
||||
src/os_mint.h \
|
||||
src/os_vms_fix.com \
|
||||
src/toolbar.phi \
|
||||
@@ -691,9 +697,17 @@ LANG_GEN = \
|
||||
runtime/tutor/Makefile \
|
||||
runtime/tutor/tutor.utf-8 \
|
||||
runtime/tutor/tutor.?? \
|
||||
runtime/tutor/tutor.??.* \
|
||||
runtime/tutor/tutor.??.utf-8 \
|
||||
runtime/tutor/tutor.??.euc \
|
||||
runtime/tutor/tutor.??.sjis \
|
||||
runtime/tutor/tutor.??.iso9 \
|
||||
runtime/tutor/tutor.??.big5 \
|
||||
runtime/tutor/tutor.??.cp1250 \
|
||||
runtime/tutor/tutor.??.cp1251 \
|
||||
runtime/tutor/tutor.??.cp737 \
|
||||
runtime/tutor/tutor.??_??.utf-8 \
|
||||
runtime/tutor/tutor.bar \
|
||||
runtime/tutor/tutor.bar.* \
|
||||
runtime/tutor/tutor.bar.utf-8 \
|
||||
runtime/spell/README.txt \
|
||||
runtime/spell/??/*.diff \
|
||||
runtime/spell/??/main.aap \
|
||||
|
||||
@@ -97,10 +97,12 @@ The latest news about Vim can be found on the Vim home page:
|
||||
If you have problems, have a look at the Vim FAQ:
|
||||
http://vimdoc.sf.net/vimfaq.html
|
||||
|
||||
Send bug reports to:
|
||||
Bram Moolenaar <Bram@vim.org>
|
||||
If you still have problems or any other questions, use one of the mailing
|
||||
lists to discuss them with Vim users and developers:
|
||||
http://www.vim.org/maillist.php
|
||||
|
||||
There are several mailing lists for Vim, see http://www.vim.org/maillist.php.
|
||||
If nothing else works, report bugs directly:
|
||||
Bram Moolenaar <Bram@vim.org>
|
||||
|
||||
|
||||
MAIN AUTHOR
|
||||
|
||||
20
runtime/autoload/clojurecomplete.vim
Normal file
20
runtime/autoload/clojurecomplete.vim
Normal file
File diff suppressed because one or more lines are too long
@@ -1,8 +1,8 @@
|
||||
" ---------------------------------------------------------------------
|
||||
" getscript.vim
|
||||
" Author: Charles E. Campbell, Jr.
|
||||
" Date: Jan 17, 2012
|
||||
" Version: 34
|
||||
" Author: Charles E. Campbell
|
||||
" Date: Apr 17, 2013
|
||||
" Version: 35
|
||||
" Installing: :help glvs-install
|
||||
" Usage: :help glvs
|
||||
"
|
||||
@@ -15,7 +15,7 @@
|
||||
if exists("g:loaded_getscript")
|
||||
finish
|
||||
endif
|
||||
let g:loaded_getscript= "v34"
|
||||
let g:loaded_getscript= "v35"
|
||||
if &cp
|
||||
echoerr "GetLatestVimScripts is not vi-compatible; not loaded (you need to set nocp)"
|
||||
finish
|
||||
@@ -74,6 +74,11 @@ if !exists("g:GetLatestVimScripts_allowautoinstall")
|
||||
let g:GetLatestVimScripts_allowautoinstall= 1
|
||||
endif
|
||||
|
||||
" set up default scriptaddr address
|
||||
if !exists("g:GetLatestVimScripts_scriptaddr")
|
||||
let g:GetLatestVimScripts_scriptaddr = 'http://vim.sourceforge.net/script.php?script_id='
|
||||
endif
|
||||
|
||||
"" For debugging:
|
||||
"let g:GetLatestVimScripts_wget = "echo"
|
||||
"let g:GetLatestVimScripts_options = "options"
|
||||
@@ -314,7 +319,7 @@ fun! getscript#GetLatestVimScripts()
|
||||
if &mod
|
||||
silent! w!
|
||||
endif
|
||||
q
|
||||
q!
|
||||
|
||||
" restore events and current directory
|
||||
exe "cd ".fnameescape(substitute(origdir,'\','/','ge'))
|
||||
@@ -415,7 +420,7 @@ fun! s:GetOneScript(...)
|
||||
echo 'considering <'.aicmmnt.'> scriptid='.scriptid.' srcid='.srcid
|
||||
|
||||
" grab a copy of the plugin's vim.sourceforge.net webpage
|
||||
let scriptaddr = 'http://vim.sourceforge.net/script.php?script_id='.scriptid
|
||||
let scriptaddr = g:GetLatestVimScripts_scriptaddr.scriptid
|
||||
let tmpfile = tempname()
|
||||
let v:errmsg = ""
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,9 +1,9 @@
|
||||
" netrwFileHandlers: contains various extension-based file handlers for
|
||||
" netrw's browsers' x command ("eXecute launcher")
|
||||
" Author: Charles E. Campbell, Jr.
|
||||
" Date: Mar 14, 2012
|
||||
" Version: 11a
|
||||
" Copyright: Copyright (C) 1999-2012 Charles E. Campbell, Jr. {{{1
|
||||
" Author: Charles E. Campbell
|
||||
" Date: May 03, 2013
|
||||
" Version: 11b ASTRO-ONLY
|
||||
" Copyright: Copyright (C) 1999-2012 Charles E. Campbell {{{1
|
||||
" Permission is hereby granted to use and distribute this code,
|
||||
" with or without modifications, provided that this copyright
|
||||
" notice is copied with it. Like anything else that's free,
|
||||
@@ -20,7 +20,7 @@
|
||||
if exists("g:loaded_netrwFileHandlers") || &cp
|
||||
finish
|
||||
endif
|
||||
let g:loaded_netrwFileHandlers= "v11a"
|
||||
let g:loaded_netrwFileHandlers= "v11b"
|
||||
if v:version < 702
|
||||
echohl WarningMsg
|
||||
echo "***warning*** this version of netrwFileHandlers needs vim 7.2"
|
||||
@@ -34,10 +34,10 @@ set cpo&vim
|
||||
" netrwFileHandlers#Invoke: {{{1
|
||||
fun! netrwFileHandlers#Invoke(exten,fname)
|
||||
" call Dfunc("netrwFileHandlers#Invoke(exten<".a:exten."> fname<".a:fname.">)")
|
||||
let fname= a:fname
|
||||
let exten= a:exten
|
||||
" list of supported special characters. Consider rcs,v --- that can be
|
||||
" supported with a NFH_rcsCOMMAv() handler
|
||||
if a:fname =~ '[@:,$!=\-+%?;~]'
|
||||
if exten =~ '[@:,$!=\-+%?;~]'
|
||||
let specials= {
|
||||
\ '@' : 'AT',
|
||||
\ ':' : 'COLON',
|
||||
@@ -51,18 +51,18 @@ fun! netrwFileHandlers#Invoke(exten,fname)
|
||||
\ '?' : 'QUESTION',
|
||||
\ ';' : 'SEMICOLON',
|
||||
\ '~' : 'TILDE'}
|
||||
let fname= substitute(a:fname,'[@:,$!=\-+%?;~]','\=specials[submatch(0)]','ge')
|
||||
let exten= substitute(a:exten,'[@:,$!=\-+%?;~]','\=specials[submatch(0)]','ge')
|
||||
" call Decho('fname<'.fname.'> done with dictionary')
|
||||
endif
|
||||
|
||||
if a:exten != "" && exists("*NFH_".a:exten)
|
||||
if a:exten != "" && exists("*NFH_".exten)
|
||||
" support user NFH_*() functions
|
||||
" call Decho("let ret= netrwFileHandlers#NFH_".a:exten.'("'.fname.'")')
|
||||
exe "let ret= NFH_".a:exten.'("'.fname.'")'
|
||||
elseif a:exten != "" && exists("*s:NFH_".a:exten)
|
||||
exe "let ret= NFH_".exten.'("'.a:fname.'")'
|
||||
elseif a:exten != "" && exists("*s:NFH_".exten)
|
||||
" use builtin-NFH_*() functions
|
||||
" call Decho("let ret= netrwFileHandlers#NFH_".a:exten.'("'.fname.'")')
|
||||
exe "let ret= s:NFH_".a:exten.'("'.fname.'")'
|
||||
exe "let ret= s:NFH_".a:exten.'("'.a:fname.'")'
|
||||
endif
|
||||
|
||||
" call Dret("netrwFileHandlers#Invoke 0 : ret=".ret)
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
" netrwSettings.vim: makes netrw settings simpler
|
||||
" Date: Sep 03, 2008
|
||||
" Maintainer: Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
|
||||
" Version: 13
|
||||
" Copyright: Copyright (C) 1999-2007 Charles E. Campbell, Jr. {{{1
|
||||
" Date: May 03, 2013
|
||||
" Maintainer: Charles E Campbell <drchipNOSPAM at campbellfamily dot biz>
|
||||
" Version: 14a ASTRO-ONLY
|
||||
" Copyright: Copyright (C) 1999-2007 Charles E. Campbell {{{1
|
||||
" Permission is hereby granted to use and distribute this code,
|
||||
" with or without modifications, provided that this copyright
|
||||
" notice is copied with it. Like anything else that's free,
|
||||
@@ -19,7 +19,7 @@
|
||||
if exists("g:loaded_netrwSettings") || &cp
|
||||
finish
|
||||
endif
|
||||
let g:loaded_netrwSettings = "v13"
|
||||
let g:loaded_netrwSettings = "v14a"
|
||||
if v:version < 700
|
||||
echohl WarningMsg
|
||||
echo "***warning*** this version of netrwSettings needs vim 7.0"
|
||||
@@ -63,7 +63,7 @@ fun! netrwSettings#NetrwSettings()
|
||||
endif
|
||||
|
||||
put ='+ ---------------------------------------------'
|
||||
put ='+ NetrwSettings: by Charles E. Campbell, Jr.'
|
||||
put ='+ NetrwSettings: by Charles E. Campbell'
|
||||
put ='+ Press <F1> with cursor atop any line for help'
|
||||
put ='+ ---------------------------------------------'
|
||||
let s:netrw_settings_stop= line(".")
|
||||
@@ -88,6 +88,7 @@ fun! netrwSettings#NetrwSettings()
|
||||
put = 'let g:netrw_ftpmode = '.g:netrw_ftpmode
|
||||
put = 'let g:netrw_ignorenetrc = '.g:netrw_ignorenetrc
|
||||
put = 'let g:netrw_sshport = '.g:netrw_sshport
|
||||
put = 'let g:netrw_silent = '.g:netrw_silent
|
||||
put = 'let g:netrw_use_nt_rcp = '.g:netrw_use_nt_rcp
|
||||
put = 'let g:netrw_win95ftp = '.g:netrw_win95ftp
|
||||
let s:netrw_xfer_stop= line(".")
|
||||
@@ -99,51 +100,81 @@ fun! netrwSettings#NetrwSettings()
|
||||
put ='+ Netrw Browser Control'
|
||||
put = 'let g:netrw_alto = '.g:netrw_alto
|
||||
put = 'let g:netrw_altv = '.g:netrw_altv
|
||||
put = 'let g:netrw_banner = '.g:netrw_banner
|
||||
if exists("g:netrw_bannerbackslash")
|
||||
put = 'let g:netrw_bannerbackslash = '.g:netrw_bannerbackslash
|
||||
else
|
||||
put = '\" let g:netrw_bannerbackslash = (not defined)'
|
||||
endif
|
||||
put = 'let g:netrw_browse_split = '.g:netrw_browse_split
|
||||
if exists("g:netrw_browsex_viewer")
|
||||
put = 'let g:netrw_browsex_viewer = '.g:netrw_browsex_viewer
|
||||
put = 'let g:netrw_browsex_viewer = '.g:netrw_browsex_viewer
|
||||
else
|
||||
put = 'let g:netrw_browsex_viewer = (not defined)'
|
||||
put = '\" let g:netrw_browsex_viewer = (not defined)'
|
||||
endif
|
||||
put = 'let g:netrw_compress = '.g:netrw_compress
|
||||
put = 'let g:netrw_cursorline = '.g:netrw_cursorline
|
||||
if exists("g:Netrw_corehandler")
|
||||
put = 'let g:Netrw_corehandler = '.g:Netrw_corehandler
|
||||
else
|
||||
put = '\" let g:Netrw_corehandler = (not defined)'
|
||||
endif
|
||||
put = 'let g:netrw_ctags = '.g:netrw_ctags
|
||||
put = 'let g:netrw_cursor = '.g:netrw_cursor
|
||||
let decompressline= line("$")
|
||||
put ='let g:netrw_decompress...'
|
||||
put = 'let g:netrw_decompress = '.string(g:netrw_decompress)
|
||||
if exists("g:netrw_dynamic_maxfilenamelen")
|
||||
put = 'let g:netrw_dynamic_maxfilenamelen='.g:netrw_dynamic_maxfilenamelen
|
||||
else
|
||||
put = '\" let g:netrw_dynamic_maxfilenamelen= (not defined)'
|
||||
endif
|
||||
put = 'let g:netrw_dirhistmax = '.g:netrw_dirhistmax
|
||||
put = 'let g:netrw_errorlvl = '.g:netrw_errorlvl
|
||||
put = 'let g:netrw_fastbrowse = '.g:netrw_fastbrowse
|
||||
let fnameescline= line("$")
|
||||
put = 'let g:netrw_fname_escape...'
|
||||
put = 'let g:netrw_fname_escape = '.string(g:netrw_fname_escape)
|
||||
put = 'let g:netrw_ftp_browse_reject = '.g:netrw_ftp_browse_reject
|
||||
put = 'let g:netrw_ftp_list_cmd = '.g:netrw_ftp_list_cmd
|
||||
put = 'let g:netrw_ftp_sizelist_cmd = '.g:netrw_ftp_sizelist_cmd
|
||||
put = 'let g:netrw_ftp_timelist_cmd = '.g:netrw_ftp_timelist_cmd
|
||||
let globescline= line("$")
|
||||
put ='let g:netrw_glob_escape...'
|
||||
put = 'let g:netrw_glob_escape = '.string(g:netrw_glob_escape)
|
||||
put = 'let g:netrw_hide = '.g:netrw_hide
|
||||
if exists("g:netrw_home")
|
||||
put = 'let g:netrw_home = '.g:netrw_home
|
||||
else
|
||||
put = '\" let g:netrw_home = (not defined)'
|
||||
endif
|
||||
put = 'let g:netrw_keepdir = '.g:netrw_keepdir
|
||||
put = 'let g:netrw_list_cmd = '.g:netrw_list_cmd
|
||||
put = 'let g:netrw_list_hide = '.g:netrw_list_hide
|
||||
put = 'let g:netrw_liststyle = '.g:netrw_liststyle
|
||||
put = 'let g:netrw_localcopycmd = '.g:netrw_localcopycmd
|
||||
put = 'let g:netrw_local_mkdir = '.g:netrw_local_mkdir
|
||||
put = 'let g:netrw_localmkdir = '.g:netrw_localmkdir
|
||||
put = 'let g:netrw_localmovecmd = '.g:netrw_localmovecmd
|
||||
put = 'let g:netrw_local_rmdir = '.g:netrw_local_rmdir
|
||||
put = 'let g:netrw_localrmdir = '.g:netrw_localrmdir
|
||||
put = 'let g:netrw_maxfilenamelen = '.g:netrw_maxfilenamelen
|
||||
put = 'let g:netrw_menu = '.g:netrw_menu
|
||||
put = 'let g:netrw_mousemaps = '.g:netrw_mousemaps
|
||||
put = 'let g:netrw_mkdir_cmd = '.g:netrw_mkdir_cmd
|
||||
if exists("g:netrw_nobeval")
|
||||
put = 'let g:netrw_nobeval = '.g:netrw_nobeval
|
||||
else
|
||||
put = '\" let g:netrw_nobeval = (not defined)'
|
||||
endif
|
||||
put = 'let g:netrw_remote_mkdir = '.g:netrw_remote_mkdir
|
||||
put = 'let g:netrw_preview = '.g:netrw_preview
|
||||
put = 'let g:netrw_rename_cmd = '.g:netrw_rename_cmd
|
||||
put = 'let g:netrw_retmap = '.g:netrw_retmap
|
||||
put = 'let g:netrw_rm_cmd = '.g:netrw_rm_cmd
|
||||
put = 'let g:netrw_rmdir_cmd = '.g:netrw_rmdir_cmd
|
||||
put = 'let g:netrw_rmf_cmd = '.g:netrw_rmf_cmd
|
||||
put = 'let g:netrw_silent = '.g:netrw_silent
|
||||
put = 'let g:netrw_sort_by = '.g:netrw_sort_by
|
||||
put = 'let g:netrw_sort_direction = '.g:netrw_sort_direction
|
||||
put = 'let g:netrw_sort_options = '.g:netrw_sort_options
|
||||
put = 'let g:netrw_sort_sequence = '.g:netrw_sort_sequence
|
||||
put = 'let g:netrw_special_syntax = '.g:netrw_special_syntax
|
||||
put = 'let g:netrw_ssh_browse_reject = '.g:netrw_ssh_browse_reject
|
||||
put = 'let g:netrw_ssh_cmd = '.g:netrw_ssh_cmd
|
||||
put = 'let g:netrw_scpport = '.g:netrw_scpport
|
||||
put = 'let g:netrw_sepchr = '.g:netrw_sepchr
|
||||
put = 'let g:netrw_sshport = '.g:netrw_sshport
|
||||
|
||||
@@ -1,23 +1,55 @@
|
||||
" Vim OMNI completion script for SQL
|
||||
" Language: SQL
|
||||
" Maintainer: David Fishburn <dfishburn dot vim at gmail dot com>
|
||||
" Version: 12.0
|
||||
" Last Change: 2012 Feb 08
|
||||
" Version: 15.0
|
||||
" Last Change: 2013 May 13
|
||||
" Homepage: http://www.vim.org/scripts/script.php?script_id=1572
|
||||
" Usage: For detailed help
|
||||
" ":help sql.txt"
|
||||
" or ":help ft-sql-omni"
|
||||
" or read $VIMRUNTIME/doc/sql.txt
|
||||
|
||||
" History
|
||||
" Version 12.0
|
||||
"
|
||||
" TODO
|
||||
" - Jonas Enberg - if no table is found when using column completion
|
||||
" look backwards to a FROM clause and find the first table
|
||||
" and complete it.
|
||||
"
|
||||
" Version 15.0 (May 2013)
|
||||
" - NF: Changed the SQL precached syntax items, omni_sql_precache_syntax_groups,
|
||||
" to use regular expressions to pick up extended syntax group names.
|
||||
" This requires an updated SyntaxComplete plugin version 13.0.
|
||||
" If the required versions have not been installed, previous
|
||||
" behaviour will not be impacted.
|
||||
"
|
||||
" Version 14.0 (Dec 2012)
|
||||
" - BF: Added check for cpo
|
||||
"
|
||||
" Version 13.0 (Dec 2012)
|
||||
" - NF: When completing column lists or drilling into a table
|
||||
" and g:omni_sql_include_owner is enabled, the
|
||||
" only the table name would be replaced with the column
|
||||
" list instead of the table name and owner (if specified).
|
||||
" - NF: When completing column lists using table aliases
|
||||
" and g:omni_sql_include_owner is enabled, account
|
||||
" for the owner name when looking up the table
|
||||
" list instead of the table name and owner (if specified).
|
||||
" - BF: When completing column lists or drilling into a table
|
||||
" and g:omni_sql_include_owner is enabled, the
|
||||
" column list could often not be found for the table.
|
||||
" - BF: When OMNI popped up, possibly the wrong word
|
||||
" would be replaced for column and column list options.
|
||||
"
|
||||
" Version 12.0 (Feb 2012)
|
||||
" - Partial column name completion did not work when a table
|
||||
" name or table alias was provided (Jonas Enberg).
|
||||
" - Improved the handling of column completion. First we match any
|
||||
" columns from a previous completion. If not matches are found, we
|
||||
" consider the partial name to be a table or table alias for the
|
||||
" consider the partial name to be a table or table alias for the
|
||||
" query and attempt to match on it.
|
||||
"
|
||||
" Version 11.0
|
||||
" Version 11.0 (Jan 2012)
|
||||
" Added g:omni_sql_default_compl_type variable
|
||||
" - You can specify which type of completion to default to
|
||||
" when pressing <C-X><C-O>. The entire list of available
|
||||
@@ -40,7 +72,7 @@
|
||||
" - Prepends error message with SQLComplete so you know who issued
|
||||
" the error.
|
||||
"
|
||||
" Version 9.0
|
||||
" Version 9.0 (May 2010)
|
||||
" This change removes some of the support for tables with spaces in their
|
||||
" names in order to simplify the regexes used to pull out query table
|
||||
" aliases for more robust table name and column name code completion.
|
||||
@@ -51,10 +83,10 @@
|
||||
" Incorrectly re-executed the g:ftplugin_sql_omni_key_right and g:ftplugin_sql_omni_key_left
|
||||
" when drilling in and out of a column list for a table.
|
||||
"
|
||||
" Version 7.0
|
||||
" Version 7.0 (Jan 2010)
|
||||
" Better handling of object names
|
||||
"
|
||||
" Version 6.0
|
||||
" Version 6.0 (Apr 2008)
|
||||
" Supports object names with spaces "my table name"
|
||||
"
|
||||
" Set completion with CTRL-X CTRL-O to autoloaded function.
|
||||
@@ -71,7 +103,9 @@ endif
|
||||
if exists('g:loaded_sql_completion')
|
||||
finish
|
||||
endif
|
||||
let g:loaded_sql_completion = 120
|
||||
let g:loaded_sql_completion = 150
|
||||
let s:keepcpo= &cpo
|
||||
set cpo&vim
|
||||
|
||||
" Maintains filename of dictionary
|
||||
let s:sql_file_table = ""
|
||||
@@ -88,12 +122,14 @@ let s:syn_value = []
|
||||
" Used in conjunction with the syntaxcomplete plugin
|
||||
let s:save_inc = ""
|
||||
let s:save_exc = ""
|
||||
if exists('g:omni_syntax_group_include_sql')
|
||||
let s:save_inc = g:omni_syntax_group_include_sql
|
||||
if !exists('g:omni_syntax_group_include_sql')
|
||||
let g:omni_syntax_group_include_sql = ''
|
||||
endif
|
||||
if exists('g:omni_syntax_group_exclude_sql')
|
||||
let s:save_exc = g:omni_syntax_group_exclude_sql
|
||||
if !exists('g:omni_syntax_group_exclude_sql')
|
||||
let g:omni_syntax_group_exclude_sql = ''
|
||||
endif
|
||||
let s:save_inc = g:omni_syntax_group_include_sql
|
||||
let s:save_exc = g:omni_syntax_group_exclude_sql
|
||||
|
||||
" Used with the column list
|
||||
let s:save_prev_table = ""
|
||||
@@ -105,12 +141,12 @@ endif
|
||||
" Default syntax items to precache
|
||||
if !exists('g:omni_sql_precache_syntax_groups')
|
||||
let g:omni_sql_precache_syntax_groups = [
|
||||
\ 'syntax',
|
||||
\ 'sqlKeyword',
|
||||
\ 'sqlFunction',
|
||||
\ 'sqlOption',
|
||||
\ 'sqlType',
|
||||
\ 'sqlStatement'
|
||||
\ 'syntax\w*',
|
||||
\ 'sqlKeyword\w*',
|
||||
\ 'sqlFunction\w*',
|
||||
\ 'sqlOption\w*',
|
||||
\ 'sqlType\w*',
|
||||
\ 'sqlStatement\w*'
|
||||
\ ]
|
||||
endif
|
||||
" Set ignorecase to the ftplugin standard
|
||||
@@ -137,6 +173,13 @@ if !exists('g:omni_sql_default_compl_type')
|
||||
endif
|
||||
|
||||
" This function is used for the 'omnifunc' option.
|
||||
" It is called twice by omni and it is responsible
|
||||
" for returning the completion list of items.
|
||||
" But it must also determine context of what to complete
|
||||
" and what to "replace" with the completion.
|
||||
" The a:base, is replaced directly with what the user
|
||||
" chooses from the choices.
|
||||
" The s:prepend provides context for the completion.
|
||||
function! sqlcomplete#Complete(findstart, base)
|
||||
|
||||
" Default to table name completion
|
||||
@@ -145,6 +188,7 @@ function! sqlcomplete#Complete(findstart, base)
|
||||
if exists('b:sql_compl_type')
|
||||
let compl_type = b:sql_compl_type
|
||||
endif
|
||||
let begindot = 0
|
||||
|
||||
" First pass through this function determines how much of the line should
|
||||
" be replaced by whatever is chosen from the completion list
|
||||
@@ -153,7 +197,6 @@ function! sqlcomplete#Complete(findstart, base)
|
||||
let line = getline('.')
|
||||
let start = col('.') - 1
|
||||
let lastword = -1
|
||||
let begindot = 0
|
||||
" Check if the first character is a ".", for column completion
|
||||
if line[start - 1] == '.'
|
||||
let begindot = 1
|
||||
@@ -179,7 +222,10 @@ function! sqlcomplete#Complete(findstart, base)
|
||||
" If lastword has already been set for column completion
|
||||
" break from the loop, since we do not also want to pickup
|
||||
" a table name if it was also supplied.
|
||||
" Unless g:omni_sql_include_owner == 1, then we can
|
||||
" include the ownername.
|
||||
if lastword != -1 && compl_type == 'column'
|
||||
\ && g:omni_sql_include_owner == 0
|
||||
break
|
||||
endif
|
||||
" If column completion was specified stop at the "." if
|
||||
@@ -191,7 +237,7 @@ function! sqlcomplete#Complete(findstart, base)
|
||||
" If omni_sql_include_owner = 0, do not include the table
|
||||
" name as part of the substitution, so break here
|
||||
if lastword == -1 &&
|
||||
\ compl_type =~ 'table\|view\|procedure\column_csv' &&
|
||||
\ compl_type =~ '\<\(table\|view\|procedure\|column\|column_csv\)\>' &&
|
||||
\ g:omni_sql_include_owner == 0
|
||||
let lastword = start
|
||||
break
|
||||
@@ -288,6 +334,12 @@ function! sqlcomplete#Complete(findstart, base)
|
||||
let table = matchstr( base, '^\(.*\.\)\?\zs.*\ze\..*' )
|
||||
let column = matchstr( base, '.*\.\zs.*' )
|
||||
|
||||
if g:omni_sql_include_owner == 1 && owner == '' && table != '' && column != ''
|
||||
let owner = table
|
||||
let table = column
|
||||
let column = ''
|
||||
endif
|
||||
|
||||
" It is pretty well impossible to determine if the user
|
||||
" has entered:
|
||||
" owner.table
|
||||
@@ -370,7 +422,16 @@ function! sqlcomplete#Complete(findstart, base)
|
||||
let list_type = 'csv'
|
||||
endif
|
||||
|
||||
let compl_list = s:SQLCGetColumns(table, list_type)
|
||||
" If we are including the OWNER for the objects, then for
|
||||
" table completion, if we have it, it should be included
|
||||
" as there can be the same table names in a database yet
|
||||
" with different owner names.
|
||||
if g:omni_sql_include_owner == 1 && owner != '' && table != ''
|
||||
let compl_list = s:SQLCGetColumns(owner.'.'.table, list_type)
|
||||
else
|
||||
let compl_list = s:SQLCGetColumns(table, list_type)
|
||||
endif
|
||||
|
||||
if column != ''
|
||||
" If no column prefix has been provided and the table
|
||||
" name was provided, append it to each of the items
|
||||
@@ -393,11 +454,14 @@ function! sqlcomplete#Complete(findstart, base)
|
||||
endif
|
||||
elseif compl_type == 'resetCache'
|
||||
" Reset all cached items
|
||||
let s:tbl_name = []
|
||||
let s:tbl_alias = []
|
||||
let s:tbl_cols = []
|
||||
let s:syn_list = []
|
||||
let s:syn_value = []
|
||||
let s:tbl_name = []
|
||||
let s:tbl_alias = []
|
||||
let s:tbl_cols = []
|
||||
let s:syn_list = []
|
||||
let s:syn_value = []
|
||||
let s:sql_file_table = ""
|
||||
let s:sql_file_procedure = ""
|
||||
let s:sql_file_view = ""
|
||||
|
||||
let msg = "All SQL cached items have been removed."
|
||||
call s:SQLCWarningMsg(msg)
|
||||
@@ -423,12 +487,27 @@ function! sqlcomplete#Complete(findstart, base)
|
||||
" let expr = 'v:val '.(g:omni_sql_ignorecase==1?'=~?':'=~#').' "\\(^'.base.'\\|\\(\\.\\)\\?'.base.'\\)"'
|
||||
" let expr = 'v:val '.(g:omni_sql_ignorecase==1?'=~?':'=~#').' "\\(^'.base.'\\|\\([^.]*\\)\\?'.base.'\\)"'
|
||||
let compl_list = filter(deepcopy(compl_list), expr)
|
||||
|
||||
if empty(compl_list) && compl_type == 'table' && base =~ '\.$'
|
||||
" It is possible we could be looking for column name completion
|
||||
" and the user simply hit C-X C-O to lets try it as well
|
||||
" since we had no hits with the tables.
|
||||
" If the base ends with a . it is hard to know if we are
|
||||
" completing table names or column names.
|
||||
let list_type = ''
|
||||
|
||||
let compl_list = s:SQLCGetColumns(base, list_type)
|
||||
endif
|
||||
endif
|
||||
|
||||
if exists('b:sql_compl_savefunc') && b:sql_compl_savefunc != ""
|
||||
let &omnifunc = b:sql_compl_savefunc
|
||||
endif
|
||||
|
||||
if empty(compl_list)
|
||||
call s:SQLCWarningMsg( 'Could not find type['.compl_type.'] using prepend[.'.s:prepended.'] base['.a:base.']' )
|
||||
endif
|
||||
|
||||
return compl_list
|
||||
endfunc
|
||||
|
||||
@@ -556,19 +635,23 @@ function! s:SQLCGetSyntaxList(syn_group)
|
||||
" Return previously cached value
|
||||
let compl_list = s:syn_value[list_idx]
|
||||
else
|
||||
let s:save_inc = g:omni_syntax_group_include_sql
|
||||
let s:save_exc = g:omni_syntax_group_exclude_sql
|
||||
let g:omni_syntax_group_include_sql = ''
|
||||
let g:omni_syntax_group_exclude_sql = ''
|
||||
|
||||
" Request the syntax list items from the
|
||||
" syntax completion plugin
|
||||
if syn_group == 'syntax'
|
||||
" Handle this special case. This allows the user
|
||||
" to indicate they want all the syntax items available,
|
||||
" so do not specify a specific include list.
|
||||
let g:omni_syntax_group_include_sql = ''
|
||||
let syn_value = syntaxcomplete#OmniSyntaxList()
|
||||
else
|
||||
" The user has specified a specific syntax group
|
||||
let g:omni_syntax_group_include_sql = syn_group
|
||||
let syn_value = syntaxcomplete#OmniSyntaxList(syn_group)
|
||||
endif
|
||||
let g:omni_syntax_group_exclude_sql = ''
|
||||
let syn_value = syntaxcomplete#OmniSyntaxList()
|
||||
let g:omni_syntax_group_include_sql = s:save_inc
|
||||
let g:omni_syntax_group_exclude_sql = s:save_exc
|
||||
" Cache these values for later use
|
||||
@@ -664,8 +747,26 @@ function! s:SQLCGetObjectOwner(object)
|
||||
endfunction
|
||||
|
||||
function! s:SQLCGetColumns(table_name, list_type)
|
||||
if a:table_name =~ '\.'
|
||||
" Check if the owner/creator has been specified
|
||||
let owner = matchstr( a:table_name, '^\zs.*\ze\..*\..*' )
|
||||
let table = matchstr( a:table_name, '^\(.*\.\)\?\zs.*\ze\..*' )
|
||||
let column = matchstr( a:table_name, '.*\.\zs.*' )
|
||||
|
||||
if g:omni_sql_include_owner == 1 && owner == '' && table != '' && column != ''
|
||||
let owner = table
|
||||
let table = column
|
||||
let column = ''
|
||||
endif
|
||||
else
|
||||
let owner = ''
|
||||
let table = matchstr(a:table_name, '^["\[\]a-zA-Z0-9_ ]\+\ze\.\?')
|
||||
let column = ''
|
||||
endif
|
||||
|
||||
" Check if the table name was provided as part of the column name
|
||||
let table_name = matchstr(a:table_name, '^["\[\]a-zA-Z0-9_ ]\+\ze\.\?')
|
||||
" let table_name = matchstr(a:table_name, '^["\[\]a-zA-Z0-9_ ]\+\ze\.\?')
|
||||
let table_name = table
|
||||
let table_cols = []
|
||||
let table_alias = ''
|
||||
let move_to_top = 1
|
||||
@@ -786,7 +887,12 @@ function! s:SQLCGetColumns(table_name, list_type)
|
||||
|
||||
if table_name_new != ''
|
||||
let table_alias = table_name
|
||||
let table_name = matchstr( table_name_new, '^\(.*\.\)\?\zs.*\ze' )
|
||||
if g:omni_sql_include_owner == 1
|
||||
let table_name = matchstr( table_name_new, '^\zs\(.\{-}\.\)\?\(.\{-}\.\)\?.*\ze' )
|
||||
else
|
||||
" let table_name = matchstr( table_name_new, '^\(.*\.\)\?\zs.*\ze' )
|
||||
let table_name = matchstr( table_name_new, '^\(.\{-}\.\)\?\zs\(.\{-}\.\)\?.*\ze' )
|
||||
endif
|
||||
|
||||
let list_idx = index(s:tbl_name, table_name, 0, &ignorecase)
|
||||
if list_idx > -1
|
||||
@@ -828,7 +934,8 @@ function! s:SQLCGetColumns(table_name, list_type)
|
||||
if empty(table_cols)
|
||||
" Specify silent mode, no messages to the user (tbl, 1)
|
||||
" Specify do not comma separate (tbl, 1, 1)
|
||||
let table_cols_str = DB_getListColumn(table_name, 1, 1)
|
||||
" let table_cols_str = DB_getListColumn(table_name, 1, 1)
|
||||
let table_cols_str = DB_getListColumn((owner!=''?owner.'.':'').table_name, 1, 1)
|
||||
|
||||
if table_cols_str != ""
|
||||
let s:tbl_name = add( s:tbl_name, table_name )
|
||||
@@ -854,3 +961,7 @@ function! s:SQLCGetColumns(table_name, list_type)
|
||||
|
||||
return table_cols
|
||||
endfunction
|
||||
" Restore:
|
||||
let &cpo= s:keepcpo
|
||||
unlet s:keepcpo
|
||||
" vim: ts=4 fdm=marker
|
||||
|
||||
@@ -1,44 +1,80 @@
|
||||
" Vim completion script
|
||||
" Language: All languages, uses existing syntax highlighting rules
|
||||
" Maintainer: David Fishburn <dfishburn dot vim at gmail dot com>
|
||||
" Version: 8.0
|
||||
" Last Change: 2011 Nov 02
|
||||
" Usage: For detailed help, ":help ft-syntax-omni"
|
||||
" Version: 13.0
|
||||
" Last Change: 2013 May 14
|
||||
" Usage: For detailed help, ":help ft-syntax-omni"
|
||||
|
||||
" History
|
||||
"
|
||||
" Version 13.0
|
||||
" - Extended the option omni_syntax_group_include_{filetype}
|
||||
" to accept a comma separated list of regex's rather than
|
||||
" string. For example, for the javascript filetype you could
|
||||
" use:
|
||||
" let g:omni_syntax_group_include_javascript = 'javascript\w\+,jquery\w\+'
|
||||
" - Some syntax files (perl.vim) use the match // syntax as a mechanism
|
||||
" to identify keywords. This update attempts to parse the
|
||||
" match syntax and pull out syntax items which are at least
|
||||
" 3 words or more.
|
||||
"
|
||||
" Version 12.0
|
||||
" - It is possible to have '-' as part of iskeyword, when
|
||||
" checking for character ranges, tighten up the regex.
|
||||
" E688: More targets than List items.
|
||||
"
|
||||
" Version 11.0
|
||||
" - Corrected which characters required escaping during
|
||||
" substitution calls.
|
||||
"
|
||||
" Version 10.0
|
||||
" - Cycle through all the character ranges specified in the
|
||||
" iskeyword option and build a list of valid word separators.
|
||||
" Prior to this change, only actual characters were used,
|
||||
" where for example ASCII "45" == "-". If "45" were used
|
||||
" in iskeyword the hyphen would not be picked up.
|
||||
" This introduces a new option, since the character ranges
|
||||
" specified could be multibyte:
|
||||
" let g:omni_syntax_use_single_byte = 1
|
||||
" - This by default will only allow single byte ASCII
|
||||
" characters to be added and an additional check to ensure
|
||||
" the charater is printable (see documentation for isprint).
|
||||
"
|
||||
" Version 9.0
|
||||
" - Add the check for cpo.
|
||||
"
|
||||
" Version 8.0
|
||||
" Updated SyntaxCSyntaxGroupItems()
|
||||
" - Updated SyntaxCSyntaxGroupItems()
|
||||
" - Some additional syntax items were also allowed
|
||||
" on nextgroup= lines which were ignored by default.
|
||||
" Now these lines are processed independently.
|
||||
"
|
||||
" Version 7.0
|
||||
" Updated syntaxcomplete#OmniSyntaxList()
|
||||
" - Updated syntaxcomplete#OmniSyntaxList()
|
||||
" - Looking up the syntax groups defined from a syntax file
|
||||
" looked for only 1 format of {filetype}GroupName, but some
|
||||
" looked for only 1 format of {filetype}GroupName, but some
|
||||
" syntax writers use this format as well:
|
||||
" {b:current_syntax}GroupName
|
||||
" OmniSyntaxList() will now check for both if the first
|
||||
" - OmniSyntaxList() will now check for both if the first
|
||||
" method does not find a match.
|
||||
"
|
||||
" Version 6.0
|
||||
" Added syntaxcomplete#OmniSyntaxList()
|
||||
" - Allows other plugins to use this for their own
|
||||
" - Added syntaxcomplete#OmniSyntaxList()
|
||||
" - Allows other plugins to use this for their own
|
||||
" purposes.
|
||||
" - It will return a List of all syntax items for the
|
||||
" syntax group name passed in.
|
||||
" - XPTemplate for SQL will use this function via the
|
||||
" syntax group name passed in.
|
||||
" - XPTemplate for SQL will use this function via the
|
||||
" sqlcomplete plugin to populate a Choose box.
|
||||
"
|
||||
" Version 5.0
|
||||
" Updated SyntaxCSyntaxGroupItems()
|
||||
" - Updated SyntaxCSyntaxGroupItems()
|
||||
" - When processing a list of syntax groups, the final group
|
||||
" was missed in function SyntaxCSyntaxGroupItems.
|
||||
"
|
||||
" Set completion with CTRL-X CTRL-O to autoloaded function.
|
||||
" This check is in place in case this script is
|
||||
" sourced directly instead of using the autoload feature.
|
||||
" sourced directly instead of using the autoload feature.
|
||||
if exists('+omnifunc')
|
||||
" Do not set the option if already set since this
|
||||
" results in an E117 warning.
|
||||
@@ -48,9 +84,13 @@ if exists('+omnifunc')
|
||||
endif
|
||||
|
||||
if exists('g:loaded_syntax_completion')
|
||||
finish
|
||||
finish
|
||||
endif
|
||||
let g:loaded_syntax_completion = 80
|
||||
let g:loaded_syntax_completion = 130
|
||||
|
||||
" Turn on support for line continuations when creating the script
|
||||
let s:cpo_save = &cpo
|
||||
set cpo&vim
|
||||
|
||||
" Set ignorecase to the ftplugin standard
|
||||
" This is the default setting, but if you define a buffer local
|
||||
@@ -67,6 +107,18 @@ if !exists('g:omni_syntax_use_iskeyword')
|
||||
let g:omni_syntax_use_iskeyword = 1
|
||||
endif
|
||||
|
||||
" When using iskeyword, this setting controls whether the characters
|
||||
" should be limited to single byte characters.
|
||||
if !exists('g:omni_syntax_use_single_byte')
|
||||
let g:omni_syntax_use_single_byte = 1
|
||||
endif
|
||||
|
||||
" When using iskeyword, this setting controls whether the characters
|
||||
" should be limited to single byte characters.
|
||||
if !exists('g:omni_syntax_use_iskeyword_numeric')
|
||||
let g:omni_syntax_use_iskeyword_numeric = 1
|
||||
endif
|
||||
|
||||
" Only display items in the completion window that are at least
|
||||
" this many characters in length.
|
||||
" This is the default setting, but if you define a buffer local
|
||||
@@ -77,7 +129,8 @@ endif
|
||||
|
||||
" This script will build a completion list based on the syntax
|
||||
" elements defined by the files in $VIMRUNTIME/syntax.
|
||||
let s:syn_remove_words = 'match,matchgroup=,contains,'.
|
||||
" let s:syn_remove_words = 'match,matchgroup=,contains,'.
|
||||
let s:syn_remove_words = 'matchgroup=,contains,'.
|
||||
\ 'links to,start=,end='
|
||||
" \ 'links to,start=,end=,nextgroup='
|
||||
|
||||
@@ -158,7 +211,7 @@ endfunc
|
||||
function! syntaxcomplete#OmniSyntaxList(...)
|
||||
if a:0 > 0
|
||||
let parms = []
|
||||
if 3 == type(a:1)
|
||||
if 3 == type(a:1)
|
||||
let parms = a:1
|
||||
elseif 1 == type(a:1)
|
||||
let parms = split(a:1, ',')
|
||||
@@ -172,7 +225,7 @@ endfunc
|
||||
function! OmniSyntaxList(...)
|
||||
let list_parms = []
|
||||
if a:0 > 0
|
||||
if 3 == type(a:1)
|
||||
if 3 == type(a:1)
|
||||
let list_parms = a:1
|
||||
elseif 1 == type(a:1)
|
||||
let list_parms = split(a:1, ',')
|
||||
@@ -208,18 +261,18 @@ function! OmniSyntaxList(...)
|
||||
|
||||
let saveL = @l
|
||||
let filetype = substitute(&filetype, '\.', '_', 'g')
|
||||
|
||||
|
||||
if empty(list_parms)
|
||||
" Default the include group to include the requested syntax group
|
||||
let syntax_group_include_{filetype} = ''
|
||||
" Check if there are any overrides specified for this filetype
|
||||
if exists('g:omni_syntax_group_include_'.filetype)
|
||||
let syntax_group_include_{filetype} =
|
||||
\ substitute( g:omni_syntax_group_include_{filetype},'\s\+','','g')
|
||||
\ substitute( g:omni_syntax_group_include_{filetype},'\s\+','','g')
|
||||
let list_parms = split(g:omni_syntax_group_include_{filetype}, ',')
|
||||
if syntax_group_include_{filetype} =~ '\w'
|
||||
let syntax_group_include_{filetype} =
|
||||
\ substitute( syntax_group_include_{filetype},
|
||||
let syntax_group_include_{filetype} =
|
||||
\ substitute( syntax_group_include_{filetype},
|
||||
\ '\s*,\s*', '\\|', 'g'
|
||||
\ )
|
||||
endif
|
||||
@@ -229,24 +282,34 @@ function! OmniSyntaxList(...)
|
||||
endif
|
||||
|
||||
" Loop through all the syntax groupnames, and build a
|
||||
" syntax file which contains these names. This can
|
||||
" syntax file which contains these names. This can
|
||||
" work generically for any filetype that does not already
|
||||
" have a plugin defined.
|
||||
" This ASSUMES the syntax groupname BEGINS with the name
|
||||
" of the filetype. From my casual viewing of the vim7\syntax
|
||||
" of the filetype. From my casual viewing of the vim7\syntax
|
||||
" directory this is true for almost all syntax definitions.
|
||||
" As an example, the SQL syntax groups have this pattern:
|
||||
" sqlType
|
||||
" sqlOperators
|
||||
" sqlKeyword ...
|
||||
redir @l
|
||||
silent! exec 'syntax list '.join(list_parms)
|
||||
redir END
|
||||
if !empty(list_parms) && empty(substitute(join(list_parms), '[a-zA-Z ]', '', 'g'))
|
||||
" If list_parms only includes word characters, use it to limit
|
||||
" the syntax elements.
|
||||
" If using regex syntax list will fail to find those items, so
|
||||
" simply grab the who syntax list.
|
||||
redir @l
|
||||
silent! exec 'syntax list '.join(list_parms)
|
||||
redir END
|
||||
else
|
||||
redir @l
|
||||
silent! exec 'syntax list'
|
||||
redir END
|
||||
endif
|
||||
|
||||
let syntax_full = "\n".@l
|
||||
let @l = saveL
|
||||
|
||||
if syntax_full =~ 'E28'
|
||||
if syntax_full =~ 'E28'
|
||||
\ || syntax_full =~ 'E411'
|
||||
\ || syntax_full =~ 'E415'
|
||||
\ || syntax_full =~ 'No Syntax items'
|
||||
@@ -256,7 +319,7 @@ function! OmniSyntaxList(...)
|
||||
let filetype = substitute(&filetype, '\.', '_', 'g')
|
||||
|
||||
let list_exclude_groups = []
|
||||
if a:0 > 0
|
||||
if a:0 > 0
|
||||
" Do nothing since we have specific a specific list of groups
|
||||
else
|
||||
" Default the exclude group to nothing
|
||||
@@ -264,93 +327,178 @@ function! OmniSyntaxList(...)
|
||||
" Check if there are any overrides specified for this filetype
|
||||
if exists('g:omni_syntax_group_exclude_'.filetype)
|
||||
let syntax_group_exclude_{filetype} =
|
||||
\ substitute( g:omni_syntax_group_exclude_{filetype},'\s\+','','g')
|
||||
\ substitute( g:omni_syntax_group_exclude_{filetype},'\s\+','','g')
|
||||
let list_exclude_groups = split(g:omni_syntax_group_exclude_{filetype}, ',')
|
||||
if syntax_group_exclude_{filetype} =~ '\w'
|
||||
let syntax_group_exclude_{filetype} =
|
||||
\ substitute( syntax_group_exclude_{filetype},
|
||||
if syntax_group_exclude_{filetype} =~ '\w'
|
||||
let syntax_group_exclude_{filetype} =
|
||||
\ substitute( syntax_group_exclude_{filetype},
|
||||
\ '\s*,\s*', '\\|', 'g'
|
||||
\ )
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
" Sometimes filetypes can be composite names, like c.doxygen
|
||||
" Loop through each individual part looking for the syntax
|
||||
" items specific to each individual filetype.
|
||||
if empty(list_parms)
|
||||
let list_parms = [&filetype.'\w\+']
|
||||
endif
|
||||
|
||||
let syn_list = ''
|
||||
let ftindex = 0
|
||||
let ftindex = match(&filetype, '\w\+', ftindex)
|
||||
let index = 0
|
||||
for group_regex in list_parms
|
||||
" Sometimes filetypes can be composite names, like c.doxygen
|
||||
" Loop through each individual part looking for the syntax
|
||||
" items specific to each individual filetype.
|
||||
" let ftindex = 0
|
||||
" let ftindex = match(syntax_full, group_regex, ftindex)
|
||||
|
||||
while ftindex > -1
|
||||
let ft_part_name = matchstr( &filetype, '\w\+', ftindex )
|
||||
" while ftindex > -1
|
||||
" let ft_part_name = matchstr( syntax_full, '\w\+', ftindex )
|
||||
|
||||
" Syntax rules can contain items for more than just the current
|
||||
" filetype. They can contain additional items added by the user
|
||||
" via autocmds or their vimrc.
|
||||
" Some syntax files can be combined (html, php, jsp).
|
||||
" We want only items that begin with the filetype we are interested in.
|
||||
let next_group_regex = '\n' .
|
||||
\ '\zs'.ft_part_name.'\w\+\ze'.
|
||||
\ '\s\+xxx\s\+'
|
||||
let index = 0
|
||||
let index = match(syntax_full, next_group_regex, index)
|
||||
|
||||
if index == -1 && exists('b:current_syntax') && ft_part_name != b:current_syntax
|
||||
" There appears to be two standards when writing syntax files.
|
||||
" Either items begin as:
|
||||
" syn keyword {filetype}Keyword values ...
|
||||
" let b:current_syntax = "sql"
|
||||
" let b:current_syntax = "sqlanywhere"
|
||||
" Or
|
||||
" syn keyword {syntax_filename}Keyword values ...
|
||||
" let b:current_syntax = "mysql"
|
||||
" So, we will make the format of finding the syntax group names
|
||||
" a bit more flexible and look for both if the first fails to
|
||||
" find a match.
|
||||
" Syntax rules can contain items for more than just the current
|
||||
" filetype. They can contain additional items added by the user
|
||||
" via autocmds or their vimrc.
|
||||
" Some syntax files can be combined (html, php, jsp).
|
||||
" We want only items that begin with the filetype we are interested in.
|
||||
let next_group_regex = '\n' .
|
||||
\ '\zs'.b:current_syntax.'\w\+\ze'.
|
||||
\ '\s\+xxx\s\+'
|
||||
let index = 0
|
||||
\ '\zs'.group_regex.'\ze'.
|
||||
\ '\s\+xxx\s\+'
|
||||
let index = match(syntax_full, next_group_regex, index)
|
||||
endif
|
||||
|
||||
while index > -1
|
||||
let group_name = matchstr( syntax_full, '\w\+', index )
|
||||
|
||||
let get_syn_list = 1
|
||||
for exclude_group_name in list_exclude_groups
|
||||
if '\<'.exclude_group_name.'\>' =~ '\<'.group_name.'\>'
|
||||
let get_syn_list = 0
|
||||
endif
|
||||
endfor
|
||||
|
||||
" This code is no longer needed in version 6.0 since we have
|
||||
" augmented the syntax list command to only retrieve the syntax
|
||||
" groups we are interested in.
|
||||
"
|
||||
" if get_syn_list == 1
|
||||
" if syntax_group_include_{filetype} != ''
|
||||
" if '\<'.syntax_group_include_{filetype}.'\>' !~ '\<'.group_name.'\>'
|
||||
" let get_syn_list = 0
|
||||
" endif
|
||||
" endif
|
||||
" endif
|
||||
|
||||
if get_syn_list == 1
|
||||
" Pass in the full syntax listing, plus the group name we
|
||||
" are interested in.
|
||||
let extra_syn_list = s:SyntaxCSyntaxGroupItems(group_name, syntax_full)
|
||||
let syn_list = syn_list . extra_syn_list . "\n"
|
||||
" For the matched group name, strip off any of the regex special
|
||||
" characters and see if we get a match with the current syntax
|
||||
if index == -1 && exists('b:current_syntax') && substitute(group_regex, '[^a-zA-Z ]\+.*', '', 'g') !~ '^'.b:current_syntax
|
||||
" There appears to be two standards when writing syntax files.
|
||||
" Either items begin as:
|
||||
" syn keyword {filetype}Keyword values ...
|
||||
" let b:current_syntax = "sql"
|
||||
" let b:current_syntax = "sqlanywhere"
|
||||
" Or
|
||||
" syn keyword {syntax_filename}Keyword values ...
|
||||
" let b:current_syntax = "mysql"
|
||||
" So, we will make the format of finding the syntax group names
|
||||
" a bit more flexible and look for both if the first fails to
|
||||
" find a match.
|
||||
let next_group_regex = '\n' .
|
||||
\ '\zs'.b:current_syntax.'\w\+\ze'.
|
||||
\ '\s\+xxx\s\+'
|
||||
let index = 0
|
||||
let index = match(syntax_full, next_group_regex, index)
|
||||
endif
|
||||
|
||||
let index = index + strlen(group_name)
|
||||
let index = match(syntax_full, next_group_regex, index)
|
||||
endwhile
|
||||
while index > -1
|
||||
let group_name = matchstr( syntax_full, '\w\+', index )
|
||||
|
||||
let ftindex = ftindex + len(ft_part_name)
|
||||
let ftindex = match( &filetype, '\w\+', ftindex )
|
||||
endwhile
|
||||
let get_syn_list = 1
|
||||
for exclude_group_name in list_exclude_groups
|
||||
if '\<'.exclude_group_name.'\>' =~ '\<'.group_name.'\>'
|
||||
let get_syn_list = 0
|
||||
endif
|
||||
endfor
|
||||
|
||||
" This code is no longer needed in version 6.0 since we have
|
||||
" augmented the syntax list command to only retrieve the syntax
|
||||
" groups we are interested in.
|
||||
"
|
||||
" if get_syn_list == 1
|
||||
" if syntax_group_include_{filetype} != ''
|
||||
" if '\<'.syntax_group_include_{filetype}.'\>' !~ '\<'.group_name.'\>'
|
||||
" let get_syn_list = 0
|
||||
" endif
|
||||
" endif
|
||||
" endif
|
||||
|
||||
if get_syn_list == 1
|
||||
" Pass in the full syntax listing, plus the group name we
|
||||
" are interested in.
|
||||
let extra_syn_list = s:SyntaxCSyntaxGroupItems(group_name, syntax_full)
|
||||
let syn_list = syn_list . extra_syn_list . "\n"
|
||||
endif
|
||||
|
||||
let index = index + strlen(group_name)
|
||||
let index = match(syntax_full, next_group_regex, index)
|
||||
endwhile
|
||||
|
||||
" let ftindex = ftindex + len(ft_part_name)
|
||||
" let ftindex = match( syntax_full, group_regex, ftindex )
|
||||
" endwhile
|
||||
endfor
|
||||
|
||||
" " Sometimes filetypes can be composite names, like c.doxygen
|
||||
" " Loop through each individual part looking for the syntax
|
||||
" " items specific to each individual filetype.
|
||||
" let syn_list = ''
|
||||
" let ftindex = 0
|
||||
" let ftindex = match(&filetype, '\w\+', ftindex)
|
||||
|
||||
" while ftindex > -1
|
||||
" let ft_part_name = matchstr( &filetype, '\w\+', ftindex )
|
||||
|
||||
" " Syntax rules can contain items for more than just the current
|
||||
" " filetype. They can contain additional items added by the user
|
||||
" " via autocmds or their vimrc.
|
||||
" " Some syntax files can be combined (html, php, jsp).
|
||||
" " We want only items that begin with the filetype we are interested in.
|
||||
" let next_group_regex = '\n' .
|
||||
" \ '\zs'.ft_part_name.'\w\+\ze'.
|
||||
" \ '\s\+xxx\s\+'
|
||||
" let index = 0
|
||||
" let index = match(syntax_full, next_group_regex, index)
|
||||
|
||||
" if index == -1 && exists('b:current_syntax') && ft_part_name != b:current_syntax
|
||||
" " There appears to be two standards when writing syntax files.
|
||||
" " Either items begin as:
|
||||
" " syn keyword {filetype}Keyword values ...
|
||||
" " let b:current_syntax = "sql"
|
||||
" " let b:current_syntax = "sqlanywhere"
|
||||
" " Or
|
||||
" " syn keyword {syntax_filename}Keyword values ...
|
||||
" " let b:current_syntax = "mysql"
|
||||
" " So, we will make the format of finding the syntax group names
|
||||
" " a bit more flexible and look for both if the first fails to
|
||||
" " find a match.
|
||||
" let next_group_regex = '\n' .
|
||||
" \ '\zs'.b:current_syntax.'\w\+\ze'.
|
||||
" \ '\s\+xxx\s\+'
|
||||
" let index = 0
|
||||
" let index = match(syntax_full, next_group_regex, index)
|
||||
" endif
|
||||
|
||||
" while index > -1
|
||||
" let group_name = matchstr( syntax_full, '\w\+', index )
|
||||
|
||||
" let get_syn_list = 1
|
||||
" for exclude_group_name in list_exclude_groups
|
||||
" if '\<'.exclude_group_name.'\>' =~ '\<'.group_name.'\>'
|
||||
" let get_syn_list = 0
|
||||
" endif
|
||||
" endfor
|
||||
|
||||
" " This code is no longer needed in version 6.0 since we have
|
||||
" " augmented the syntax list command to only retrieve the syntax
|
||||
" " groups we are interested in.
|
||||
" "
|
||||
" " if get_syn_list == 1
|
||||
" " if syntax_group_include_{filetype} != ''
|
||||
" " if '\<'.syntax_group_include_{filetype}.'\>' !~ '\<'.group_name.'\>'
|
||||
" " let get_syn_list = 0
|
||||
" " endif
|
||||
" " endif
|
||||
" " endif
|
||||
|
||||
" if get_syn_list == 1
|
||||
" " Pass in the full syntax listing, plus the group name we
|
||||
" " are interested in.
|
||||
" let extra_syn_list = s:SyntaxCSyntaxGroupItems(group_name, syntax_full)
|
||||
" let syn_list = syn_list . extra_syn_list . "\n"
|
||||
" endif
|
||||
|
||||
" let index = index + strlen(group_name)
|
||||
" let index = match(syntax_full, next_group_regex, index)
|
||||
" endwhile
|
||||
|
||||
" let ftindex = ftindex + len(ft_part_name)
|
||||
" let ftindex = match( &filetype, '\w\+', ftindex )
|
||||
" endwhile
|
||||
|
||||
" Convert the string to a List and sort it.
|
||||
let compl_list = sort(split(syn_list))
|
||||
@@ -392,7 +540,7 @@ function! s:SyntaxCSyntaxGroupItems( group_name, syntax_full )
|
||||
" \| - 2nd potential match
|
||||
" \%$ - matches end of the file or string
|
||||
" \) - end a group
|
||||
let syntax_group = matchstr(a:syntax_full,
|
||||
let syntax_group = matchstr(a:syntax_full,
|
||||
\ "\n".a:group_name.'\s\+xxx\s\+\zs.\{-}\ze\(\n\w\|\%$\)'
|
||||
\ )
|
||||
|
||||
@@ -402,42 +550,97 @@ function! s:SyntaxCSyntaxGroupItems( group_name, syntax_full )
|
||||
|
||||
" We only want the words for the lines begining with
|
||||
" containedin, but there could be other items.
|
||||
|
||||
|
||||
" Tried to remove all lines that do not begin with contained
|
||||
" but this does not work in all cases since you can have
|
||||
" contained nextgroup=...
|
||||
" So this will strip off the ending of lines with known
|
||||
" keywords.
|
||||
let syn_list = substitute(
|
||||
let syn_list = substitute(
|
||||
\ syntax_group, '\<\('.
|
||||
\ substitute(
|
||||
\ escape(s:syn_remove_words, '\\/.*$^~[]')
|
||||
\ , ',', '\\|', 'g'
|
||||
\ ).
|
||||
\ '\).\{-}\%($\|'."\n".'\)'
|
||||
\ , "\n", 'g'
|
||||
\ , "\n", 'g'
|
||||
\ )
|
||||
|
||||
" Attempt to deal with lines using the match syntax
|
||||
" javaScriptDocTags xxx match /@\(param\|argument\|requires\|file\)\>/
|
||||
" Though it can use any types of regex, so this plugin will attempt
|
||||
" to restrict it
|
||||
" 1. Only use \( or \%( constructs remove all else
|
||||
" 2 Remove and []s
|
||||
" 3. Account for match //constructs
|
||||
" \%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?
|
||||
" 4. Hope for the best
|
||||
"
|
||||
"
|
||||
let syn_list_old = syn_list
|
||||
while syn_list =~ '\<match\>\s\+\/'
|
||||
if syn_list =~ 'perlElseIfError'
|
||||
let syn_list = syn_list
|
||||
endif
|
||||
" Check if the match has words at least 3 characters long
|
||||
if syn_list =~ '\<match \/\zs.\{-}\<\w\{3,}\>.\{-}\ze\\\@<!\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?\s\+'
|
||||
" Remove everything after / and before the first \(
|
||||
let syn_list = substitute( syn_list, '\<match \/\zs.\{-}\ze\\%\?(.\{-}\\\@<!\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?\s\+', '', 'g' )
|
||||
" Remove everything after \) and up to the ending /
|
||||
let syn_list = substitute( syn_list, '\<match \/.\{-}\\)\zs.\{-}\ze\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?\s\+', '', 'g' )
|
||||
|
||||
" Remove any character classes
|
||||
" let syn_list = substitute( syn_list, '\<match /\zs.\{-}\[[^]]*\].\{-}\ze\/ ', '', 'g' )
|
||||
let syn_list = substitute( syn_list, '\%(\<match \/[^/]\{-}\)\@<=\[[^]]*\]\ze.\{-}\\\@<!\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?', '', 'g' )
|
||||
" Remove any words < 3 characters
|
||||
let syn_list = substitute( syn_list, '\%(\<match \/[^/]\{-}\)\@<=\<\w\{1,2}\>\ze.\{-}\\\@<!\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?\s\+', '', 'g' )
|
||||
" Remove all non-word characters
|
||||
" let syn_list = substitute( syn_list, '\<match /\zs.\{-}\<\W\+\>.\{-}\ze\/ ', "", 'g' )
|
||||
" let syn_list = substitute( syn_list, '\%(\<match \/[^/]\{-}\)\@<=\W\+\ze.\{-}\/ ', ' ', 'g' )
|
||||
" Do this by using the outer substitue() call to gather all
|
||||
" text between the match /.../ tags.
|
||||
" The inner substitute() call operates on the text selected
|
||||
" and replaces all non-word characters.
|
||||
let syn_list = substitute( syn_list, '\<match \/\zs\(.\{-}\)\ze\\\@<!\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?\s\+'
|
||||
\ , '\=substitute(submatch(1), "\\W\\+", " ", "g")'
|
||||
\ , 'g' )
|
||||
" Remove the match / / syntax
|
||||
let syn_list = substitute( syn_list, '\<match \/\(.\{-}\)\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?\s\+', '\1', 'g' )
|
||||
else
|
||||
" No words long enough, remove the match
|
||||
" Remove the match syntax
|
||||
" let syn_list = substitute( syn_list, '\<match \/[^\/]*\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?\s\+', '', 'g' )
|
||||
let syn_list = substitute( syn_list, '\<match \/\%(.\{-}\)\?\/\%(\%(ms\|me\|hs\|he\|rs\|re\|lc\)\S\+\)\?\s\+', '', 'g' )
|
||||
endif
|
||||
if syn_list =~ '\<match\>\s\+\/'
|
||||
" Problem removing the match / / tags
|
||||
let syn_list = ''
|
||||
endif
|
||||
endwhile
|
||||
|
||||
|
||||
" Now strip off the newline + blank space + contained.
|
||||
" Also include lines with nextgroup=@someName skip_key_words syntax_element
|
||||
let syn_list = substitute(
|
||||
\ syn_list, '\%(^\|\n\)\@<=\s*\<\(contained\|nextgroup=\)'
|
||||
\ , "", 'g'
|
||||
" \ syn_list, '\%(^\|\n\)\@<=\s*\<\(contained\|nextgroup=\)'
|
||||
" \ syn_list, '\%(^\|\n\)\@<=\s*\<\(contained\|nextgroup=[@a-zA-Z,]*\)'
|
||||
let syn_list = substitute(
|
||||
\ syn_list, '\<\(contained\|nextgroup=[@a-zA-Z,]*\)'
|
||||
\ , "", 'g'
|
||||
\ )
|
||||
|
||||
" This can leave lines like this
|
||||
" =@vimMenuList skipwhite onoremenu
|
||||
" Strip the special option keywords first
|
||||
" :h :syn-skipwhite*
|
||||
let syn_list = substitute(
|
||||
let syn_list = substitute(
|
||||
\ syn_list, '\<\(skipwhite\|skipnl\|skipempty\)\>'
|
||||
\ , "", 'g'
|
||||
\ , "", 'g'
|
||||
\ )
|
||||
|
||||
" Now remove the remainder of the nextgroup=@someName lines
|
||||
let syn_list = substitute(
|
||||
let syn_list = substitute(
|
||||
\ syn_list, '\%(^\|\n\)\@<=\s*\(@\w\+\)'
|
||||
\ , "", 'g'
|
||||
\ , "", 'g'
|
||||
\ )
|
||||
|
||||
if b:omni_syntax_use_iskeyword == 0
|
||||
@@ -446,19 +649,74 @@ function! s:SyntaxCSyntaxGroupItems( group_name, syntax_full )
|
||||
" This will replace non-word characters with spaces.
|
||||
let syn_list = substitute( syn_list, '[^0-9A-Za-z_ ]', ' ', 'g' )
|
||||
else
|
||||
let accept_chars = ','.&iskeyword.','
|
||||
" Remove all character ranges
|
||||
" let accept_chars = substitute(accept_chars, ',[^,]\+-[^,]\+,', ',', 'g')
|
||||
let accept_chars = substitute(accept_chars, ',\@<=[^,]\+-[^,]\+,', '', 'g')
|
||||
" Remove all numeric specifications
|
||||
" let accept_chars = substitute(accept_chars, ',\d\{-},', ',', 'g')
|
||||
let accept_chars = substitute(accept_chars, ',\@<=\d\{-},', '', 'g')
|
||||
" Remove all commas
|
||||
let accept_chars = substitute(accept_chars, ',', '', 'g')
|
||||
" Escape special regex characters
|
||||
let accept_chars = escape(accept_chars, '\\/.*$^~[]' )
|
||||
" Remove all characters that are not acceptable
|
||||
let syn_list = substitute( syn_list, '[^0-9A-Za-z_ '.accept_chars.']', ' ', 'g' )
|
||||
if g:omni_syntax_use_iskeyword_numeric == 1
|
||||
" iskeyword can contain value like this
|
||||
" 38,42,43,45,47-58,60-62,64-90,97-122,_,+,-,*,/,%,<,=,>,:,$,?,!,@-@,94
|
||||
" Numeric values convert to their ASCII equivalent using the
|
||||
" nr2char() function.
|
||||
" & 38
|
||||
" * 42
|
||||
" + 43
|
||||
" - 45
|
||||
" ^ 94
|
||||
" Iterate through all numeric specifications and convert those
|
||||
" to their ascii equivalent ensuring the character is printable.
|
||||
" If so, add it to the list.
|
||||
let accepted_chars = ''
|
||||
for item in split(&iskeyword, ',')
|
||||
if item =~ '\d-\d'
|
||||
" This is a character range (ie 47-58),
|
||||
" cycle through each character within the range
|
||||
let [b:start, b:end] = split(item, '-')
|
||||
for range_item in range( b:start, b:end )
|
||||
if range_item <= 127 || g:omni_syntax_use_single_byte == 0
|
||||
if nr2char(range_item) =~ '\p'
|
||||
let accepted_chars = accepted_chars . nr2char(range_item)
|
||||
endif
|
||||
endif
|
||||
endfor
|
||||
elseif item =~ '^\d\+$'
|
||||
" Only numeric, translate to a character
|
||||
if item < 127 || g:omni_syntax_use_single_byte == 0
|
||||
if nr2char(item) =~ '\p'
|
||||
let accepted_chars = accepted_chars . nr2char(item)
|
||||
endif
|
||||
endif
|
||||
else
|
||||
if char2nr(item) < 127 || g:omni_syntax_use_single_byte == 0
|
||||
if item =~ '\p'
|
||||
let accepted_chars = accepted_chars . item
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
endfor
|
||||
" Escape special regex characters
|
||||
" Looks like the wrong chars are escaped. In a collection,
|
||||
" :h /[]
|
||||
" only `]', `\', `-' and `^' are special:
|
||||
" let accepted_chars = escape(accepted_chars, '\\/.*$^~[]' )
|
||||
let accepted_chars = escape(accepted_chars, ']\-^' )
|
||||
" Remove all characters that are not acceptable
|
||||
let syn_list = substitute( syn_list, '[^A-Za-z'.accepted_chars.']', ' ', 'g' )
|
||||
else
|
||||
let accept_chars = ','.&iskeyword.','
|
||||
" Remove all character ranges
|
||||
" let accept_chars = substitute(accept_chars, ',[^,]\+-[^,]\+,', ',', 'g')
|
||||
let accept_chars = substitute(accept_chars, ',\@<=[^,]\+-[^,]\+,', '', 'g')
|
||||
" Remove all numeric specifications
|
||||
" let accept_chars = substitute(accept_chars, ',\d\{-},', ',', 'g')
|
||||
let accept_chars = substitute(accept_chars, ',\@<=\d\{-},', '', 'g')
|
||||
" Remove all commas
|
||||
let accept_chars = substitute(accept_chars, ',', '', 'g')
|
||||
" Escape special regex characters
|
||||
" Looks like the wrong chars are escaped. In a collection,
|
||||
" :h /[]
|
||||
" only `]', `\', `-' and `^' are special:
|
||||
" let accept_chars = escape(accept_chars, '\\/.*$^~[]' )
|
||||
let accept_chars = escape(accept_chars, ']\-^' )
|
||||
" Remove all characters that are not acceptable
|
||||
let syn_list = substitute( syn_list, '[^0-9A-Za-z_'.accept_chars.']', ' ', 'g' )
|
||||
endif
|
||||
endif
|
||||
|
||||
if b:omni_syntax_minimum_length > 0
|
||||
@@ -471,3 +729,27 @@ function! s:SyntaxCSyntaxGroupItems( group_name, syntax_full )
|
||||
|
||||
return syn_list
|
||||
endfunction
|
||||
|
||||
function! OmniSyntaxShowChars(spec)
|
||||
let result = []
|
||||
for item in split(a:spec, ',')
|
||||
if len(item) > 1
|
||||
if item == '@-@'
|
||||
call add(result, char2nr(item))
|
||||
else
|
||||
call extend(result, call('range', split(item, '-')))
|
||||
endif
|
||||
else
|
||||
if item == '@' " assume this is [A-Za-z]
|
||||
for [c1, c2] in [['A', 'Z'], ['a', 'z']]
|
||||
call extend(result, range(char2nr(c1), char2nr(c2)))
|
||||
endfor
|
||||
else
|
||||
call add(result, char2nr(item))
|
||||
endif
|
||||
endif
|
||||
endfor
|
||||
return join(map(result, 'nr2char(v:val)'), ', ')
|
||||
endfunction
|
||||
let &cpo = s:cpo_save
|
||||
unlet s:cpo_save
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
" tar.vim: Handles browsing tarfiles
|
||||
" AUTOLOAD PORTION
|
||||
" Date: Jan 17, 2012
|
||||
" Version: 28
|
||||
" Maintainer: Charles E Campbell, Jr <NdrOchip@ScampbellPfamily.AbizM-NOSPAM>
|
||||
" Date: Apr 17, 2013
|
||||
" Version: 29
|
||||
" Maintainer: Charles E Campbell <NdrOchip@ScampbellPfamily.AbizM-NOSPAM>
|
||||
" License: Vim License (see vim's :help license)
|
||||
"
|
||||
" Contains many ideas from Michael Toren's <tar.vim>
|
||||
"
|
||||
" Copyright: Copyright (C) 2005-2011 Charles E. Campbell, Jr. {{{1
|
||||
" Copyright: Copyright (C) 2005-2011 Charles E. Campbell {{{1
|
||||
" Permission is hereby granted to use and distribute this code,
|
||||
" with or without modifications, provided that this copyright
|
||||
" notice is copied with it. Like anything else that's free,
|
||||
@@ -22,7 +22,7 @@
|
||||
if &cp || exists("g:loaded_tar")
|
||||
finish
|
||||
endif
|
||||
let g:loaded_tar= "v28"
|
||||
let g:loaded_tar= "v29"
|
||||
if v:version < 702
|
||||
echohl WarningMsg
|
||||
echo "***warning*** this version of tar needs vim 7.2"
|
||||
@@ -31,6 +31,7 @@ if v:version < 702
|
||||
endif
|
||||
let s:keepcpo= &cpo
|
||||
set cpo&vim
|
||||
"DechoTabOn
|
||||
"call Decho("loading autoload/tar.vim")
|
||||
|
||||
" ---------------------------------------------------------------------
|
||||
@@ -80,7 +81,7 @@ endif
|
||||
|
||||
" set up shell quoting character
|
||||
if !exists("g:tar_shq")
|
||||
if exists("&shq") && &shq != ""
|
||||
if exists("+shq") && exists("&shq") && &shq != ""
|
||||
let g:tar_shq= &shq
|
||||
elseif has("win32") || has("win95") || has("win64") || has("win16")
|
||||
if exists("g:netrw_cygwin") && g:netrw_cygwin
|
||||
@@ -147,7 +148,7 @@ fun! tar#Browse(tarfile)
|
||||
keepj $
|
||||
|
||||
let tarfile= a:tarfile
|
||||
if has("win32") && executable("cygpath")
|
||||
if has("win32unix") && executable("cygpath")
|
||||
" assuming cygwin
|
||||
let tarfile=substitute(system("cygpath -u ".shellescape(tarfile,0)),'\n$','','e')
|
||||
endif
|
||||
@@ -227,7 +228,7 @@ fun! s:TarBrowseSelect()
|
||||
" about to make a new window, need to use b:tarfile
|
||||
let tarfile= b:tarfile
|
||||
let curfile= expand("%")
|
||||
if has("win32") && executable("cygpath")
|
||||
if has("win32unix") && executable("cygpath")
|
||||
" assuming cygwin
|
||||
let tarfile=substitute(system("cygpath -u ".shellescape(tarfile,0)),'\n$','','e')
|
||||
endif
|
||||
@@ -239,6 +240,8 @@ fun! s:TarBrowseSelect()
|
||||
let s:tblfile_{winnr()}= curfile
|
||||
call tar#Read("tarfile:".tarfile.'::'.fname,1)
|
||||
filetype detect
|
||||
set nomod
|
||||
exe 'com! -buffer -nargs=? -complete=file TarDiff :call tar#Diff(<q-args>,"'.fnameescape(fname).'")'
|
||||
|
||||
let &report= repkeep
|
||||
" call Dret("TarBrowseSelect : s:tblfile_".winnr()."<".s:tblfile_{winnr()}.">")
|
||||
@@ -252,7 +255,7 @@ fun! tar#Read(fname,mode)
|
||||
set report=10
|
||||
let tarfile = substitute(a:fname,'tarfile:\(.\{-}\)::.*$','\1','')
|
||||
let fname = substitute(a:fname,'tarfile:.\{-}::\(.*\)$','\1','')
|
||||
if has("win32") && executable("cygpath")
|
||||
if has("win32unix") && executable("cygpath")
|
||||
" assuming cygwin
|
||||
let tarfile=substitute(system("cygpath -u ".shellescape(tarfile,0)),'\n$','','e')
|
||||
endif
|
||||
@@ -425,7 +428,7 @@ fun! tar#Write(fname)
|
||||
|
||||
if fname =~ '/'
|
||||
let dirpath = substitute(fname,'/[^/]\+$','','e')
|
||||
if executable("cygpath")
|
||||
if has("win32unix") && executable("cygpath")
|
||||
let dirpath = substitute(system("cygpath ".shellescape(dirpath, 0)),'\n','','e')
|
||||
endif
|
||||
call mkdir(dirpath,"p")
|
||||
@@ -445,7 +448,7 @@ fun! tar#Write(fname)
|
||||
let tar_secure= " "
|
||||
endif
|
||||
exe "w! ".fnameescape(fname)
|
||||
if executable("cygpath")
|
||||
if has("win32unix") && executable("cygpath")
|
||||
let tarfile = substitute(system("cygpath ".shellescape(tarfile,0)),'\n','','e')
|
||||
endif
|
||||
|
||||
@@ -500,6 +503,30 @@ fun! tar#Write(fname)
|
||||
" call Dret("tar#Write")
|
||||
endfun
|
||||
|
||||
" ---------------------------------------------------------------------
|
||||
" tar#Diff: {{{2
|
||||
fun! tar#Diff(userfname,fname)
|
||||
" call Dfunc("tar#Diff(userfname<".a:userfname."> fname<".a:fname.")")
|
||||
let fname= a:fname
|
||||
if a:userfname != ""
|
||||
let fname= a:userfname
|
||||
endif
|
||||
if filereadable(fname)
|
||||
" sets current file (from tarball) for diff'ing
|
||||
" splits window vertically
|
||||
" opens original file, sets it for diff'ing
|
||||
" sets up b:tardiff_otherbuf variables so each buffer knows about the other (for closing purposes)
|
||||
diffthis
|
||||
wincmd v
|
||||
exe "e ".fnameescape(fname)
|
||||
diffthis
|
||||
else
|
||||
redraw!
|
||||
echo "***warning*** unable to read file<".fname.">"
|
||||
endif
|
||||
" call Dret("tar#Diff")
|
||||
endfun
|
||||
|
||||
" ---------------------------------------------------------------------
|
||||
" s:Rmdir: {{{2
|
||||
fun! s:Rmdir(fname)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
" Vim autoload file for the tohtml plugin.
|
||||
" Maintainer: Ben Fritz <fritzophrenic@gmail.com>
|
||||
" Last Change: 2012 Jun 30
|
||||
" Last Change: 2013 May 31
|
||||
"
|
||||
" Additional contributors:
|
||||
"
|
||||
@@ -401,13 +401,13 @@ func! tohtml#Diff2HTML(win_list, buf_list) "{{{
|
||||
call add(html, '</head>')
|
||||
let body_line_num = len(html)
|
||||
if !empty(s:settings.prevent_copy)
|
||||
call add(html, "<body onload='FixCharWidth();'>")
|
||||
call add(html, "<body onload='FixCharWidth(); JumpToLine();'>")
|
||||
call add(html, "<!-- hidden divs used by javascript to get the width of a char -->")
|
||||
call add(html, "<div id='oneCharWidth'>0</div>")
|
||||
call add(html, "<div id='oneInputWidth'><input size='1' value='0'".tag_close."</div>")
|
||||
call add(html, "<div id='oneEmWidth' style='width: 1em;'></div>")
|
||||
else
|
||||
call add(html, '<body>')
|
||||
call add(html, '<body onload="JumpToLine();">')
|
||||
endif
|
||||
call add(html, "<table border='1' width='100%' id='vimCodeElement'>")
|
||||
|
||||
@@ -503,6 +503,11 @@ func! tohtml#Diff2HTML(win_list, buf_list) "{{{
|
||||
call add(html, s:body_end_line)
|
||||
call add(html, '</html>')
|
||||
|
||||
" The generated HTML is admittedly ugly and takes a LONG time to fold.
|
||||
" Make sure the user doesn't do syntax folding when loading a generated file,
|
||||
" using a modeline.
|
||||
call add(html, '<!-- vim: set foldmethod=manual : -->')
|
||||
|
||||
let i = 1
|
||||
let name = "Diff" . (s:settings.use_xhtml ? ".xhtml" : ".html")
|
||||
" Find an unused file name if current file name is already in use
|
||||
@@ -539,14 +544,12 @@ func! tohtml#Diff2HTML(win_list, buf_list) "{{{
|
||||
" add required javascript in reverse order so we can just call append again
|
||||
" and again without adjusting {{{
|
||||
|
||||
" insert script closing tag if any javascript is needed
|
||||
if s:settings.dynamic_folds || !empty(s:settings.prevent_copy)
|
||||
call append(style_start, [
|
||||
\ '',
|
||||
\ s:settings.use_xhtml ? '//]]>' : '-->',
|
||||
\ "</script>"
|
||||
\ ])
|
||||
endif
|
||||
" insert script closing tag
|
||||
call append(style_start, [
|
||||
\ '',
|
||||
\ s:settings.use_xhtml ? '//]]>' : '-->',
|
||||
\ "</script>"
|
||||
\ ])
|
||||
|
||||
" insert script which corrects the size of small input elements in
|
||||
" prevent_copy mode. See 2html.vim for details on why this is needed and how
|
||||
@@ -572,6 +575,55 @@ func! tohtml#Diff2HTML(win_list, buf_list) "{{{
|
||||
\ '}'
|
||||
\ ])
|
||||
endif
|
||||
"
|
||||
" insert javascript to get IDs from line numbers, and to open a fold before
|
||||
" jumping to any lines contained therein
|
||||
call append(style_start, [
|
||||
\ " /* Always jump to new location even if the line was hidden inside a fold, or",
|
||||
\ " * we corrected the raw number to a line ID.",
|
||||
\ " */",
|
||||
\ " if (lineElem) {",
|
||||
\ " lineElem.scrollIntoView(true);",
|
||||
\ " }",
|
||||
\ " return true;",
|
||||
\ "}",
|
||||
\ "if ('onhashchange' in window) {",
|
||||
\ " window.onhashchange = JumpToLine;",
|
||||
\ "}"
|
||||
\ ])
|
||||
if s:settings.dynamic_folds
|
||||
call append(style_start, [
|
||||
\ "",
|
||||
\ " /* navigate upwards in the DOM tree to open all folds containing the line */",
|
||||
\ " var node = lineElem;",
|
||||
\ " while (node && node.id != 'vimCodeElement')",
|
||||
\ " {",
|
||||
\ " if (node.className == 'closed-fold')",
|
||||
\ " {",
|
||||
\ " /* toggle open the fold ID (remove window ID) */",
|
||||
\ " toggleFold(node.id.substr(4));",
|
||||
\ " }",
|
||||
\ " node = node.parentNode;",
|
||||
\ " }",
|
||||
\ ])
|
||||
endif
|
||||
call append(style_start, [
|
||||
\ "",
|
||||
\ "/* function to open any folds containing a jumped-to line before jumping to it */",
|
||||
\ "function JumpToLine()",
|
||||
\ "{",
|
||||
\ " var lineNum;",
|
||||
\ " lineNum = window.location.hash;",
|
||||
\ " lineNum = lineNum.substr(1); /* strip off '#' */",
|
||||
\ "",
|
||||
\ " if (lineNum.indexOf('L') == -1) {",
|
||||
\ " lineNum = 'L'+lineNum;",
|
||||
\ " }",
|
||||
\ " if (lineNum.indexOf('W') == -1) {",
|
||||
\ " lineNum = 'W1'+lineNum;",
|
||||
\ " }",
|
||||
\ " lineElem = document.getElementById(lineNum);"
|
||||
\ ])
|
||||
|
||||
" Insert javascript to toggle matching folds open and closed in all windows,
|
||||
" if dynamic folding is active.
|
||||
@@ -596,12 +648,11 @@ func! tohtml#Diff2HTML(win_list, buf_list) "{{{
|
||||
\ ])
|
||||
endif
|
||||
|
||||
" insert script tag if any javascript is needed
|
||||
if s:settings.dynamic_folds || s:settings.prevent_copy != ""
|
||||
call append(style_start, [
|
||||
\ "<script type='text/javascript'>",
|
||||
\ s:settings.use_xhtml ? '//<![CDATA[' : "<!--"])
|
||||
endif "}}}
|
||||
" insert script tag; javascript is always needed for the line number
|
||||
" normalization for URL hashes
|
||||
call append(style_start, [
|
||||
\ "<script type='text/javascript'>",
|
||||
\ s:settings.use_xhtml ? '//<![CDATA[' : "<!--"])
|
||||
|
||||
" Insert styles from all the generated html documents and additional styles
|
||||
" for the table-based layout of the side-by-side diff. The diff should take
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
" zip.vim: Handles browsing zipfiles
|
||||
" AUTOLOAD PORTION
|
||||
" Date: Jan 17, 2012
|
||||
" Version: 25
|
||||
" Maintainer: Charles E Campbell, Jr <NdrOchip@ScampbellPfamily.AbizM-NOSPAM>
|
||||
" Date: Apr 17, 2013
|
||||
" Version: 26
|
||||
" Maintainer: Charles E Campbell <NdrOchip@ScampbellPfamily.AbizM-NOSPAM>
|
||||
" License: Vim License (see vim's :help license)
|
||||
" Copyright: Copyright (C) 2005-2012 Charles E. Campbell, Jr. {{{1
|
||||
" Copyright: Copyright (C) 2005-2012 Charles E. Campbell {{{1
|
||||
" Permission is hereby granted to use and distribute this code,
|
||||
" with or without modifications, provided that this copyright
|
||||
" notice is copied with it. Like anything else that's free,
|
||||
@@ -19,7 +19,7 @@
|
||||
if &cp || exists("g:loaded_zip")
|
||||
finish
|
||||
endif
|
||||
let g:loaded_zip= "v25"
|
||||
let g:loaded_zip= "v26"
|
||||
if v:version < 702
|
||||
echohl WarningMsg
|
||||
echo "***warning*** this version of zip needs vim 7.2"
|
||||
@@ -188,13 +188,23 @@ fun! zip#Read(fname,mode)
|
||||
else
|
||||
let zipfile = substitute(a:fname,'^.\{-}zipfile:\(.\{-}\)::[^\\].*$','\1','')
|
||||
let fname = substitute(a:fname,'^.\{-}zipfile:.\{-}::\([^\\].*\)$','\1','')
|
||||
let fname = substitute(fname, '[', '[[]', 'g')
|
||||
let fname = substitute(fname, '[', '[[]', 'g')
|
||||
endif
|
||||
" call Decho("zipfile<".zipfile.">")
|
||||
" call Decho("fname <".fname.">")
|
||||
|
||||
" call Decho("exe r! ".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fnameescape(fname),1))
|
||||
exe "keepj sil! r! ".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fnameescape(fname),1)
|
||||
" the following code does much the same thing as
|
||||
" exe "keepj sil! r! ".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fnameescape(fname),1)
|
||||
" but allows zipfile:... entries in quickfix lists
|
||||
let temp = tempname()
|
||||
let fn = expand('%:p')
|
||||
exe "sil! !".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fnameescape(fname),1).' > '.temp
|
||||
" call Decho("exe sil! !".g:zip_unzipcmd." -p -- ".s:Escape(zipfile,1)." ".s:Escape(fnameescape(fname),1).' > '.temp)
|
||||
sil exe 'keepalt file '.temp
|
||||
sil keepj e!
|
||||
sil exe 'keepalt file '.fnameescape(fn)
|
||||
call delete(temp)
|
||||
|
||||
filetype detect
|
||||
|
||||
" cleanup
|
||||
@@ -267,7 +277,7 @@ fun! zip#Write(fname)
|
||||
|
||||
if fname =~ '/'
|
||||
let dirpath = substitute(fname,'/[^/]\+$','','e')
|
||||
if executable("cygpath")
|
||||
if has("win32unix") && executable("cygpath")
|
||||
let dirpath = substitute(system("cygpath ".s:Escape(dirpath,0)),'\n','','e')
|
||||
endif
|
||||
" call Decho("mkdir(dirpath<".dirpath.">,p)")
|
||||
@@ -279,7 +289,7 @@ fun! zip#Write(fname)
|
||||
" call Decho("zipfile<".zipfile."> fname<".fname.">")
|
||||
|
||||
exe "w! ".fnameescape(fname)
|
||||
if executable("cygpath")
|
||||
if has("win32unix") && executable("cygpath")
|
||||
let zipfile = substitute(system("cygpath ".s:Escape(zipfile,0)),'\n','','e')
|
||||
endif
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
" vim: tw=0 ts=4 sw=4
|
||||
" Vim color file
|
||||
" Maintainer: Ron Aaron <ron@ronware.org>
|
||||
" Last Change: 2006 Dec 10
|
||||
" Last Change: 2013 May 23
|
||||
|
||||
hi clear
|
||||
set background=dark
|
||||
@@ -43,6 +43,8 @@ hi MatchParen term=reverse ctermfg=blue guibg=Blue
|
||||
hi TabLine term=bold,reverse cterm=bold ctermfg=lightblue ctermbg=white gui=bold guifg=blue guibg=white
|
||||
hi TabLineFill term=bold,reverse cterm=bold ctermfg=lightblue ctermbg=white gui=bold guifg=blue guibg=white
|
||||
hi TabLineSel term=reverse ctermfg=white ctermbg=lightblue guifg=white guibg=blue
|
||||
hi Underlined term=underline cterm=bold,underline ctermfg=lightblue guifg=lightblue gui=bold,underline
|
||||
hi Ignore ctermfg=black ctermbg=black guifg=black guibg=black
|
||||
hi link IncSearch Visual
|
||||
hi link String Constant
|
||||
hi link Character Constant
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
" vim: tw=0 ts=4 sw=4
|
||||
" Vim color file
|
||||
" Maintainer: Ron Aaron <ron@ronware.org>
|
||||
" Last Change: 2003 May 02
|
||||
" Last Change: 2013 May 24
|
||||
|
||||
set background=dark
|
||||
hi clear
|
||||
@@ -11,7 +11,7 @@ if exists("syntax_on")
|
||||
endif
|
||||
let g:colors_name = "ron"
|
||||
hi Normal guifg=cyan guibg=black
|
||||
hi NonText guifg=brown
|
||||
hi NonText guifg=yellow guibg=#303030
|
||||
hi comment guifg=green
|
||||
hi constant guifg=cyan gui=bold
|
||||
hi identifier guifg=cyan gui=NONE
|
||||
@@ -24,10 +24,11 @@ hi WarningMsg guifg=Black guibg=Green
|
||||
hi Error guibg=Red
|
||||
hi Todo guifg=Black guibg=orange
|
||||
hi Cursor guibg=#60a060 guifg=#00ff00
|
||||
hi Search guibg=lightslateblue
|
||||
hi Search guibg=darkgray guifg=black gui=bold
|
||||
hi IncSearch gui=NONE guibg=steelblue
|
||||
hi LineNr guifg=darkgrey
|
||||
hi title guifg=darkgrey
|
||||
hi ShowMarksHL ctermfg=cyan ctermbg=lightblue cterm=bold guifg=yellow guibg=black gui=bold
|
||||
hi StatusLineNC gui=NONE guifg=lightblue guibg=darkblue
|
||||
hi StatusLine gui=bold guifg=cyan guibg=blue
|
||||
hi label guifg=gold2
|
||||
@@ -41,3 +42,4 @@ hi DiffDelete guibg=coral
|
||||
hi Folded guibg=gray30
|
||||
hi FoldColumn guibg=gray30 guifg=white
|
||||
hi cIf0 guifg=gray
|
||||
hi diffOnly guifg=red gui=bold
|
||||
|
||||
23
runtime/compiler/haml.vim
Normal file
23
runtime/compiler/haml.vim
Normal file
@@ -0,0 +1,23 @@
|
||||
if exists("current_compiler")
|
||||
finish
|
||||
endif
|
||||
let current_compiler = "haml"
|
||||
|
||||
if exists(":CompilerSet") != 2 " older Vim always used :setlocal
|
||||
command -nargs=* CompilerSet setlocal <args>
|
||||
endif
|
||||
|
||||
let s:cpo_save = &cpo
|
||||
set cpo-=C
|
||||
|
||||
CompilerSet makeprg=haml\ -c
|
||||
|
||||
CompilerSet errorformat=
|
||||
\Haml\ %trror\ on\ line\ %l:\ %m,
|
||||
\Syntax\ %trror\ on\ line\ %l:\ %m,
|
||||
\%-G%.%#
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
unlet s:cpo_save
|
||||
|
||||
" vim:set sw=2 sts=2:
|
||||
21
runtime/compiler/msbuild.vim
Normal file
21
runtime/compiler/msbuild.vim
Normal file
@@ -0,0 +1,21 @@
|
||||
" Vim compiler file
|
||||
" Compiler: Microsoft Visual Studio C#
|
||||
" Maintainer: Chiel ten Brinke (ctje92@gmail.com)
|
||||
" Last Change: 2013 May 13
|
||||
|
||||
if exists("current_compiler")
|
||||
finish
|
||||
endif
|
||||
let current_compiler = "msbuild"
|
||||
let s:keepcpo= &cpo
|
||||
set cpo&vim
|
||||
|
||||
if exists(":CompilerSet") != 2 " older Vim always used :setlocal
|
||||
command -nargs=* CompilerSet setlocal <args>
|
||||
endif
|
||||
|
||||
CompilerSet errorformat=\ %#%f(%l\\\,%c):\ %m
|
||||
CompilerSet makeprg=msbuild\ /nologo\ /v:q\ /property:GenerateFullPaths=true
|
||||
|
||||
let &cpo = s:keepcpo
|
||||
unlet s:keepcpo
|
||||
25
runtime/compiler/sass.vim
Normal file
25
runtime/compiler/sass.vim
Normal file
@@ -0,0 +1,25 @@
|
||||
if exists("current_compiler")
|
||||
finish
|
||||
endif
|
||||
let current_compiler = "sass"
|
||||
|
||||
if exists(":CompilerSet") != 2 " older Vim always used :setlocal
|
||||
command -nargs=* CompilerSet setlocal <args>
|
||||
endif
|
||||
|
||||
let s:cpo_save = &cpo
|
||||
set cpo-=C
|
||||
|
||||
CompilerSet makeprg=sass\ -c
|
||||
|
||||
CompilerSet errorformat=
|
||||
\%f:%l:%m\ (Sass::Syntax%trror),
|
||||
\%ESyntax\ %trror:%m,
|
||||
\%C%\\s%\\+on\ line\ %l\ of\ %f,
|
||||
\%Z%.%#,
|
||||
\%-G%.%#
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
unlet s:cpo_save
|
||||
|
||||
" vim:set sw=2 sts=2:
|
||||
22
runtime/compiler/xbuild.vim
Normal file
22
runtime/compiler/xbuild.vim
Normal file
@@ -0,0 +1,22 @@
|
||||
" Vim compiler file
|
||||
" Compiler: Mono C#
|
||||
" Maintainer: Chiel ten Brinke (ctje92@gmail.com)
|
||||
" Last Change: 2013 May 13
|
||||
|
||||
if exists("current_compiler")
|
||||
finish
|
||||
endif
|
||||
|
||||
let current_compiler = "xbuild"
|
||||
let s:keepcpo= &cpo
|
||||
set cpo&vim
|
||||
|
||||
if exists(":CompilerSet") != 2 " older Vim always used :setlocal
|
||||
command -nargs=* CompilerSet setlocal <args>
|
||||
endif
|
||||
|
||||
CompilerSet errorformat=\ %#%f(%l\\\,%c):\ %m
|
||||
CompilerSet makeprg=xbuild\ /nologo\ /v:q\ /property:GenerateFullPaths=true
|
||||
|
||||
let &cpo = s:keepcpo
|
||||
unlet s:keepcpo
|
||||
@@ -1,4 +1,4 @@
|
||||
*autocmd.txt* For Vim version 7.3. Last change: 2012 Jul 10
|
||||
*autocmd.txt* For Vim version 7.3. Last change: 2013 May 19
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -263,8 +263,10 @@ Name triggered by ~
|
||||
Startup and exit
|
||||
|VimEnter| after doing all the startup stuff
|
||||
|GUIEnter| after starting the GUI successfully
|
||||
|GUIFailed| after starting the GUI failed
|
||||
|TermResponse| after the terminal response to |t_RV| is received
|
||||
|
||||
|QuitPre| when using `:quit`, before deciding whether to quit
|
||||
|VimLeavePre| before exiting Vim, before writing the viminfo file
|
||||
|VimLeave| before exiting Vim, after writing the viminfo file
|
||||
|
||||
@@ -312,6 +314,7 @@ Name triggered by ~
|
||||
|SessionLoadPost| after loading a session file
|
||||
|
||||
|MenuPopup| just before showing the popup menu
|
||||
|CompleteDone| after Insert mode completion is done
|
||||
|
||||
|User| to be used in combination with ":doautocmd"
|
||||
|
||||
@@ -516,8 +519,9 @@ CursorMoved After the cursor was moved in Normal mode.
|
||||
Not triggered when there is typeahead or when
|
||||
an operator is pending.
|
||||
For an example see |match-parens|.
|
||||
Careful: Don't do anything that the user does
|
||||
not expect or that is slow.
|
||||
Careful: This is triggered very often, don't
|
||||
do anything that the user does not expect or
|
||||
that is slow.
|
||||
*CursorMovedI*
|
||||
CursorMovedI After the cursor was moved in Insert mode.
|
||||
Not triggered when the popup menu is visible.
|
||||
@@ -687,8 +691,11 @@ InsertCharPre When a character is typed in Insert mode,
|
||||
InsertEnter Just before starting Insert mode. Also for
|
||||
Replace mode and Virtual Replace mode. The
|
||||
|v:insertmode| variable indicates the mode.
|
||||
Be careful not to move the cursor or do
|
||||
anything else that the user does not expect.
|
||||
Be careful not to do anything else that the
|
||||
user does not expect.
|
||||
The cursor is restored afterwards. If you do
|
||||
not want that set |v:char| to a non-empty
|
||||
string.
|
||||
*InsertLeave*
|
||||
InsertLeave When leaving Insert mode. Also when using
|
||||
CTRL-O |i_CTRL-O|. But not for |i_CTRL-C|.
|
||||
@@ -727,11 +734,11 @@ QuickFixCmdPost Like QuickFixCmdPre, but after a quickfix
|
||||
moving to the first error.
|
||||
See |QuickFixCmdPost-example|.
|
||||
*QuitPre*
|
||||
QuitPre When using `:quit`, before deciding whether it
|
||||
closes the current window or quits Vim. Can
|
||||
be used to close any non-essential window if
|
||||
the current window is the last ordinary
|
||||
window.
|
||||
QuitPre When using `:quit`, `:wq` or `:qall`, before
|
||||
deciding whether it closes the current window
|
||||
or quits Vim. Can be used to close any
|
||||
non-essential window if the current window is
|
||||
the last ordinary window.
|
||||
*RemoteReply*
|
||||
RemoteReply When a reply from a Vim that functions as
|
||||
server was received |server2client()|. The
|
||||
@@ -828,12 +835,27 @@ TermResponse After the response to |t_RV| is received from
|
||||
triggered halfway executing another event,
|
||||
especially if file I/O, a shell command or
|
||||
anything else that takes time is involved.
|
||||
*TextChanged*
|
||||
TextChanged After a change was made to the text in the
|
||||
current buffer in Normal mode. That is when
|
||||
|b:changedtick| has changed.
|
||||
Not triggered when there is typeahead or when
|
||||
an operator is pending.
|
||||
Careful: This is triggered very often, don't
|
||||
do anything that the user does not expect or
|
||||
that is slow.
|
||||
*TextChangedI*
|
||||
TextChangedI After a change was made to the text in the
|
||||
current buffer in Insert mode.
|
||||
Not triggered when the popup menu is visible.
|
||||
Otherwise the same as TextChanged.
|
||||
*User*
|
||||
User Never executed automatically. To be used for
|
||||
autocommands that are only executed with
|
||||
":doautocmd".
|
||||
*UserGettingBored*
|
||||
UserGettingBored When the user hits CTRL-C. Just kidding! :-)
|
||||
UserGettingBored When the user presses the same key 42 times.
|
||||
Just kidding! :-)
|
||||
*VimEnter*
|
||||
VimEnter After doing all the startup stuff, including
|
||||
loading .vimrc files, executing the "-c cmd"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*change.txt* For Vim version 7.3. Last change: 2012 Aug 08
|
||||
*change.txt* For Vim version 7.3. Last change: 2013 Mar 19
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -598,8 +598,11 @@ For other systems the tmpnam() library function is used.
|
||||
the flags.
|
||||
|
||||
*g&*
|
||||
g& Synonym for `:%s//~/&` (repeat last substitute on all
|
||||
lines with the same flags).
|
||||
g& Synonym for `:%s//~/&` (repeat last substitute with
|
||||
last search pattern on all lines with the same flags).
|
||||
For example, when you first do a substitution with
|
||||
`:s/pattern/repl/flags` and then `/search` for
|
||||
something else, `g&` will do `:%s/search/repl/flags`.
|
||||
Mnemonic: global substitute. {not in Vi}
|
||||
|
||||
*:snomagic* *:sno*
|
||||
@@ -781,6 +784,11 @@ Examples: >
|
||||
:s/abcde/abc^Mde/ modifies "abcde" to "abc", "de" (two lines)
|
||||
:s/$/\^M/ modifies "abcde" to "abcde^M"
|
||||
:s/\w\+/\u\0/g modifies "bla bla" to "Bla Bla"
|
||||
:s/\w\+/\L\u/g modifies "BLA bla" to "Bla Bla"
|
||||
|
||||
Note: "\L\u" can be used to capitalize the first letter of a word. This is
|
||||
not compatible with Vi and older versions of Vim, where the "\u" would cancel
|
||||
out the "\L". Same for "\U\l".
|
||||
|
||||
Note: In previous versions CTRL-V was handled in a special way. Since this is
|
||||
not Vi compatible, this was removed. Use a backslash instead.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*cmdline.txt* For Vim version 7.3. Last change: 2012 Jun 20
|
||||
*cmdline.txt* For Vim version 7.3. Last change: 2013 Mar 16
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -217,7 +217,7 @@ CTRL-\ e {expr} *c_CTRL-\_e*
|
||||
:return cmd
|
||||
:endfunc
|
||||
< This doesn't work recursively, thus not when already editing
|
||||
an expression.
|
||||
an expression. But it is possible to use in a mapping.
|
||||
|
||||
*c_CTRL-Y*
|
||||
CTRL-Y When there is a modeless selection, copy the selection into
|
||||
@@ -714,10 +714,15 @@ three lines: >
|
||||
Visual Mode and Range *v_:*
|
||||
|
||||
{Visual}: Starts a command-line with the Visual selected lines as a
|
||||
range. The code ":'<,'>" is used for this range, which makes
|
||||
range. The code `:'<,'>` is used for this range, which makes
|
||||
it possible to select a similar line from the command-line
|
||||
history for repeating a command on different Visually selected
|
||||
lines.
|
||||
When Visual mode was already ended, a short way to use the
|
||||
Visual area for a range is `:*`. This requires that "*" does
|
||||
not appear in 'cpo', see |cpo-star|. Otherwise you will have
|
||||
to type `:'<,'>`
|
||||
|
||||
|
||||
==============================================================================
|
||||
5. Ex command-line flags *ex-flags*
|
||||
@@ -959,7 +964,7 @@ for the file "$home" in the root directory. A few examples:
|
||||
\\$home file "\\", followed by expanded $home
|
||||
|
||||
==============================================================================
|
||||
6. Command-line window *cmdline-window* *cmdwin*
|
||||
7. Command-line window *cmdline-window* *cmdwin*
|
||||
*command-line-window*
|
||||
In the command-line window the command line can be edited just like editing
|
||||
text in any window. It is a special kind of window, because you cannot leave
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*develop.txt* For Vim version 7.3. Last change: 2012 Jan 10
|
||||
*develop.txt* For Vim version 7.3. Last change: 2013 Apr 27
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -20,6 +20,7 @@ code.
|
||||
Vim is open source software. Everybody is encouraged to contribute to help
|
||||
improving Vim. For sending patches a context diff "diff -c" is preferred.
|
||||
Also see http://www.vim.org/tips/tip.php?tip_id=618.
|
||||
Also see http://vim.wikia.com/wiki/How_to_make_and_submit_a_patch.
|
||||
|
||||
==============================================================================
|
||||
1. Design goals *design-goals*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*diff.txt* For Vim version 7.3. Last change: 2012 Aug 08
|
||||
*diff.txt* For Vim version 7.3. Last change: 2012 Sep 05
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -86,16 +86,16 @@ diff mode. You could use a construct like this: >
|
||||
While already in Vim you can start diff mode in three ways.
|
||||
|
||||
*E98*
|
||||
:diffsplit {filename} *:diffs* *:diffsplit*
|
||||
:diffs[plit] {filename} *:diffs* *:diffsplit*
|
||||
Open a new window on the file {filename}. The options are set
|
||||
as for "vimdiff" for the current and the newly opened window.
|
||||
Also see 'diffexpr'.
|
||||
|
||||
*:difft* *:diffthis*
|
||||
:diffthis Make the current window part of the diff windows. This sets
|
||||
:difft[his] Make the current window part of the diff windows. This sets
|
||||
the options like for "vimdiff".
|
||||
|
||||
:diffpatch {patchfile} *E816* *:diffp* *:diffpatch*
|
||||
:diffp[atch] {patchfile} *E816* *:diffp* *:diffpatch*
|
||||
Use the current buffer, patch it with the diff found in
|
||||
{patchfile} and open a buffer on the result. The options are
|
||||
set as for "vimdiff".
|
||||
@@ -123,9 +123,9 @@ Since the option values are remembered with the buffer, you can edit another
|
||||
file for a moment and come back to the same file and be in diff mode again.
|
||||
|
||||
*:diffo* *:diffoff*
|
||||
:diffoff Switch off diff mode for the current window.
|
||||
:diffo[ff] Switch off diff mode for the current window.
|
||||
|
||||
:diffoff! Switch off diff mode for the current window and in all windows
|
||||
:diffo[ff]! Switch off diff mode for the current window and in all windows
|
||||
in the current tab page where 'diff' is set.
|
||||
|
||||
The ":diffoff" command resets the relevant options to their default value.
|
||||
@@ -220,7 +220,7 @@ The diffs are highlighted with these groups:
|
||||
that parts in the middle that are still the
|
||||
same are highlighted anyway. Only "iwhite" of
|
||||
'diffopt' is used here.
|
||||
|hl-DiffDelete| DiffDelete Deleted lines. Also called filler lines,
|
||||
|hl-DiffDelete| DiffDelete Deleted lines. Also called filler lines,
|
||||
because they don't really exist in this
|
||||
buffer.
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*editing.txt* For Vim version 7.3. Last change: 2012 Aug 08
|
||||
*editing.txt* For Vim version 7.3. Last change: 2013 Feb 07
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -424,7 +424,7 @@ external command, by using the syntax `={expr}` e.g.: >
|
||||
:e `=tempname()`
|
||||
The expression can contain just about anything, thus this can also be used to
|
||||
avoid the special meaning of '"', '|', '%' and '#'. However, 'wildignore'
|
||||
does apply like to other wildcars.
|
||||
does apply like to other wildcards.
|
||||
If the expression returns a string then names are to be separated with line
|
||||
breaks. When the result is a |List| then each item is used as a name. Line
|
||||
breaks also separate names.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*eval.txt* For Vim version 7.3. Last change: 2012 Aug 02
|
||||
*eval.txt* For Vim version 7.3. Last change: 2013 May 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -91,8 +91,8 @@ For boolean operators Numbers are used. Zero is FALSE, non-zero is TRUE.
|
||||
Note that in the command >
|
||||
:if "foo"
|
||||
"foo" is converted to 0, which means FALSE. To test for a non-empty string,
|
||||
use strlen(): >
|
||||
:if strlen("foo")
|
||||
use empty(): >
|
||||
:if !empty("foo")
|
||||
< *E745* *E728* *E703* *E729* *E730* *E731*
|
||||
List, Dictionary and Funcref types are not automatically converted.
|
||||
|
||||
@@ -503,7 +503,7 @@ This removes all entries from "dict" with a value not matching 'x'.
|
||||
|
||||
|
||||
Dictionary function ~
|
||||
*Dictionary-function* *self* *E725*
|
||||
*Dictionary-function* *self* *E725* *E862*
|
||||
When a function is defined with the "dict" attribute it can be used in a
|
||||
special way with a dictionary. Example: >
|
||||
:function Mylen() dict
|
||||
@@ -759,7 +759,7 @@ of a |List| is different from the original |List|. When using "is" without
|
||||
a |List| or a |Dictionary| it is equivalent to using "equal", using "isnot"
|
||||
equivalent to using "not equal". Except that a different type means the
|
||||
values are different: "4 == '4'" is true, "4 is '4'" is false and "0 is []" is
|
||||
false and not a error. "is#"/"isnot#" and "is?"/"isnot?" can be used to match
|
||||
false and not an error. "is#"/"isnot#" and "is?"/"isnot?" can be used to match
|
||||
and ignore case.
|
||||
|
||||
When comparing a String with a Number, the String is converted to a Number,
|
||||
@@ -1150,14 +1150,14 @@ delete all script-local variables: >
|
||||
: unlet s:[k]
|
||||
:endfor
|
||||
<
|
||||
*buffer-variable* *b:var*
|
||||
*buffer-variable* *b:var* *b:*
|
||||
A variable name that is preceded with "b:" is local to the current buffer.
|
||||
Thus you can have several "b:foo" variables, one for each buffer.
|
||||
This kind of variable is deleted when the buffer is wiped out or deleted with
|
||||
|:bdelete|.
|
||||
|
||||
One local buffer variable is predefined:
|
||||
*b:changedtick-variable* *changetick*
|
||||
*b:changedtick* *changetick*
|
||||
b:changedtick The total number of changes to the current buffer. It is
|
||||
incremented for each change. An undo command is also a change
|
||||
in this case. This can be used to perform an action only when
|
||||
@@ -1167,21 +1167,21 @@ b:changedtick The total number of changes to the current buffer. It is
|
||||
: call My_Update()
|
||||
:endif
|
||||
<
|
||||
*window-variable* *w:var*
|
||||
*window-variable* *w:var* *w:*
|
||||
A variable name that is preceded with "w:" is local to the current window. It
|
||||
is deleted when the window is closed.
|
||||
|
||||
*tabpage-variable* *t:var*
|
||||
*tabpage-variable* *t:var* *t:*
|
||||
A variable name that is preceded with "t:" is local to the current tab page,
|
||||
It is deleted when the tab page is closed. {not available when compiled
|
||||
without the |+windows| feature}
|
||||
|
||||
*global-variable* *g:var*
|
||||
*global-variable* *g:var* *g:*
|
||||
Inside functions global variables are accessed with "g:". Omitting this will
|
||||
access a variable local to a function. But "g:" can also be used in any other
|
||||
place if you like.
|
||||
|
||||
*local-variable* *l:var*
|
||||
*local-variable* *l:var* *l:*
|
||||
Inside functions local variables are accessed without prepending anything.
|
||||
But you can also prepend "l:" if you like. However, without prepending "l:"
|
||||
you may run into reserved variable names. For example "count". By itself it
|
||||
@@ -1264,7 +1264,7 @@ Note that this means that filetype plugins don't get a different set of script
|
||||
variables for each buffer. Use local buffer variables instead |b:var|.
|
||||
|
||||
|
||||
Predefined Vim variables: *vim-variable* *v:var*
|
||||
Predefined Vim variables: *vim-variable* *v:var* *v:*
|
||||
|
||||
*v:beval_col* *beval_col-variable*
|
||||
v:beval_col The number of the column, over which the mouse pointer is.
|
||||
@@ -1297,7 +1297,7 @@ v:beval_winnr The number of the window, over which the mouse pointer is. Only
|
||||
*v:char* *char-variable*
|
||||
v:char Argument for evaluating 'formatexpr' and used for the typed
|
||||
character when using <expr> in an abbreviation |:map-<expr>|.
|
||||
It is also used by the |InsertCharPre| event.
|
||||
It is also used by the |InsertCharPre| and |InsertEnter| events.
|
||||
|
||||
*v:charconvert_from* *charconvert_from-variable*
|
||||
v:charconvert_from
|
||||
@@ -1716,7 +1716,7 @@ call( {func}, {arglist} [, {dict}])
|
||||
any call {func} with arguments {arglist}
|
||||
ceil( {expr}) Float round {expr} up
|
||||
changenr() Number current change number
|
||||
char2nr( {expr}) Number ASCII value of first char in {expr}
|
||||
char2nr( {expr}[, {utf8}]) Number ASCII/UTF8 value of first char in {expr}
|
||||
cindent( {lnum}) Number C indent for line {lnum}
|
||||
clearmatches() none clear all matches
|
||||
col( {expr}) Number column nr of cursor or mark
|
||||
@@ -1777,7 +1777,8 @@ get( {list}, {idx} [, {def}]) any get item {idx} from {list} or {def}
|
||||
get( {dict}, {key} [, {def}]) any get item {key} from {dict} or {def}
|
||||
getbufline( {expr}, {lnum} [, {end}])
|
||||
List lines {lnum} to {end} of buffer {expr}
|
||||
getbufvar( {expr}, {varname}) any variable {varname} in buffer {expr}
|
||||
getbufvar( {expr}, {varname} [, {def}])
|
||||
any variable {varname} in buffer {expr}
|
||||
getchar( [expr]) Number get one character from the user
|
||||
getcharmod( ) Number modifiers for the last typed character
|
||||
getcmdline() String return the current command-line
|
||||
@@ -1798,12 +1799,14 @@ getpos( {expr}) List position of cursor, mark, etc.
|
||||
getqflist() List list of quickfix items
|
||||
getreg( [{regname} [, 1]]) String contents of register
|
||||
getregtype( [{regname}]) String type of register
|
||||
gettabvar( {nr}, {varname}) any variable {varname} in tab {nr}
|
||||
gettabwinvar( {tabnr}, {winnr}, {name})
|
||||
gettabvar( {nr}, {varname} [, {def}])
|
||||
any variable {varname} in tab {nr} or {def}
|
||||
gettabwinvar( {tabnr}, {winnr}, {name} [, {def}])
|
||||
any {name} in {winnr} in tab page {tabnr}
|
||||
getwinposx() Number X coord in pixels of GUI Vim window
|
||||
getwinposy() Number Y coord in pixels of GUI Vim window
|
||||
getwinvar( {nr}, {varname}) any variable {varname} in window {nr}
|
||||
getwinvar( {nr}, {varname} [, {def}])
|
||||
any variable {varname} in window {nr}
|
||||
glob( {expr} [, {nosuf} [, {list}]])
|
||||
any expand file wildcards in {expr}
|
||||
globpath( {path}, {expr} [, {flag}])
|
||||
@@ -1873,7 +1876,7 @@ mkdir( {name} [, {path} [, {prot}]])
|
||||
mode( [expr]) String current editing mode
|
||||
mzeval( {expr}) any evaluate |MzScheme| expression
|
||||
nextnonblank( {lnum}) Number line nr of non-blank line >= {lnum}
|
||||
nr2char( {expr}) String single char with ASCII value {expr}
|
||||
nr2char( {expr}[, {utf8}]) String single char with ASCII/UTF8 value {expr}
|
||||
or( {expr}, {expr}) Number bitwise OR
|
||||
pathshorten( {expr}) String shorten directory names in a path
|
||||
pow( {x}, {y}) Float {x} to the power of {y}
|
||||
@@ -1903,6 +1906,8 @@ repeat( {expr}, {count}) String repeat {expr} {count} times
|
||||
resolve( {filename}) String get filename a shortcut points to
|
||||
reverse( {list}) List reverse {list} in-place
|
||||
round( {expr}) Float round off {expr}
|
||||
screencol() Number current cursor column
|
||||
screenrow() Number current cursor row
|
||||
search( {pattern} [, {flags} [, {stopline} [, {timeout}]]])
|
||||
Number search for {pattern}
|
||||
searchdecl( {name} [, {global} [, {thisblock}]])
|
||||
@@ -1929,9 +1934,11 @@ settabvar( {nr}, {varname}, {val}) set {varname} in tab page {nr} to {val}
|
||||
settabwinvar( {tabnr}, {winnr}, {varname}, {val}) set {varname} in window
|
||||
{winnr} in tab page {tabnr} to {val}
|
||||
setwinvar( {nr}, {varname}, {val}) set {varname} in window {nr} to {val}
|
||||
sha256( {string}) String SHA256 checksum of {string}
|
||||
shellescape( {string} [, {special}])
|
||||
String escape {string} for use as shell
|
||||
command argument
|
||||
shiftwidth() Number effective value of 'shiftwidth'
|
||||
simplify( {filename}) String simplify filename as much as possible
|
||||
sin( {expr}) Float sine of {expr}
|
||||
sinh( {expr}) Float hyperbolic sine of {expr}
|
||||
@@ -1989,6 +1996,7 @@ undotree() List undo file tree
|
||||
values( {dict}) List values in {dict}
|
||||
virtcol( {expr}) Number screen column of cursor or mark
|
||||
visualmode( [expr]) String last visual mode used
|
||||
wildmenumode() Number whether 'wildmenu' mode is active
|
||||
winbufnr( {nr}) Number buffer number of window {nr}
|
||||
wincol() Number window column of the cursor
|
||||
winheight( {nr}) Number height of window {nr}
|
||||
@@ -2291,14 +2299,16 @@ changenr() *changenr()*
|
||||
redo it is the number of the redone change. After undo it is
|
||||
one less than the number of the undone change.
|
||||
|
||||
char2nr({expr}) *char2nr()*
|
||||
char2nr({expr}[, {utf8}]) *char2nr()*
|
||||
Return number value of the first char in {expr}. Examples: >
|
||||
char2nr(" ") returns 32
|
||||
char2nr("ABC") returns 65
|
||||
< The current 'encoding' is used. Example for "utf-8": >
|
||||
< When {utf8} is omitted or zero, the current 'encoding' is used.
|
||||
Example for "utf-8": >
|
||||
char2nr("<22>") returns 225
|
||||
char2nr("<22>"[0]) returns 195
|
||||
< A combining character is a separate character.
|
||||
< With {utf8} set to 1, always treat as utf-8 characters.
|
||||
A combining character is a separate character.
|
||||
|nr2char()| does the opposite.
|
||||
|
||||
cindent({lnum}) *cindent()*
|
||||
@@ -2573,6 +2583,8 @@ delete({fname}) *delete()*
|
||||
which is 0 if the file was deleted successfully, and non-zero
|
||||
when the deletion failed.
|
||||
Use |remove()| to delete an item from a |List|.
|
||||
To delete a line from the buffer use |:delete|. Use |:exe|
|
||||
when the line number is in a variable.
|
||||
|
||||
*did_filetype()*
|
||||
did_filetype() Returns non-zero when autocommands are being executed and the
|
||||
@@ -3136,7 +3148,7 @@ getbufline({expr}, {lnum} [, {end}])
|
||||
Example: >
|
||||
:let lines = getbufline(bufnr("myfile"), 1, "$")
|
||||
|
||||
getbufvar({expr}, {varname}) *getbufvar()*
|
||||
getbufvar({expr}, {varname} [, {def}]) *getbufvar()*
|
||||
The result is the value of option or local buffer variable
|
||||
{varname} in buffer {expr}. Note that the name without "b:"
|
||||
must be used.
|
||||
@@ -3146,8 +3158,8 @@ getbufvar({expr}, {varname}) *getbufvar()*
|
||||
doesn't work for a global variable, window-local variable or
|
||||
window-local option.
|
||||
For the use of {expr}, see |bufname()| above.
|
||||
When the buffer or variable doesn't exist an empty string is
|
||||
returned, there is no error message.
|
||||
When the buffer or variable doesn't exist {def} or an empty
|
||||
string is returned, there is no error message.
|
||||
Examples: >
|
||||
:let bufmodified = getbufvar(1, "&mod")
|
||||
:echo "todo myvar = " . getbufvar("todo", "myvar")
|
||||
@@ -3424,26 +3436,30 @@ getregtype([{regname}]) *getregtype()*
|
||||
<CTRL-V> is one character with value 0x16.
|
||||
If {regname} is not specified, |v:register| is used.
|
||||
|
||||
gettabvar({tabnr}, {varname}) *gettabvar()*
|
||||
gettabvar({tabnr}, {varname} [, {def}]) *gettabvar()*
|
||||
Get the value of a tab-local variable {varname} in tab page
|
||||
{tabnr}. |t:var|
|
||||
Tabs are numbered starting with one.
|
||||
Note that the name without "t:" must be used.
|
||||
When the tab or variable doesn't exist {def} or an empty
|
||||
string is returned, there is no error message.
|
||||
|
||||
gettabwinvar({tabnr}, {winnr}, {varname}) *gettabwinvar()*
|
||||
gettabwinvar({tabnr}, {winnr}, {varname} [, {def}]) *gettabwinvar()*
|
||||
Get the value of window-local variable {varname} in window
|
||||
{winnr} in tab page {tabnr}.
|
||||
When {varname} starts with "&" get the value of a window-local
|
||||
option.
|
||||
When {varname} is empty a dictionary with all window-local
|
||||
variables is returned.
|
||||
Note that {varname} must be the name without "w:".
|
||||
Tabs are numbered starting with one. For the current tabpage
|
||||
use |getwinvar()|.
|
||||
When {winnr} is zero the current window is used.
|
||||
This also works for a global option, buffer-local option and
|
||||
window-local option, but it doesn't work for a global variable
|
||||
or buffer-local variable.
|
||||
When {varname} is empty a dictionary with all window-local
|
||||
variables is returned.
|
||||
Note that {varname} must be the name without "w:".
|
||||
When the tab, window or variable doesn't exist {def} or an
|
||||
empty string is returned, there is no error message.
|
||||
Examples: >
|
||||
:let list_is_on = gettabwinvar(1, 2, '&list')
|
||||
:echo "myvar = " . gettabwinvar(3, 1, 'myvar')
|
||||
@@ -3458,7 +3474,7 @@ getwinposy() The result is a Number, which is the Y coordinate in pixels of
|
||||
the top of the GUI Vim window. The result will be -1 if the
|
||||
information is not available.
|
||||
|
||||
getwinvar({winnr}, {varname}) *getwinvar()*
|
||||
getwinvar({winnr}, {varname} [, {def}]) *getwinvar()*
|
||||
Like |gettabwinvar()| for the current tabpage.
|
||||
Examples: >
|
||||
:let list_is_on = getwinvar(2, '&list')
|
||||
@@ -3754,10 +3770,10 @@ inputdialog({prompt} [, {text} [, {cancelreturn}]]) *inputdialog()*
|
||||
Like |input()|, but when the GUI is running and text dialogs
|
||||
are supported, a dialog window pops up to input the text.
|
||||
Example: >
|
||||
:let n = inputdialog("value for shiftwidth", &sw)
|
||||
:if n != ""
|
||||
: let &sw = n
|
||||
:endif
|
||||
:let n = inputdialog("value for shiftwidth", shiftwidth())
|
||||
:if n != ""
|
||||
: let &sw = n
|
||||
:endif
|
||||
< When the dialog is cancelled {cancelreturn} is returned. When
|
||||
omitted an empty string is returned.
|
||||
Hitting <Enter> works like pressing the OK button. Hitting
|
||||
@@ -4368,14 +4384,16 @@ nextnonblank({lnum}) *nextnonblank()*
|
||||
below it, zero is returned.
|
||||
See also |prevnonblank()|.
|
||||
|
||||
nr2char({expr}) *nr2char()*
|
||||
nr2char({expr}[, {utf8}]) *nr2char()*
|
||||
Return a string with a single character, which has the number
|
||||
value {expr}. Examples: >
|
||||
nr2char(64) returns "@"
|
||||
nr2char(32) returns " "
|
||||
< The current 'encoding' is used. Example for "utf-8": >
|
||||
< When {utf8} is omitted or zero, the current 'encoding' is used.
|
||||
Example for "utf-8": >
|
||||
nr2char(300) returns I with bow character
|
||||
< Note that a NUL character in the file is specified with
|
||||
< With {utf8} set to 1, always return utf-8 characters.
|
||||
Note that a NUL character in the file is specified with
|
||||
nr2char(10), because NULs are represented with newline
|
||||
characters. nr2char(0) is a real NUL and terminates the
|
||||
string, thus results in an empty string.
|
||||
@@ -4450,6 +4468,7 @@ printf({fmt}, {expr1} ...) *printf()*
|
||||
|
||||
Often used items are:
|
||||
%s string
|
||||
%6S string right-aligned in 6 display cells
|
||||
%6s string right-aligned in 6 bytes
|
||||
%.9s string truncated to 9 bytes
|
||||
%c single byte
|
||||
@@ -4564,6 +4583,10 @@ printf({fmt}, {expr1} ...) *printf()*
|
||||
s The text of the String argument is used. If a
|
||||
precision is specified, no more bytes than the number
|
||||
specified are used.
|
||||
S The text of the String argument is used. If a
|
||||
precision is specified, no more display cells than the
|
||||
number specified are used. Without the |+multi_byte|
|
||||
feature works just like 's'.
|
||||
|
||||
*printf-f* *E807*
|
||||
f The Float argument is converted into a string of the
|
||||
@@ -4616,7 +4639,7 @@ pumvisible() *pumvisible()*
|
||||
This can be used to avoid some things that would remove the
|
||||
popup menu.
|
||||
|
||||
*E860* *E861*
|
||||
*E860*
|
||||
py3eval({expr}) *py3eval()*
|
||||
Evaluate Python expression {expr} and return its result
|
||||
converted to Vim data structures.
|
||||
@@ -4635,8 +4658,8 @@ pyeval({expr}) *pyeval()*
|
||||
Numbers and strings are returned as they are (strings are
|
||||
copied though).
|
||||
Lists are represented as Vim |List| type.
|
||||
Dictionaries are represented as Vim |Dictionary| type with
|
||||
keys converted to strings.
|
||||
Dictionaries are represented as Vim |Dictionary| type,
|
||||
non-string keys result in error.
|
||||
{only available when compiled with the |+python| feature}
|
||||
|
||||
*E726* *E727*
|
||||
@@ -4866,15 +4889,34 @@ round({expr}) *round()*
|
||||
echo round(-4.5)
|
||||
< -5.0
|
||||
{only available when compiled with the |+float| feature}
|
||||
|
||||
|
||||
|
||||
screencol() *screencol()*
|
||||
The result is a Number, which is the current screen column of
|
||||
the cursor. The leftmost column has number 1.
|
||||
This function is mainly used for testing.
|
||||
|
||||
Note: Always returns the current screen column, thus if used
|
||||
in a command (e.g. ":echo screencol()") it will return the
|
||||
column inside the command line, which is 1 when the command is
|
||||
executed. To get the cursor position in the file use one of
|
||||
the following mappings: >
|
||||
nnoremap <expr> GG ":echom ".screencol()."\n"
|
||||
nnoremap <silent> GG :echom screencol()<CR>
|
||||
<
|
||||
screenrow() *screenrow()*
|
||||
The result is a Number, which is the current screen row of the
|
||||
cursor. The top line has number one.
|
||||
This function is mainly used for testing.
|
||||
|
||||
Note: Same restrictions as with |screencol()|.
|
||||
|
||||
search({pattern} [, {flags} [, {stopline} [, {timeout}]]]) *search()*
|
||||
Search for regexp pattern {pattern}. The search starts at the
|
||||
cursor position (you can use |cursor()| to set it).
|
||||
|
||||
When a match has been found its line number is returned.
|
||||
If there is no match a 0 is returned and the cursor doesn't
|
||||
move. No error message is given.
|
||||
When a match has been found its line number is returned.
|
||||
|
||||
{flags} is a String, which can contain these character flags:
|
||||
'b' search backward instead of forward
|
||||
@@ -5253,8 +5295,9 @@ setreg({regname}, {value} [,{options}])
|
||||
|
||||
If {options} contains no register settings, then the default
|
||||
is to use character mode unless {value} ends in a <NL>.
|
||||
Setting the '=' register is not possible.
|
||||
Returns zero for success, non-zero for failure.
|
||||
Setting the '=' register is not possible, but you can use >
|
||||
:let @= = var_expr
|
||||
< Returns zero for success, non-zero for failure.
|
||||
|
||||
Examples: >
|
||||
:call setreg(v:register, @*)
|
||||
@@ -5277,8 +5320,6 @@ settabvar({tabnr}, {varname}, {val}) *settabvar()*
|
||||
|t:var|
|
||||
Note that the variable name without "t:" must be used.
|
||||
Tabs are numbered starting with one.
|
||||
Vim briefly goes to the tab page {tabnr}, this may trigger
|
||||
TabLeave and TabEnter autocommands.
|
||||
This function is not available in the |sandbox|.
|
||||
|
||||
settabwinvar({tabnr}, {winnr}, {varname}, {val}) *settabwinvar()*
|
||||
@@ -5291,8 +5332,6 @@ settabwinvar({tabnr}, {winnr}, {varname}, {val}) *settabwinvar()*
|
||||
doesn't work for a global or local buffer variable.
|
||||
For a local buffer option the global value is unchanged.
|
||||
Note that the variable name without "w:" must be used.
|
||||
Vim briefly goes to the tab page {tabnr}, this may trigger
|
||||
TabLeave and TabEnter autocommands.
|
||||
Examples: >
|
||||
:call settabwinvar(1, 1, "&list", 0)
|
||||
:call settabwinvar(3, 2, "myvar", "foobar")
|
||||
@@ -5304,6 +5343,11 @@ setwinvar({nr}, {varname}, {val}) *setwinvar()*
|
||||
:call setwinvar(1, "&list", 0)
|
||||
:call setwinvar(2, "myvar", "foobar")
|
||||
|
||||
sha256({string}) *sha256()*
|
||||
Returns a String with 64 hex charactes, which is the SHA256
|
||||
checksum of {string}.
|
||||
{only available when compiled with the |+cryptv| feature}
|
||||
|
||||
shellescape({string} [, {special}]) *shellescape()*
|
||||
Escape {string} for use as a shell command argument.
|
||||
On MS-Windows and MS-DOS, when 'shellslash' is not set, it
|
||||
@@ -5330,6 +5374,23 @@ shellescape({string} [, {special}]) *shellescape()*
|
||||
:call system("chmod +w -- " . shellescape(expand("%")))
|
||||
|
||||
|
||||
shiftwidth() *shiftwidth()*
|
||||
Returns the effective value of 'shiftwidth'. This is the
|
||||
'shiftwidth' value unless it is zero, in which case it is the
|
||||
'tabstop' value. To be backwards compatible in indent
|
||||
plugins, use this: >
|
||||
if exists('*shiftwidth')
|
||||
func s:sw()
|
||||
return shiftwidth()
|
||||
endfunc
|
||||
else
|
||||
func s:sw()
|
||||
return &sw
|
||||
endfunc
|
||||
endif
|
||||
< And then use s:sw() instead of &sw.
|
||||
|
||||
|
||||
simplify({filename}) *simplify()*
|
||||
Simplify the file name as much as possible without changing
|
||||
the meaning. Shortcuts (on MS-Windows) or symbolic links (on
|
||||
@@ -5459,7 +5520,8 @@ split({expr} [, {pattern} [, {keepempty}]]) *split()*
|
||||
empty each white-separated sequence of characters becomes an
|
||||
item.
|
||||
Otherwise the string is split where {pattern} matches,
|
||||
removing the matched characters.
|
||||
removing the matched characters. 'ignorecase' is not used
|
||||
here, add \c to ignore case. |/\c|
|
||||
When the first or last item is empty it is omitted, unless the
|
||||
{keepempty} argument is given and it's non-zero.
|
||||
Other empty items are kept when {pattern} matches at least one
|
||||
@@ -5669,8 +5731,10 @@ substitute({expr}, {pat}, {sub}, {flags}) *substitute()*
|
||||
This works like the ":substitute" command (without any flags).
|
||||
But the matching with {pat} is always done like the 'magic'
|
||||
option is set and 'cpoptions' is empty (to make scripts
|
||||
portable). 'ignorecase' is still relevant. 'smartcase' is
|
||||
not used. See |string-match| for how {pat} is used.
|
||||
portable). 'ignorecase' is still relevant, use |/\c| or |/\C|
|
||||
if you want to ignore or match case and ignore 'ignorecase'.
|
||||
'smartcase' is not used. See |string-match| for how {pat} is
|
||||
used.
|
||||
|
||||
A "~" in {sub} is not replaced with the previous {sub}.
|
||||
Note that some codes in {sub} have a special meaning
|
||||
@@ -5891,8 +5955,9 @@ taglist({expr}) *taglist()*
|
||||
If there are no matching tags, then an empty list is returned.
|
||||
|
||||
To get an exact tag match, the anchors '^' and '$' should be
|
||||
used in {expr}. Refer to |tag-regexp| for more information
|
||||
about the tag search regular expression pattern.
|
||||
used in {expr}. This also make the function work faster.
|
||||
Refer to |tag-regexp| for more information about the tag
|
||||
search regular expression pattern.
|
||||
|
||||
Refer to |'tags'| for information about how the tags file is
|
||||
located by Vim. Refer to |tags-file-format| for the format of
|
||||
@@ -6103,6 +6168,18 @@ visualmode([expr]) *visualmode()*
|
||||
Dictionary or Float is not a Number or String, thus does not
|
||||
cause the mode to be cleared.
|
||||
|
||||
wildmenumode() *wildmenumode()*
|
||||
Returns non-zero when the wildmenu is active and zero
|
||||
otherwise. See 'wildmenu' and 'wildmode'.
|
||||
This can be used in mappings to handle the 'wildcharm' option
|
||||
gracefully. (Makes only sense with |mapmode-c| mappings).
|
||||
|
||||
For example to make <c-j> work like <down> in wildmode, use: >
|
||||
:cnoremap <expr> <C-j> wildmenumode() ? "\<Down>\<Tab>" : "\<c-j>"
|
||||
<
|
||||
(Note, this needs the 'wildcharm' option set appropriately).
|
||||
|
||||
|
||||
*winbufnr()*
|
||||
winbufnr({nr}) The result is a Number, which is the number of the buffer
|
||||
associated with window {nr}. When {nr} is zero, the number of
|
||||
@@ -6135,8 +6212,9 @@ winline() The result is a Number, which is the screen line of the cursor
|
||||
winnr([{arg}]) The result is a Number, which is the number of the current
|
||||
window. The top window has number 1.
|
||||
When the optional argument is "$", the number of the
|
||||
last window is returned (the window count).
|
||||
When the optional argument is "#", the number of the last
|
||||
last window is returned (the window count). >
|
||||
let window_count = winnr('$')
|
||||
< When the optional argument is "#", the number of the last
|
||||
accessed window is returned (where |CTRL-W_p| goes to).
|
||||
If there is no previous window or it is in another tab page 0
|
||||
is returned.
|
||||
@@ -6507,6 +6585,8 @@ See |:verbose-cmd| for more information.
|
||||
is excluded, ":{range}call" will call the function for
|
||||
each line in the range, with the cursor on the start
|
||||
of each line. See |function-range-example|.
|
||||
The cursor is still moved to the first line of the
|
||||
range, as is the case with all Ex commands.
|
||||
|
||||
When the [abort] argument is added, the function will
|
||||
abort as soon as an error is detected.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.TH EVIM 1 "16 f<>vrier 2002 February 16"
|
||||
.TH EVIM 1 "16 f<>vrier 2002"
|
||||
.SH NAME
|
||||
evim \- <20> Easy Vim <20>, <20>dite un fichier avec Vim sans utiliser les modes
|
||||
.SH SYNOPSIS
|
||||
@@ -54,4 +54,4 @@ Voir le menu Aide/Remerciements ou ":help credits" dans
|
||||
.SH TRADUCTION
|
||||
Cette page de manuel a <20>t<EFBFBD> traduite David Blanchet.
|
||||
<david.blanchet@free.fr> 2005-03-26.
|
||||
Mise <20> jour 2012-05-06, Dominique Pell<6C> <dominique.pelle@gmail.com>
|
||||
Mise <20> jour 2013-05-10, Dominique Pell<6C> <dominique.pelle@gmail.com>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
.TH EVIM 1 "16 février 2002 February 16"
|
||||
.TH EVIM 1 "16 février 2002"
|
||||
.SH NAME
|
||||
evim \- « Easy Vim », édite un fichier avec Vim sans utiliser les modes
|
||||
.SH SYNOPSIS
|
||||
@@ -54,4 +54,4 @@ Voir le menu Aide/Remerciements ou ":help credits" dans
|
||||
.SH TRADUCTION
|
||||
Cette page de manuel a été traduite David Blanchet.
|
||||
<david.blanchet@free.fr> 2005-03-26.
|
||||
Mise à jour 2012-05-06, Dominique Pellé <dominique.pelle@gmail.com>
|
||||
Mise à jour 2013-05-10, Dominique Pellé <dominique.pelle@gmail.com>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*filetype.txt* For Vim version 7.3. Last change: 2011 Jun 19
|
||||
*filetype.txt* For Vim version 7.3. Last change: 2013 May 25
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -603,7 +603,7 @@ Since the text for this plugin is rather long it has been put in a separate
|
||||
file: |ft_sql.txt|.
|
||||
|
||||
|
||||
TEX *ft-tex-plugin*
|
||||
TEX *ft-tex-plugin* *g:tex_flavor*
|
||||
|
||||
If the first line of a *.tex file has the form >
|
||||
%&<format>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*ft_sql.txt* For Vim version 7.3. Last change: 2010 Jul 20
|
||||
*ft_sql.txt* For Vim version 7.3. Last change: 2013 May 15
|
||||
|
||||
by David Fishburn
|
||||
|
||||
@@ -349,6 +349,7 @@ may not work properly on all platforms: >
|
||||
The static maps (which are based on the syntax highlight groups) follow this
|
||||
format: >
|
||||
imap <buffer> <C-C>k <C-\><C-O>:call sqlcomplete#Map('sqlKeyword')<CR><C-X><C-O>
|
||||
imap <buffer> <C-C>k <C-\><C-O>:call sqlcomplete#Map('sqlKeyword\w*')<CR><C-X><C-O>
|
||||
|
||||
This command breaks down as: >
|
||||
imap - Create an insert map
|
||||
@@ -369,6 +370,9 @@ This command breaks down as: >
|
||||
command while editing a SQL file.
|
||||
'sqlKeyword' - Display the items for the sqlKeyword highlight
|
||||
group
|
||||
'sqlKeyword\w*' - A second option available with Vim 7.4 which
|
||||
uses a regular expression to determine which
|
||||
syntax groups to use
|
||||
)<CR> - Execute the :let command
|
||||
<C-X><C-O> - Trigger the standard omni completion key stroke.
|
||||
Passing in 'sqlKeyword' instructs the SQL
|
||||
@@ -435,7 +439,7 @@ the space bar):
|
||||
of columns, you can press <Left>, this will
|
||||
replace the column list with the list of tables.
|
||||
- This allows you to quickly drill down into a
|
||||
table to view it's columns and back again.
|
||||
table to view its columns and back again.
|
||||
- <Right> and <Left> can be also be chosen via
|
||||
your |.vimrc| >
|
||||
let g:ftplugin_sql_omni_key_right = '<Right>'
|
||||
@@ -645,7 +649,7 @@ your |vimrc|: >
|
||||
- When completing tables, procedure or views and using dbext.vim 3.00
|
||||
or higher the list of objects will also include the owner name.
|
||||
When completing these objects and omni_sql_include_owner is enabled
|
||||
the owner name will be be replaced. >
|
||||
the owner name will be replaced. >
|
||||
|
||||
omni_sql_precache_syntax_groups
|
||||
< - Default:
|
||||
|
||||
@@ -16,7 +16,7 @@ Vim's Graphical User Interface *gui-w16* *win16-gui*
|
||||
|
||||
Other relevant documentation:
|
||||
|gui.txt| For generic items of the GUI.
|
||||
|os_msdos.txt| For items common to DOS and Windows.
|
||||
|os_msdos.txt| For items common to DOS and Windows.
|
||||
|gui_w32.txt| Some items here are also applicable to the Win16 version.
|
||||
|
||||
{Vi does not have a Windows GUI}
|
||||
|
||||
@@ -17,7 +17,7 @@ Vim's Win32 Graphical User Interface *gui-w32* *win32-gui*
|
||||
|
||||
Other relevant documentation:
|
||||
|gui.txt| For generic items of the GUI.
|
||||
|os_win32.txt| For Win32 specific items.
|
||||
|os_win32.txt| For Win32 specific items.
|
||||
|
||||
{Vi does not have a Windows GUI}
|
||||
|
||||
|
||||
@@ -93,7 +93,7 @@ Details
|
||||
This is also the keymap when 'keymap=hebrew' is set. The advantage of
|
||||
'keymap' is that it works properly when using UTF8, e.g. it inserts the
|
||||
correct characters; 'hkmap' does not. The 'keymap' keyboard can also
|
||||
insert niqud and te`amim. To see what those mappings are,look at the
|
||||
insert niqud and te`amim. To see what those mappings are, look at the
|
||||
keymap file 'hebrew.vim' etc.
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*help.txt* For Vim version 7.3. Last change: 2010 Jul 20
|
||||
*help.txt* For Vim version 7.3. Last change: 2012 Dec 06
|
||||
|
||||
VIM - main help file
|
||||
k
|
||||
@@ -195,12 +195,12 @@ Remarks about specific systems ~
|
||||
*standard-plugin-list*
|
||||
Standard plugins ~
|
||||
|pi_getscript.txt| Downloading latest version of Vim scripts
|
||||
|pi_gzip.txt| Reading and writing compressed files
|
||||
|pi_netrw.txt| Reading and writing files over a network
|
||||
|pi_paren.txt| Highlight matching parens
|
||||
|pi_tar.txt| Tar file explorer
|
||||
|pi_gzip.txt| Reading and writing compressed files
|
||||
|pi_netrw.txt| Reading and writing files over a network
|
||||
|pi_paren.txt| Highlight matching parens
|
||||
|pi_tar.txt| Tar file explorer
|
||||
|pi_vimball.txt| Create a self-installing Vim script
|
||||
|pi_zip.txt| Zip archive explorer
|
||||
|pi_zip.txt| Zip archive explorer
|
||||
|
||||
LOCAL ADDITIONS: *local-additions*
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*helphelp.txt* For Vim version 7.3. Last change: 2012 May 18
|
||||
*helphelp.txt* For Vim version 7.3. Last change: 2012 Nov 28
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -194,11 +194,12 @@ command: >
|
||||
*E154* *E150* *E151* *E152* *E153* *E670*
|
||||
:helpt[ags] [++t] {dir}
|
||||
Generate the help tags file(s) for directory {dir}.
|
||||
All "*.txt" and "*.??x" files in the directory are
|
||||
scanned for a help tag definition in between stars.
|
||||
The "*.??x" files are for translated docs, they
|
||||
generate the "tags-??" file, see |help-translated|.
|
||||
The generated tags files are sorted.
|
||||
All "*.txt" and "*.??x" files in the directory and
|
||||
sub-directories are scanned for a help tag definition
|
||||
in between stars. The "*.??x" files are for
|
||||
translated docs, they generate the "tags-??" file, see
|
||||
|help-translated|. The generated tags files are
|
||||
sorted.
|
||||
When there are duplicates an error message is given.
|
||||
An existing tags file is silently overwritten.
|
||||
The optional "++t" argument forces adding the
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*if_mzsch.txt* For Vim version 7.3. Last change: 2010 Feb 11
|
||||
*if_mzsch.txt* For Vim version 7.3. Last change: 2012 Dec 17
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Sergey Khorev
|
||||
@@ -11,7 +11,8 @@ The MzScheme Interface to Vim *mzscheme* *MzScheme*
|
||||
3. Threads |mzscheme-threads|
|
||||
4. Vim access from MzScheme |mzscheme-vim|
|
||||
5. mzeval() Vim function |mzscheme-mzeval|
|
||||
6. Dynamic loading |mzscheme-dynamic|
|
||||
6. Using Function references |mzscheme-funcref|
|
||||
7. Dynamic loading |mzscheme-dynamic|
|
||||
|
||||
{Vi does not have any of these commands}
|
||||
|
||||
@@ -21,10 +22,17 @@ The MzScheme interface is available only if Vim was compiled with the
|
||||
Based on the work of Brent Fulgham.
|
||||
Dynamic loading added by Sergey Khorev
|
||||
|
||||
For downloading MzScheme and other info:
|
||||
http://www.plt-scheme.org/software/mzscheme/
|
||||
MzScheme and PLT Scheme names have been rebranded as Racket. For more
|
||||
information please check http://racket-lang.org
|
||||
|
||||
Note: On FreeBSD you should use the "drscheme" port.
|
||||
Futures and places of Racket version 5.x up to and including 5.3.1 do not
|
||||
work correctly with processes created by Vim.
|
||||
The simplest solution is to build Racket on your own with these features
|
||||
disabled: >
|
||||
./configure --disable-futures --disable-places --prefix=your-install-prefix
|
||||
|
||||
To speed up the process, you might also want to use --disable-gracket and
|
||||
--disable-docs
|
||||
|
||||
==============================================================================
|
||||
1. Commands *mzscheme-commands*
|
||||
@@ -155,8 +163,11 @@ Common
|
||||
(eval {expr-string}) Evaluate the vim expression into
|
||||
respective MzScheme object: |Lists| are
|
||||
represented as Scheme lists,
|
||||
|Dictionaries| as hash tables.
|
||||
NOTE the name clashes with MzScheme eval
|
||||
|Dictionaries| as hash tables,
|
||||
|Funcref|s as functions (see also
|
||||
|mzscheme-funcref|)
|
||||
NOTE the name clashes with MzScheme eval,
|
||||
use module qualifiers to overcome this.
|
||||
(range-start) Start/End of the range passed with
|
||||
(range-end) the Scheme command.
|
||||
(beep) beep
|
||||
@@ -237,7 +248,23 @@ To facilitate bi-directional interface, you can use |mzeval()| function to
|
||||
evaluate MzScheme expressions and pass their values to VimL.
|
||||
|
||||
==============================================================================
|
||||
6. Dynamic loading *mzscheme-dynamic* *E815*
|
||||
6. Using Function references *mzscheme-funcref*
|
||||
|
||||
MzScheme interface allows use of |Funcref|s so you can call Vim functions
|
||||
directly from Scheme. For instance: >
|
||||
function! MyAdd2(arg)
|
||||
return a:arg + 2
|
||||
endfunction
|
||||
mz (define f2 (vim-eval "function(\"MyAdd2\")"))
|
||||
mz (f2 7)
|
||||
< or : >
|
||||
:mz (define indent (vim-eval "function('indent')"))
|
||||
" return Vim indent for line 12
|
||||
:mz (indent 12)
|
||||
<
|
||||
|
||||
==============================================================================
|
||||
7. Dynamic loading *mzscheme-dynamic* *E815*
|
||||
|
||||
On MS-Windows the MzScheme libraries can be loaded dynamically. The |:version|
|
||||
output then includes |+mzscheme/dyn|.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*if_perl.txt* For Vim version 7.3. Last change: 2012 Aug 02
|
||||
*if_perl.txt* For Vim version 7.3. Last change: 2012 Oct 25
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Sven Verdoolaege
|
||||
@@ -175,7 +175,8 @@ VIM::Windows([{wn}...]) With no arguments, returns a list of all the windows
|
||||
VIM::DoCommand({cmd}) Executes Ex command {cmd}.
|
||||
|
||||
*perl-Eval*
|
||||
VIM::Eval({expr}) Evaluates {expr} and returns (success, val).
|
||||
VIM::Eval({expr}) Evaluates {expr} and returns (success, value) in list
|
||||
context or just value in scalar context.
|
||||
success=1 indicates that val contains the value of
|
||||
{expr}; success=0 indicates a failure to evaluate
|
||||
the expression. '@x' returns the contents of register
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*if_pyth.txt* For Vim version 7.3. Last change: 2012 Aug 02
|
||||
*if_pyth.txt* For Vim version 7.3. Last change: 2013 May 25
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Paul Moore
|
||||
@@ -11,9 +11,11 @@ The Python Interface to Vim *python* *Python*
|
||||
3. Buffer objects |python-buffer|
|
||||
4. Range objects |python-range|
|
||||
5. Window objects |python-window|
|
||||
6. pyeval(), py3eval() Vim functions |python-pyeval|
|
||||
7. Dynamic loading |python-dynamic|
|
||||
8. Python 3 |python3|
|
||||
6. Tab page objects |python-tabpage|
|
||||
7. vim.bindeval objects |python-bindeval-objects|
|
||||
8. pyeval(), py3eval() Vim functions |python-pyeval|
|
||||
9. Dynamic loading |python-dynamic|
|
||||
10. Python 3 |python3|
|
||||
|
||||
{Vi does not have any of these commands}
|
||||
|
||||
@@ -54,9 +56,25 @@ Example: >
|
||||
EOF
|
||||
endfunction
|
||||
<
|
||||
Note: Python is very sensitive to the indenting. Also make sure the "class"
|
||||
line and "EOF" do not have any indent.
|
||||
Note: Python is very sensitive to the indenting. Make sure the "class" line
|
||||
and "EOF" do not have any indent.
|
||||
|
||||
*:pydo*
|
||||
:[range]pydo {body} Execute Python function "def _vim_pydo(line, linenr):
|
||||
{body}" for each line in the [range], with the
|
||||
function arguments being set to the text of each line
|
||||
in turn, without a trailing <EOL>, and the current
|
||||
line number. The function should return a string or
|
||||
None. If a string is returned, it becomes the text of
|
||||
the line in the current turn. The default for [range]
|
||||
is the whole file: "1,$".
|
||||
{not in Vi}
|
||||
|
||||
Examples:
|
||||
>
|
||||
:pydo return "%s\t%d" % (line[::-1], len(line))
|
||||
:pydo if line: return "%4d: %s" % (linenr, line)
|
||||
<
|
||||
*:pyfile* *:pyf*
|
||||
:[range]pyf[ile] {file}
|
||||
Execute the Python script in {file}. The whole
|
||||
@@ -154,22 +172,20 @@ vim.eval(str) *python-eval*
|
||||
'eval_expr', 'kind': 'f', 'filename': './src/eval.c'}]
|
||||
|
||||
vim.bindeval(str) *python-bindeval*
|
||||
Like |python-eval|, but
|
||||
1. if expression evaluates to |List| or |Dictionary| it is returned as
|
||||
vimlist or vimdictionary python type that are connected to original
|
||||
list or dictionary. Thus modifications to these objects imply
|
||||
modifications of the original.
|
||||
2. if expression evaluates to a function reference, then it returns
|
||||
callable vimfunction object. Use self keyword argument to assign
|
||||
|self| object for dictionary functions.
|
||||
|
||||
Note: this function has the same behavior as |lua-eval| (except that
|
||||
lua does not support running vim functions), |python-eval| is
|
||||
kept for backwards compatibility in order not to make scripts
|
||||
relying on outputs of vim.eval() being a copy of original or
|
||||
vim.eval("1") returning a string.
|
||||
Like |python-eval|, but returns special objects described in
|
||||
|python-bindeval-objects|. These python objects let you modify (|List|
|
||||
or |Dictionary|) or call (|Funcref|) vim objects.
|
||||
|
||||
vim.strwidth(str) *python-strwidth*
|
||||
Like |strwidth()|: returns number of display cells str occupies, tab
|
||||
is counted as one cell.
|
||||
|
||||
vim.chdir(*args, **kwargs) *python-chdir*
|
||||
vim.fchdir(*args, **kwargs) *python-fchdir*
|
||||
Run os.chdir or os.fchdir, then all appropriate vim stuff.
|
||||
Note: you should not use these functions directly, use os.chdir and
|
||||
os.fchdir instead. Behavior of vim.fchdir is undefined in case
|
||||
os.fchdir does not exist.
|
||||
|
||||
Error object of the "vim" module
|
||||
|
||||
@@ -189,12 +205,12 @@ Constants of the "vim" module
|
||||
to which the variables referred.
|
||||
|
||||
vim.buffers *python-buffers*
|
||||
A sequence object providing access to the list of vim buffers. The
|
||||
A mapping object providing access to the list of vim buffers. The
|
||||
object supports the following operations: >
|
||||
:py b = vim.buffers[i] # Indexing (read-only)
|
||||
:py b in vim.buffers # Membership test
|
||||
:py n = len(vim.buffers) # Number of elements
|
||||
:py for b in vim.buffers: # Sequential access
|
||||
:py for b in vim.buffers: # Iterating over buffer list
|
||||
<
|
||||
vim.windows *python-windows*
|
||||
A sequence object providing access to the list of vim windows. The
|
||||
@@ -203,13 +219,28 @@ vim.windows *python-windows*
|
||||
:py w in vim.windows # Membership test
|
||||
:py n = len(vim.windows) # Number of elements
|
||||
:py for w in vim.windows: # Sequential access
|
||||
< Note: vim.windows object always accesses current tab page.
|
||||
|python-tabpage|.windows objects are bound to parent |python-tabpage|
|
||||
object and always use windows from that tab page (or throw vim.error
|
||||
in case tab page was deleted). You can keep a reference to both
|
||||
without keeping a reference to vim module object or |python-tabpage|,
|
||||
they will not lose their properties in this case.
|
||||
|
||||
vim.tabpages *python-tabpages*
|
||||
A sequence object providing access to the list of vim tab pages. The
|
||||
object supports the following operations: >
|
||||
:py t = vim.tabpages[i] # Indexing (read-only)
|
||||
:py t in vim.tabpages # Membership test
|
||||
:py n = len(vim.tabpages) # Number of elements
|
||||
:py for t in vim.tabpages: # Sequential access
|
||||
<
|
||||
vim.current *python-current*
|
||||
An object providing access (via specific attributes) to various
|
||||
"current" objects available in vim:
|
||||
vim.current.line The current line (RW) String
|
||||
vim.current.buffer The current buffer (RO) Buffer
|
||||
vim.current.window The current window (RO) Window
|
||||
vim.current.buffer The current buffer (RW) Buffer
|
||||
vim.current.window The current window (RW) Window
|
||||
vim.current.tabpage The current tab page (RW) TabPage
|
||||
vim.current.range The current line range (RO) Range
|
||||
|
||||
The last case deserves a little explanation. When the :python or
|
||||
@@ -217,6 +248,42 @@ vim.current *python-current*
|
||||
"current range". A range is a bit like a buffer, but with all access
|
||||
restricted to a subset of lines. See |python-range| for more details.
|
||||
|
||||
Note: When assigning to vim.current.{buffer,window,tabpage} it expects
|
||||
valid |python-buffer|, |python-window| or |python-tabpage| objects
|
||||
respectively. Assigning triggers normal (with |autocommand|s)
|
||||
switching to given buffer, window or tab page. It is the only way to
|
||||
switch UI objects in python: you can't assign to
|
||||
|python-tabpage|.window attribute. To switch without triggering
|
||||
autocommands use >
|
||||
py << EOF
|
||||
saved_eventignore = vim.options['eventignore']
|
||||
vim.options['eventignore'] = 'all'
|
||||
try:
|
||||
vim.current.buffer = vim.buffers[2] # Switch to buffer 2
|
||||
finally:
|
||||
vim.options['eventignore'] = saved_eventignore
|
||||
EOF
|
||||
<
|
||||
vim.vars *python-vars*
|
||||
vim.vvars *python-vvars*
|
||||
Dictionary-like objects holding dictionaries with global (|g:|) and
|
||||
vim (|v:|) variables respectively. Identical to `vim.bindeval("g:")`,
|
||||
but faster.
|
||||
|
||||
vim.options *python-options*
|
||||
Object partly supporting mapping protocol (supports setting and
|
||||
getting items) providing a read-write access to global options.
|
||||
Note: unlike |:set| this provides access only to global options. You
|
||||
cannot use this object to obtain or set local options' values or
|
||||
access local-only options in any fashion. Raises KeyError if no global
|
||||
option with such name exists (i.e. does not raise KeyError for
|
||||
|global-local| options and global only options, but does for window-
|
||||
and buffer-local ones). Use |python-buffer| objects to access to
|
||||
buffer-local options and |python-window| objects to access to
|
||||
window-local options.
|
||||
|
||||
Type of this object is available via "Options" attribute of vim
|
||||
module.
|
||||
|
||||
Output from Python *python-output*
|
||||
Vim displays all Python code output in the Vim message area. Normal
|
||||
@@ -258,6 +325,24 @@ Buffer indexes start at zero, as is normal in Python. This differs from vim
|
||||
line numbers, which start from 1. This is particularly relevant when dealing
|
||||
with marks (see below) which use vim line numbers.
|
||||
|
||||
The buffer object attributes are:
|
||||
b.vars Dictionary-like object used to access
|
||||
|buffer-variable|s.
|
||||
b.options Mapping object (supports item getting, setting and
|
||||
deleting) that provides access to buffer-local options
|
||||
and buffer-local values of |global-local| options. Use
|
||||
|python-window|.options if option is window-local,
|
||||
this object will raise KeyError. If option is
|
||||
|global-local| and local value is missing getting it
|
||||
will return None.
|
||||
b.name String, RW. Contains buffer name (full path).
|
||||
Note: when assigning to b.name |BufFilePre| and
|
||||
|BufFilePost| autocommands are launched.
|
||||
b.number Buffer number. Can be used as |python-buffers| key.
|
||||
Read-only.
|
||||
b.valid True or False. Buffer object becames invalid when
|
||||
corresponding buffer is wiped out.
|
||||
|
||||
The buffer object methods are:
|
||||
b.append(str) Append a line to the buffer
|
||||
b.append(str, nr) Idem, below line "nr"
|
||||
@@ -276,6 +361,8 @@ Note that when adding a line it must not contain a line break character '\n'.
|
||||
A trailing '\n' is allowed and ignored, so that you can do: >
|
||||
:py b.append(f.readlines())
|
||||
|
||||
Buffer object type is available using "Buffer" attribute of vim module.
|
||||
|
||||
Examples (assume b is the current buffer) >
|
||||
:py print b.name # write the buffer file name
|
||||
:py b[0] = "hello!!!" # replace the top line
|
||||
@@ -287,6 +374,9 @@ Examples (assume b is the current buffer) >
|
||||
:py n = len(b) # number of lines
|
||||
:py (row,col) = b.mark('a') # named mark
|
||||
:py r = b.range(1,5) # a sub-range of the buffer
|
||||
:py b.vars["foo"] = "bar" # assign b:foo variable
|
||||
:py b.options["ff"] = "dos" # set fileformat
|
||||
:py del b.options["ar"] # same as :set autoread<
|
||||
|
||||
==============================================================================
|
||||
4. Range objects *python-range*
|
||||
@@ -314,6 +404,8 @@ The range object methods are:
|
||||
for Python's built-in list objects.
|
||||
r.append(list, nr) Idem, after line "nr"
|
||||
|
||||
Range object type is available using "Range" attribute of vim module.
|
||||
|
||||
Example (assume r is the current range):
|
||||
# Send all lines in a range to the default printer
|
||||
vim.command("%d,%dhardcopy!" % (r.start+1,r.end+1))
|
||||
@@ -324,6 +416,8 @@ Example (assume r is the current range):
|
||||
Window objects represent vim windows. You can obtain them in a number of ways:
|
||||
- via vim.current.window (|python-current|)
|
||||
- from indexing vim.windows (|python-windows|)
|
||||
- from indexing "windows" attribute of a tab page (|python-tabpage|)
|
||||
- from the "window" attribute of a tab page (|python-tabpage|)
|
||||
|
||||
You can manipulate window objects only through their attributes. They have no
|
||||
methods, and no sequence or other interface.
|
||||
@@ -334,17 +428,167 @@ Window attributes are:
|
||||
This is a tuple, (row,col).
|
||||
height (read-write) The window height, in rows
|
||||
width (read-write) The window width, in columns
|
||||
vars (read-only) The window |w:| variables. Attribute is
|
||||
unassignable, but you can change window
|
||||
variables this way
|
||||
options (read-only) The window-local options. Attribute is
|
||||
unassignable, but you can change window
|
||||
options this way. Provides access only to
|
||||
window-local options, for buffer-local use
|
||||
|python-buffer| and for global ones use
|
||||
|python-options|. If option is |global-local|
|
||||
and local value is missing getting it will
|
||||
return None.
|
||||
number (read-only) Window number. The first window has number 1.
|
||||
This is zero in case it cannot be determined
|
||||
(e.g. when the window object belongs to other
|
||||
tab page).
|
||||
row, col (read-only) On-screen window position in display cells.
|
||||
First position is zero.
|
||||
tabpage (read-only) Window tab page.
|
||||
valid (read-write) True or False. Window object becames invalid
|
||||
when corresponding window is closed.
|
||||
|
||||
The height attribute is writable only if the screen is split horizontally.
|
||||
The width attribute is writable only if the screen is split vertically.
|
||||
|
||||
Window object type is available using "Window" attribute of vim module.
|
||||
|
||||
==============================================================================
|
||||
6. pyeval() and py3eval() Vim functions *python-pyeval*
|
||||
6. Tab page objects *python-tabpage*
|
||||
|
||||
Tab page objects represent vim tab pages. You can obtain them in a number of
|
||||
ways:
|
||||
- via vim.current.tabpage (|python-current|)
|
||||
- from indexing vim.tabpages (|python-tabpages|)
|
||||
|
||||
You can use this object to access tab page windows. They have no methods and
|
||||
no sequence or other interfaces.
|
||||
|
||||
Tab page attributes are:
|
||||
number The tab page number like the one returned by
|
||||
|tabpagenr()|.
|
||||
windows Like |python-windows|, but for current tab page.
|
||||
vars The tab page |t:| variables.
|
||||
window Current tabpage window.
|
||||
valid True or False. Tab page object becames invalid when
|
||||
corresponding tab page is closed.
|
||||
|
||||
TabPage object type is available using "TabPage" attribute of vim module.
|
||||
|
||||
==============================================================================
|
||||
7. vim.bindeval objects *python-bindeval-objects*
|
||||
|
||||
vim.Dictionary object *python-Dictionary*
|
||||
Dictionary-like object providing access to vim |Dictionary| type.
|
||||
Attributes:
|
||||
Attribute Description ~
|
||||
locked One of *python-.locked*
|
||||
Value Description ~
|
||||
zero Variable is not locked
|
||||
vim.VAR_LOCKED Variable is locked, but can be unlocked
|
||||
vim.VAR_FIXED Variable is locked and can't be unlocked
|
||||
Read-write. You can unlock locked variable by assigning
|
||||
`True` or `False` to this attribute. No recursive locking
|
||||
is supported.
|
||||
scope One of
|
||||
Value Description ~
|
||||
zero Dictionary is not a scope one
|
||||
vim.VAR_DEF_SCOPE |g:| or |l:| dictionary
|
||||
vim.VAR_SCOPE Other scope dictionary,
|
||||
see |internal-variables|
|
||||
Methods (note: methods do not support keyword arguments):
|
||||
Method Description ~
|
||||
keys() Returns a list with dictionary keys.
|
||||
values() Returns a list with dictionary values.
|
||||
items() Returns a list of 2-tuples with dictionary contents.
|
||||
update(iterable), update(dictionary), update(**kwargs)
|
||||
Adds keys to dictionary.
|
||||
get(key[, default=None])
|
||||
Obtain key from dictionary, returning the default if it is
|
||||
not present.
|
||||
pop(key[, default])
|
||||
Remove specified key from dictionary and return
|
||||
corresponding value. If key is not found and default is
|
||||
given returns the default, otherwise raises KeyError.
|
||||
popitem()
|
||||
Remove random key from dictionary and return (key, value)
|
||||
pair.
|
||||
has_key(key)
|
||||
Check whether dictionary contains specified key, similar
|
||||
to `key in dict`.
|
||||
|
||||
__new__(), __new__(iterable), __new__(dictionary), __new__(update)
|
||||
You can use `vim.Dictionary()` to create new vim
|
||||
dictionaries. `d=vim.Dictionary(arg)` is the same as
|
||||
`d=vim.bindeval('{}');d.update(arg)`. Without arguments
|
||||
constructs empty dictionary.
|
||||
|
||||
Examples: >
|
||||
d = vim.Dictionary(food="bar") # Constructor
|
||||
d['a'] = 'b' # Item assignment
|
||||
print d['a'] # getting item
|
||||
d.update({'c': 'd'}) # .update(dictionary)
|
||||
d.update(e='f') # .update(**kwargs)
|
||||
d.update((('g', 'h'), ('i', 'j'))) # .update(iterable)
|
||||
for key in d.keys(): # .keys()
|
||||
for val in d.values(): # .values()
|
||||
for key, val in d.items(): # .items()
|
||||
print isinstance(d, vim.Dictionary) # True
|
||||
for key in d: # Iteration over keys
|
||||
class Dict(vim.Dictionary): # Subclassing
|
||||
<
|
||||
Note: when iterating over keys you should not modify dictionary.
|
||||
|
||||
vim.List object *python-List*
|
||||
Sequence-like object providing access to vim |List| type.
|
||||
Supports `.locked` attribute, see |python-.locked|. Also supports the
|
||||
following methods:
|
||||
Method Description ~
|
||||
extend(item) Add items to the list.
|
||||
|
||||
__new__(), __new__(iterable)
|
||||
You can use `vim.List()` to create new vim lists.
|
||||
`l=vim.List(iterable)` is the same as
|
||||
`l=vim.bindeval('[]');l.extend(iterable)`. Without
|
||||
arguments constructs empty list.
|
||||
Examples: >
|
||||
l = vim.List("abc") # Constructor, result: ['a', 'b', 'c']
|
||||
l.extend(['abc', 'def']) # .extend() method
|
||||
print l[1:] # slicing
|
||||
l[:0] = ['ghi', 'jkl'] # slice assignment
|
||||
print l[0] # getting item
|
||||
l[0] = 'mno' # assignment
|
||||
for i in l: # iteration
|
||||
print isinstance(l, vim.List) # True
|
||||
class List(vim.List): # Subclassing
|
||||
|
||||
vim.Function object *python-Function*
|
||||
Function-like object, acting like vim |Funcref| object. Supports `.name`
|
||||
attribute and is callable. Accepts special keyword argument `self`, see
|
||||
|Dictionary-function|. You can also use `vim.Function(name)` constructor,
|
||||
it is the same as `vim.bindeval('function(%s)'%json.dumps(name))`.
|
||||
|
||||
Examples: >
|
||||
f = vim.Function('tr') # Constructor
|
||||
print f('abc', 'a', 'b') # Calls tr('abc', 'a', 'b')
|
||||
vim.command('''
|
||||
function DictFun() dict
|
||||
return self
|
||||
endfunction
|
||||
''')
|
||||
f = vim.bindeval('function("DictFun")')
|
||||
print f(self={}) # Like call('DictFun', [], {})
|
||||
print isinstance(f, vim.Function) # True
|
||||
|
||||
==============================================================================
|
||||
8. pyeval() and py3eval() Vim functions *python-pyeval*
|
||||
|
||||
To facilitate bi-directional interface, you can use |pyeval()| and |py3eval()|
|
||||
functions to evaluate Python expressions and pass their values to VimL.
|
||||
|
||||
==============================================================================
|
||||
7. Dynamic loading *python-dynamic*
|
||||
9. Dynamic loading *python-dynamic*
|
||||
|
||||
On MS-Windows the Python library can be loaded dynamically. The |:version|
|
||||
output then includes |+python/dyn|.
|
||||
@@ -361,14 +605,16 @@ Currently the name is "python24.dll". That is for Python 2.4. To know for
|
||||
sure edit "gvim.exe" and search for "python\d*.dll\c".
|
||||
|
||||
==============================================================================
|
||||
8. Python 3 *python3*
|
||||
10. Python 3 *python3*
|
||||
|
||||
*:py3* *:python3*
|
||||
The |:py3| and |:python3| commands work similar to |:python|. A simple check
|
||||
if the `:py3` command is wrong: >
|
||||
The `:py3` and `:python3` commands work similar to `:python`. A simple check
|
||||
if the `:py3` command is working: >
|
||||
:py3 print("Hello")
|
||||
< *:py3file*
|
||||
The |:py3file| command works similar to |:pyfile|.
|
||||
The `:py3file` command works similar to `:pyfile`.
|
||||
*:py3do* *E863*
|
||||
The `:py3do` command works similar to `:pydo`.
|
||||
|
||||
|
||||
Vim can be built in four ways (:version output):
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*indent.txt* For Vim version 7.3. Last change: 2011 Sep 02
|
||||
*indent.txt* For Vim version 7.3. Last change: 2013 May 20
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -540,7 +540,7 @@ The examples below assume a 'shiftwidth' of 4.
|
||||
*cino-star*
|
||||
*N Vim searches for unclosed comments at most N lines away. This
|
||||
limits the time needed to search for the start of a comment.
|
||||
If your /* */ comments stop indenting afer N lines this is the
|
||||
If your /* */ comments stop indenting after N lines this is the
|
||||
value you will want to change.
|
||||
(default 70 lines).
|
||||
|
||||
@@ -577,6 +577,106 @@ $VIMRUNTIME/indent directory for examples.
|
||||
REMARKS ABOUT SPECIFIC INDENT FILES ~
|
||||
|
||||
|
||||
CLOJURE *ft-clojure-indent* *clojure-indent*
|
||||
|
||||
Clojure indentation differs somewhat from traditional Lisps, due in part to
|
||||
the use of square and curly brackets, and otherwise by community convention.
|
||||
These conventions are not always universally followed, so the Clojure indent
|
||||
script offers a few configurable options, listed below.
|
||||
|
||||
If the current vim does not include searchpairpos(), the indent script falls
|
||||
back to normal 'lisp' indenting, and the following options are ignored.
|
||||
|
||||
*g:clojure_maxlines*
|
||||
|
||||
Set maximum scan distance of searchpairpos(). Larger values trade performance
|
||||
for correctness when dealing with very long forms. A value of 0 will scan
|
||||
without limits.
|
||||
>
|
||||
" Default
|
||||
let g:clojure_maxlines = 100
|
||||
<
|
||||
|
||||
*g:clojure_fuzzy_indent*
|
||||
*g:clojure_fuzzy_indent_patterns*
|
||||
*g:clojure_fuzzy_indent_blacklist*
|
||||
|
||||
The 'lispwords' option is a list of comma-separated words that mark special
|
||||
forms whose subforms must be indented with two spaces.
|
||||
|
||||
For example:
|
||||
>
|
||||
(defn bad []
|
||||
"Incorrect indentation")
|
||||
|
||||
(defn good []
|
||||
"Correct indentation")
|
||||
<
|
||||
If you would like to specify 'lispwords' with a |pattern| instead, you can use
|
||||
the fuzzy indent feature:
|
||||
>
|
||||
" Default
|
||||
let g:clojure_fuzzy_indent = 1
|
||||
let g:clojure_fuzzy_indent_patterns = ['^with', '^def', '^let']
|
||||
let g:clojure_fuzzy_indent_blacklist =
|
||||
\ ['-fn$', '\v^with-%(meta|out-str|loading-context)$']
|
||||
|
||||
" Legacy comma-delimited string version; the list format above is
|
||||
" recommended. Note that patterns are implicitly anchored with ^ and $
|
||||
let g:clojure_fuzzy_indent_patterns = 'with.*,def.*,let.*'
|
||||
<
|
||||
|g:clojure_fuzzy_indent_patterns| and |g:clojure_fuzzy_indent_blacklist| are
|
||||
|Lists| of patterns that will be matched against the unquoted, unqualified
|
||||
symbol at the head of a list. This means that a pattern like "^foo" will match
|
||||
all these candidates: "foobar", "my.ns/foobar", and "#'foobar".
|
||||
|
||||
Each candidate word is tested for special treatment in this order:
|
||||
|
||||
1. Return true if word is literally in 'lispwords'
|
||||
2. Return false if word matches a pattern in
|
||||
|g:clojure_fuzzy_indent_blacklist|
|
||||
3. Return true if word matches a pattern in
|
||||
|g:clojure_fuzzy_indent_patterns|
|
||||
4. Return false and indent normally otherwise
|
||||
|
||||
*g:clojure_special_indent_words*
|
||||
|
||||
Some forms in Clojure are indented so that every subform is indented only two
|
||||
spaces, regardless of 'lispwords'. If you have a custom construct that should
|
||||
be indented in this idiosyncratic fashion, you can add your symbols to the
|
||||
default list below.
|
||||
>
|
||||
" Default
|
||||
let g:clojure_special_indent_words =
|
||||
\ 'deftype,defrecord,reify,proxy,extend-type,extend-protocol,letfn'
|
||||
<
|
||||
|
||||
*g:clojure_align_multiline_strings*
|
||||
|
||||
Align subsequent lines in multiline strings to the column after the opening
|
||||
quote, instead of the same column.
|
||||
|
||||
For example:
|
||||
>
|
||||
(def default
|
||||
"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do
|
||||
eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut
|
||||
enim ad minim veniam, quis nostrud exercitation ullamco laboris
|
||||
nisi ut aliquip ex ea commodo consequat.")
|
||||
|
||||
(def aligned
|
||||
"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do
|
||||
eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut
|
||||
enim ad minim veniam, quis nostrud exercitation ullamco laboris
|
||||
nisi ut aliquip ex ea commodo consequat.")
|
||||
<
|
||||
This option is off by default.
|
||||
>
|
||||
" Default
|
||||
let g:clojure_align_multiline_strings = 0
|
||||
<
|
||||
|
||||
|
||||
FORTRAN *ft-fortran-indent*
|
||||
|
||||
Block if, select case, where, and forall constructs are indented. So are
|
||||
@@ -640,12 +740,12 @@ those useless characters first with a command like: >
|
||||
:%s /\r$//g
|
||||
|
||||
Or, you can simply |:let| the variable PHP_removeCRwhenUnix to 1 and the
|
||||
script will silently remove them when Vim loads a PHP file (at each|BufRead|).
|
||||
script will silently remove them when Vim loads a PHP file (at each |BufRead|).
|
||||
|
||||
OPTIONS: ~
|
||||
|
||||
PHP indenting can be altered in several ways by modifying the values of some
|
||||
variables:
|
||||
global variables:
|
||||
|
||||
*php-comment*
|
||||
To not enable auto-formating of comments by default (if you want to use your
|
||||
@@ -653,10 +753,21 @@ own 'formatoptions'): >
|
||||
:let g:PHP_autoformatcomment = 0
|
||||
|
||||
Else, 't' will be removed from the 'formatoptions' string and "qrowcb" will be
|
||||
added, see|fo-table|for more information.
|
||||
added, see |fo-table| for more information.
|
||||
-------------
|
||||
|
||||
To add an extra indent to every PHP lines with N being the number of
|
||||
To add extra indentation to single-line comments: >
|
||||
:let g:PHP_outdentSLComments = N
|
||||
|
||||
With N being the number of 'shiftwidth' to add.
|
||||
|
||||
Only single-line comments will be affected such as: >
|
||||
# Comment
|
||||
// Comment
|
||||
/* Comment */
|
||||
-------------
|
||||
|
||||
To add extra indentation to every PHP lines with N being the number of
|
||||
'shiftwidth' to add: >
|
||||
:let g:PHP_default_indenting = N
|
||||
|
||||
@@ -672,7 +783,7 @@ For example, with N = 1, this will give:
|
||||
|
||||
$command_hist = TRUE;
|
||||
?>
|
||||
(Notice the extra indent between the PHP container markers and the code)
|
||||
(Notice the extra indentation between the PHP container markers and the code)
|
||||
-------------
|
||||
|
||||
To indent PHP tags as the surrounding code: >
|
||||
@@ -704,8 +815,10 @@ NOTE: Indenting will be a bit slower if this option is used because some
|
||||
To indent 'case:' and 'default:' statements in switch() blocks: >
|
||||
:let g:PHP_vintage_case_default_indent = 1
|
||||
|
||||
(Since in PHP braces are not required inside 'case/default' blocks, by default they are indented at the same level than the 'switch()' to avoid
|
||||
unnecessary indentation)
|
||||
In PHP braces are not required inside 'case/default' blocks therefore 'case:'
|
||||
and 'default:' are indented at the same level than the 'switch()' to avoid
|
||||
meaningless indentation. You can use the above option to return to the
|
||||
traditional way.
|
||||
|
||||
|
||||
PYTHON *ft-python-indent*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*index.txt* For Vim version 7.3. Last change: 2012 Jul 25
|
||||
*index.txt* For Vim version 7.3. Last change: 2013 May 17
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -94,8 +94,8 @@ tag char action in Insert mode ~
|
||||
|i_CTRL-Z| CTRL-Z when 'insertmode' set: suspend Vim
|
||||
|i_<Esc>| <Esc> end insert mode (unless 'insertmode' set)
|
||||
|i_CTRL-[| CTRL-[ same as <Esc>
|
||||
|i_CTRL-\_CTRL-N| CTRL-\ CTRL-N go to Normal mode
|
||||
|i_CTRL-\_CTRL-G| CTRL-\ CTRL-G go to mode specified with 'insertmode'
|
||||
|i_CTRL-\_CTRL-N| CTRL-\ CTRL-N go to Normal mode
|
||||
|i_CTRL-\_CTRL-G| CTRL-\ CTRL-G go to mode specified with 'insertmode'
|
||||
CTRL-\ a - z reserved for extensions
|
||||
CTRL-\ others not used
|
||||
|i_CTRL-]| CTRL-] trigger abbreviation
|
||||
@@ -141,7 +141,7 @@ tag char action in Insert mode ~
|
||||
|i_<ScrollWheelUp>| <ScrollWheelUp> move window three lines up
|
||||
|i_<S-ScrollWheelUp>| <S-ScrollWheelUp> move window one page up
|
||||
|i_<ScrollWheelLeft>| <ScrollWheelLeft> move window six columns left
|
||||
|i_<S-ScrollWheelLeft>| <S-ScrollWheelLeft> move window one page left
|
||||
|i_<S-ScrollWheelLeft>| <S-ScrollWheelLeft> move window one page left
|
||||
|i_<ScrollWheelRight>| <ScrollWheelRight> move window six columns right
|
||||
|i_<S-ScrollWheelRight>| <S-ScrollWheelRight> move window one page right
|
||||
|
||||
@@ -212,8 +212,8 @@ tag char note action in Normal mode ~
|
||||
|CTRL-Y| CTRL-Y scroll N lines downwards
|
||||
|CTRL-Z| CTRL-Z suspend program (or start new shell)
|
||||
CTRL-[ <Esc> not used
|
||||
|CTRL-\_CTRL-N| CTRL-\ CTRL-N go to Normal mode (no-op)
|
||||
|CTRL-\_CTRL-G| CTRL-\ CTRL-G go to mode specified with 'insertmode'
|
||||
|CTRL-\_CTRL-N| CTRL-\ CTRL-N go to Normal mode (no-op)
|
||||
|CTRL-\_CTRL-G| CTRL-\ CTRL-G go to mode specified with 'insertmode'
|
||||
CTRL-\ a - z reserved for extensions
|
||||
CTRL-\ others not used
|
||||
|CTRL-]| CTRL-] :ta to ident under cursor
|
||||
@@ -431,7 +431,7 @@ tag char note action in Normal mode ~
|
||||
|<Insert>| <Insert> 2 same as "i"
|
||||
|<Left>| <Left> 1 same as "h"
|
||||
|<LeftMouse>| <LeftMouse> 1 move cursor to the mouse click position
|
||||
|<MiddleMouse>| <MiddleMouse> 2 same as "gP" at the mouse click position
|
||||
|<MiddleMouse>| <MiddleMouse> 2 same as "gP" at the mouse click position
|
||||
|<PageDown>| <PageDown> same as CTRL-F
|
||||
|<PageUp>| <PageUp> same as CTRL-B
|
||||
|<Right>| <Right> 1 same as "l"
|
||||
@@ -640,7 +640,7 @@ tag char note action in Normal mode ~
|
||||
|[s| [s 1 move to the previous misspelled word
|
||||
|[z| [z 1 move to start of open fold
|
||||
|[{| [{ 1 cursor N times back to unmatched '{'
|
||||
|[<MiddleMouse> [<MiddleMouse> 2 same as "[p"
|
||||
|[<MiddleMouse>| [<MiddleMouse> 2 same as "[p"
|
||||
|
||||
|]_CTRL-D| ] CTRL-D jump to first #define found in current and
|
||||
included files matching the word under the
|
||||
@@ -680,7 +680,7 @@ tag char note action in Normal mode ~
|
||||
|]s| ]s 1 move to next misspelled word
|
||||
|]z| ]z 1 move to end of open fold
|
||||
|]}| ]} 1 cursor N times forward to unmatched '}'
|
||||
|]<MiddleMouse> ]<MiddleMouse> 2 same as "]p"
|
||||
|]<MiddleMouse>| ]<MiddleMouse> 2 same as "]p"
|
||||
|
||||
==============================================================================
|
||||
2.4 Commands starting with 'g' *g*
|
||||
@@ -725,6 +725,7 @@ tag char note action in Normal mode ~
|
||||
cursor N times, leave the cursor after it
|
||||
|gQ| gQ switch to "Ex" mode with Vim editing
|
||||
|gR| gR 2 enter Virtual Replace mode
|
||||
|gT| gT go to the previous tab page
|
||||
|gU| gU{motion} 2 make Nmove text uppercase
|
||||
|gV| gV don't reselect the previous Visual area
|
||||
when executing a mapping or menu in Select
|
||||
@@ -762,6 +763,7 @@ tag char note action in Normal mode ~
|
||||
|gq| gq{motion} 2 format Nmove text
|
||||
|gr| gr{char} 2 virtual replace N chars with {char}
|
||||
|gs| gs go to sleep for N seconds (default 1)
|
||||
|gt| gt go to the next tab page
|
||||
|gu| gu{motion} 2 make Nmove text lowercase
|
||||
|gv| gv reselect the previous Visual area
|
||||
|gw| gw{motion} 2 format Nmove text and keep cursor
|
||||
@@ -1011,8 +1013,8 @@ tag command action in Command-line editing mode ~
|
||||
CTRL-Z not used (reserved for suspend)
|
||||
|c_<Esc>| <Esc> abandon command-line without executing it
|
||||
|c_<Esc>| CTRL-[ same as <Esc>
|
||||
|c_CTRL-\_CTRL-N| CTRL-\ CTRL-N go to Normal mode, abandon command-line
|
||||
|c_CTRL-\_CTRL-G| CTRL-\ CTRL-G go to mode specified with 'insertmode',
|
||||
|c_CTRL-\_CTRL-N| CTRL-\ CTRL-N go to Normal mode, abandon command-line
|
||||
|c_CTRL-\_CTRL-G| CTRL-\ CTRL-G go to mode specified with 'insertmode',
|
||||
abandon command-line
|
||||
CTRL-\ a - d reserved for extensions
|
||||
|c_CTRL-\_e| CTRL-\ e {expr} replace the command line with the result of
|
||||
@@ -1134,7 +1136,7 @@ tag command action ~
|
||||
|:cgetbuffer| :cgetb[uffer] get errors from buffer
|
||||
|:cgetexpr| :cgete[xpr] get errors from expr
|
||||
|:cgetfile| :cg[etfile] read file with error messages
|
||||
|:changes| :cha[nges] print the change list
|
||||
|:changes| :changes print the change list
|
||||
|:chdir| :chd[ir] change directory
|
||||
|:checkpath| :che[ckpath] list included files
|
||||
|:checktime| :checkt[ime] check timestamp of loaded buffers
|
||||
@@ -1383,7 +1385,7 @@ tag command action ~
|
||||
|:promptrepl| :promptr[epl] open GUI dialog for search/replace
|
||||
|:perldo| :perld[o] execute Perl command for each line
|
||||
|:pop| :po[p] jump to older entry in tag stack
|
||||
|:popup| :pop[up] popup a menu by name
|
||||
|:popup| :popu[p] popup a menu by name
|
||||
|:ppop| :pp[op] ":pop" in preview window
|
||||
|:preserve| :pre[serve] write all text to swap file
|
||||
|:previous| :prev[ious] go to previous file in argument list
|
||||
@@ -1401,8 +1403,10 @@ tag command action ~
|
||||
|:pwd| :pw[d] print current directory
|
||||
|:py3| :py3 execute Python 3 command
|
||||
|:python3| :python3 same as :py3
|
||||
|:py3do| :py3d[o] execute Python 3 command for each line
|
||||
|:py3file| :py3f[ile] execute Python 3 script file
|
||||
|:python| :py[thon] execute Python command
|
||||
|:pydo| :pyd[o] execute Python command for each line
|
||||
|:pyfile| :pyf[ile] execute Python script file
|
||||
|:quit| :q[uit] quit current window (when one window quit Vim)
|
||||
|:quitall| :quita[ll] quit Vim
|
||||
@@ -1469,7 +1473,7 @@ tag command action ~
|
||||
|:slast| :sla[st] split window and go to last file in the
|
||||
argument list
|
||||
|:smagic| :sm[agic] :substitute with 'magic'
|
||||
|:smap| :sma[p] like ":map" but for Select mode
|
||||
|:smap| :smap like ":map" but for Select mode
|
||||
|:smapclear| :smapc[lear] remove all mappings for Select mode
|
||||
|:smenu| :sme[nu] add menu for Select mode
|
||||
|:snext| :sn[ext] split window and go to next file in the
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*insert.txt* For Vim version 7.3. Last change: 2012 Jul 10
|
||||
*insert.txt* For Vim version 7.3. Last change: 2013 Apr 12
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -380,7 +380,9 @@ The CTRL-O command sometimes has a side effect: If the cursor was beyond the
|
||||
end of the line, it will be put on the last character in the line. In
|
||||
mappings it's often better to use <Esc> (first put an "x" in the text, <Esc>
|
||||
will then always put the cursor on it). Or use CTRL-\ CTRL-O, but then
|
||||
beware of the cursor possibly being beyond the end of the line.
|
||||
beware of the cursor possibly being beyond the end of the line. Note that the
|
||||
command following CTRL-\ CTRL-O can still move the cursor, it is not restored
|
||||
to its original position.
|
||||
|
||||
The CTRL-O command takes you to Normal mode. If you then use a command enter
|
||||
Insert mode again it normally doesn't nest. Thus when typing "a<C-O>a" and
|
||||
@@ -1867,13 +1869,15 @@ NOTE: These commands cannot be used with |:global| or |:vglobal|.
|
||||
See |++opt| for the possible values of [++opt].
|
||||
|
||||
*:r!* *:read!*
|
||||
:[range]r[ead] !{cmd} Execute {cmd} and insert its standard output below
|
||||
:[range]r[ead] [++opt] !{cmd}
|
||||
Execute {cmd} and insert its standard output below
|
||||
the cursor or the specified line. A temporary file is
|
||||
used to store the output of the command which is then
|
||||
read into the buffer. 'shellredir' is used to save
|
||||
the output of the command, which can be set to include
|
||||
stderr or not. {cmd} is executed like with ":!{cmd}",
|
||||
any '!' is replaced with the previous command |:!|.
|
||||
See |++opt| for the possible values of [++opt].
|
||||
|
||||
These commands insert the contents of a file, or the output of a command,
|
||||
into the buffer. They can be undone. They cannot be repeated with the "."
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*intro.txt* For Vim version 7.3. Last change: 2011 May 15
|
||||
*intro.txt* For Vim version 7.3. Last change: 2012 Sep 05
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -394,6 +394,8 @@ CTRL-{char} {char} typed as a control character; that is, typing {char}
|
||||
*quotecommandquote*
|
||||
"command" A reference to a command that you can type is enclosed in
|
||||
double quotes.
|
||||
`command` New style command, this distinguishes it from other quoted
|
||||
text and strings.
|
||||
|
||||
*key-notation* *key-codes* *keycodes*
|
||||
These names for keys are used in the documentation. They can also be used
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*map.txt* For Vim version 7.3. Last change: 2012 Apr 13
|
||||
*map.txt* For Vim version 7.3. Last change: 2013 May 05
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -49,7 +49,7 @@ modes.
|
||||
:nm[ap] {lhs} {rhs} |mapmode-n| *:nm* *:nmap*
|
||||
:vm[ap] {lhs} {rhs} |mapmode-v| *:vm* *:vmap*
|
||||
:xm[ap] {lhs} {rhs} |mapmode-x| *:xm* *:xmap*
|
||||
:smap {lhs} {rhs} |mapmode-s| *:smap*
|
||||
:smap {lhs} {rhs} |mapmode-s| *:smap*
|
||||
:om[ap] {lhs} {rhs} |mapmode-o| *:om* *:omap*
|
||||
:map! {lhs} {rhs} |mapmode-ic| *:map!*
|
||||
:im[ap] {lhs} {rhs} |mapmode-i| *:im* *:imap*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*mbyte.txt* For Vim version 7.3. Last change: 2012 Jun 06
|
||||
*mbyte.txt* For Vim version 7.3. Last change: 2013 May 18
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar et al.
|
||||
@@ -48,9 +48,9 @@ COMPILING
|
||||
If you already have a compiled Vim program, check if the |+multi_byte| feature
|
||||
is included. The |:version| command can be used for this.
|
||||
|
||||
If +multi_byte is not included, you should compile Vim with "big" features.
|
||||
You can further tune what features are included. See the INSTALL files in the
|
||||
source directory.
|
||||
If +multi_byte is not included, you should compile Vim with "normal", "big" or
|
||||
"huge" features. You can further tune what features are included. See the
|
||||
INSTALL files in the source directory.
|
||||
|
||||
|
||||
LOCALE
|
||||
@@ -1067,7 +1067,7 @@ The actual mappings are in the lines below "loadkeymap". In the example "a"
|
||||
is mapped to "A" and "b" to "B". Thus the first item is mapped to the second
|
||||
item. This is done for each line, until the end of the file.
|
||||
These items are exactly the same as what can be used in a |:lnoremap| command,
|
||||
using "<buffer>" to make the mappings local to the buffer..
|
||||
using "<buffer>" to make the mappings local to the buffer.
|
||||
You can check the result with this command: >
|
||||
:lmap
|
||||
The two items must be separated by white space. You cannot include white
|
||||
@@ -1085,6 +1085,13 @@ Since the mapping is defined with |:lnoremap| the resulting quote will not be
|
||||
used for the start of another character.
|
||||
The "accents" keymap uses this. *keymap-accents*
|
||||
|
||||
The first column can also be in |<>| form:
|
||||
<C-c> Ctrl-C
|
||||
<A-c> Alt-c
|
||||
<A-C> Alt-C
|
||||
Note that the Alt mappings may not work, depending on your keyboard and
|
||||
terminal.
|
||||
|
||||
Although it's possible to have more than one character in the second column,
|
||||
this is unusual. But you can use various ways to specify the character: >
|
||||
A a literal character
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*message.txt* For Vim version 7.3. Last change: 2011 May 10
|
||||
*message.txt* For Vim version 7.3. Last change: 2013 Feb 23
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -730,7 +730,11 @@ Vim cannot create a temporary file.
|
||||
Can't open file {filename}
|
||||
Can't read file {filename}
|
||||
|
||||
Vim cannot read a temporary file.
|
||||
Vim cannot read a temporary file. Especially on Windows, this can be caused
|
||||
by wrong escaping of special characters for cmd.exe; the approach was
|
||||
changed with patch 7.3.443. Try using |shellescape()| for all shell arguments
|
||||
given to |system()|, or explicitly add escaping with ^. Also see
|
||||
'shellxquote' and 'shellxescape'.
|
||||
|
||||
*E464* >
|
||||
Ambiguous use of user-defined command
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*motion.txt* For Vim version 7.3. Last change: 2012 Aug 04
|
||||
*motion.txt* For Vim version 7.3. Last change: 2013 Mar 07
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -104,13 +104,14 @@ strokes and has limited redo functionality. See the chapter on Visual mode
|
||||
|Visual-mode|.
|
||||
|
||||
You can use a ":" command for a motion. For example "d:call FindEnd()".
|
||||
But this can't be redone with "." if the command is more than one line.
|
||||
But this can't be repeated with "." if the command is more than one line.
|
||||
This can be repeated: >
|
||||
d:call search("f")<CR>
|
||||
This cannot be repeated: >
|
||||
d:if 1<CR>
|
||||
call search("f")<CR>
|
||||
endif<CR>
|
||||
Note that when using ":" any motion becomes characterwise exclusive.
|
||||
|
||||
|
||||
FORCING A MOTION TO BE LINEWISE, CHARACTERWISE OR BLOCKWISE
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*options.txt* For Vim version 7.3. Last change: 2012 Aug 15
|
||||
*options.txt* For Vim version 7.3. Last change: 2013 May 23
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -277,8 +277,10 @@ Now the 'list' option is not set, because ":set nolist" resets the global
|
||||
value, ":setlocal list" only changes the local value and ":e two" gets the
|
||||
global value. Note that if you do this next: >
|
||||
:e one
|
||||
You will not get back the 'list' value as it was the last time you edited
|
||||
"one". The options local to a window are not remembered for each buffer.
|
||||
You will get back the 'list' value as it was the last time you edited "one".
|
||||
The options local to a window are remembered for each buffer. This also
|
||||
happens when the buffer is not loaded, but they are lost when the buffer is
|
||||
wiped out |:bwipe|.
|
||||
|
||||
*:setl* *:setlocal*
|
||||
:setl[ocal] ... Like ":set" but set only the value local to the
|
||||
@@ -699,6 +701,10 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
when the system locale is set to one of CJK locales. See Unicode
|
||||
Standard Annex #11 (http://www.unicode.org/reports/tr11).
|
||||
|
||||
Vim may set this option automatically at startup time when Vim is
|
||||
compiled with the |+termresponse| feature and if |t_u7| is set to the
|
||||
escape sequence to request cursor position report.
|
||||
|
||||
*'antialias'* *'anti'* *'noantialias'* *'noanti'*
|
||||
'antialias' 'anti' boolean (default: off)
|
||||
global
|
||||
@@ -756,7 +762,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
feature}
|
||||
When on and 'termbidi' is off, the required visual character
|
||||
corrections that need to take place for displaying the Arabic language
|
||||
take affect. Shaping, in essence, gets enabled; the term is a broad
|
||||
take effect. Shaping, in essence, gets enabled; the term is a broad
|
||||
one which encompasses:
|
||||
a) the changing/morphing of characters based on their location
|
||||
within a word (initial, medial, final and stand-alone).
|
||||
@@ -986,7 +992,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
- The backup file will be created in the first directory in the list
|
||||
where this is possible. The directory must exist, Vim will not
|
||||
create it for you.
|
||||
- Empty means that no backup file will be created ('patchmode' is
|
||||
- Empty means that no backup file will be created ( 'patchmode' is
|
||||
impossible!). Writing may fail because of this.
|
||||
- A directory "." means to put the backup file in the same directory
|
||||
as the edited file.
|
||||
@@ -1463,11 +1469,14 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
|gui-clipboard|.
|
||||
|
||||
*clipboard-unnamedplus*
|
||||
unnamedplus A variant of "unnamed" flag which uses the clipboard
|
||||
register '+' (|quoteplus|) instead of register '*' for
|
||||
all operations except yank. Yank shall copy the text
|
||||
into register '+' and also into '*' when "unnamed" is
|
||||
included.
|
||||
unnamedplus A variant of the "unnamed" flag which uses the
|
||||
clipboard register '+' (|quoteplus|) instead of
|
||||
register '*' for all yank, delete, change and put
|
||||
operations which would normally go to the unnamed
|
||||
register. When "unnamed" is also included to the
|
||||
option, yank operations (but not delete, change or
|
||||
put) will additionally copy the text into register
|
||||
'*'.
|
||||
Only available with the |+X11| feature.
|
||||
Availability can be checked with: >
|
||||
if has('unnamedplus')
|
||||
@@ -1700,7 +1709,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
when CTRL-P or CTRL-N are used. It is also used for whole-line
|
||||
completion |i_CTRL-X_CTRL-L|. It indicates the type of completion
|
||||
and the places to scan. It is a comma separated list of flags:
|
||||
. scan the current buffer ('wrapscan' is ignored)
|
||||
. scan the current buffer ( 'wrapscan' is ignored)
|
||||
w scan buffers from other windows
|
||||
b scan other loaded buffers that are in the buffer list
|
||||
u scan the unloaded buffers that are in the buffer list
|
||||
@@ -2865,7 +2874,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
See |file-formats| and |file-read|.
|
||||
For the character encoding of the file see 'fileencoding'.
|
||||
When 'binary' is set, the value of 'fileformat' is ignored, file I/O
|
||||
works like it was set to "unix'.
|
||||
works like it was set to "unix".
|
||||
This option is set automatically when starting to edit a file and
|
||||
'fileformats' is not empty and 'binary' is off.
|
||||
When this option is set, after starting to edit a file, the 'modified'
|
||||
@@ -2934,6 +2943,14 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
NOTE: This option is set to the Vi default value when 'compatible' is
|
||||
set and to the Vim default value when 'compatible' is reset.
|
||||
|
||||
*'fileignorecase'* *'fic'* *'nofileignorecase'* *'nofic'*
|
||||
'fileignorecase' 'fic' boolean (default on for systems where case in file
|
||||
names is normally ignored)
|
||||
global
|
||||
{not in Vi}
|
||||
When set case is ignored when using file names and directories.
|
||||
See 'wildignorecase' for only ignoring case when doing completion.
|
||||
|
||||
*'filetype'* *'ft'*
|
||||
'filetype' 'ft' string (default: "")
|
||||
local to buffer
|
||||
@@ -3560,6 +3577,10 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
to set 'guifontwide' at all unless you want to override the choice
|
||||
made by Pango/Xft.
|
||||
|
||||
Windows +multibyte only: *guifontwide_win_mbyte*
|
||||
|
||||
If set and valid, 'guifontwide' is used for IME instead of 'guifont'.
|
||||
|
||||
*'guiheadroom'* *'ghr'*
|
||||
'guiheadroom' 'ghr' number (default 50)
|
||||
global
|
||||
@@ -3820,7 +3841,8 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
|hl-ModeMsg| M Mode (e.g., "-- INSERT --")
|
||||
|hl-LineNr| n line number for ":number" and ":#" commands, and
|
||||
when 'number' or 'relativenumber' option is set.
|
||||
|hl-CursorLineNr| N like n for when 'cursorline' is set.
|
||||
|hl-CursorLineNr| N like n for when 'cursorline' or 'relativenumber' is
|
||||
set.
|
||||
|hl-Question| r |hit-enter| prompt and yes/no questions
|
||||
|hl-StatusLine| s status line of current window |status-line|
|
||||
|hl-StatusLineNC| S status lines of not-current windows
|
||||
@@ -4713,8 +4735,10 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
local to buffer
|
||||
{not in Vi}
|
||||
Characters that form pairs. The |%| command jumps from one to the
|
||||
other. Currently only single byte character pairs are allowed, and
|
||||
they must be different. The characters must be separated by a colon.
|
||||
other.
|
||||
Only character pairs are allowed that are different, thus you cannot
|
||||
jump between two double quotes.
|
||||
The characters must be separated by a colon.
|
||||
The pairs must be separated by a comma. Example for including '<' and
|
||||
'>' (HTML): >
|
||||
:set mps+=<:>
|
||||
@@ -5492,6 +5516,19 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
matches will be highlighted. This is used to avoid that Vim hangs
|
||||
when using a very complicated pattern.
|
||||
|
||||
*'regexpengine'* *'re'*
|
||||
'regexpengine' 're' number (default 0)
|
||||
global
|
||||
{not in Vi}
|
||||
This selects the default regexp engine. |two-engines|
|
||||
The possible values are:
|
||||
0 automatic selection
|
||||
1 old engine
|
||||
2 NFA engine
|
||||
Note that when using the NFA engine and the pattern contains something
|
||||
that is not supported the pattern will not match. This is only useful
|
||||
for debugging the regexp engine.
|
||||
|
||||
*'relativenumber'* *'rnu'* *'norelativenumber'* *'nornu'*
|
||||
'relativenumber' 'rnu' boolean (default off)
|
||||
local to window
|
||||
@@ -6119,7 +6156,8 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
local to buffer
|
||||
Number of spaces to use for each step of (auto)indent. Used for
|
||||
|'cindent'|, |>>|, |<<|, etc.
|
||||
When zero the 'ts' value will be used.
|
||||
When zero the 'ts' value will be used. Use the |shiftwidth()|
|
||||
function to get the effective shiftwidth value.
|
||||
|
||||
*'shortmess'* *'shm'*
|
||||
'shortmess' 'shm' string (Vim default "filnxtToO", Vi default: "",
|
||||
@@ -6383,6 +6421,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
of 8, while being able to edit like it is set to 'sts'. However,
|
||||
commands like "x" still work on the actual characters.
|
||||
When 'sts' is zero, this feature is off.
|
||||
When 'sts' is negative, the value of 'shiftwidth' is used.
|
||||
'softtabstop' is set to 0 when the 'paste' option is set.
|
||||
See also |ins-expandtab|. When 'expandtab' is not set, the number of
|
||||
spaces is minimized by using <Tab>s.
|
||||
@@ -7073,7 +7112,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
{not in Vi}
|
||||
Encoding used for the terminal. This specifies what character
|
||||
encoding the keyboard produces and the display will understand. For
|
||||
the GUI it only applies to the keyboard ('encoding' is used for the
|
||||
the GUI it only applies to the keyboard ( 'encoding' is used for the
|
||||
display). Except for the Mac when 'macatsui' is off, then
|
||||
'termencoding' should be "macroman".
|
||||
In the Win32 console version the default value is the console codepage
|
||||
@@ -7482,7 +7521,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
given, no further entry is used.
|
||||
See |undo-persistence|.
|
||||
|
||||
*'undofile'* *'udf'*
|
||||
*'undofile'* *'noundofile'* *'udf'* *'noudf'*
|
||||
'undofile' 'udf' boolean (default off)
|
||||
local to buffer
|
||||
{not in Vi}
|
||||
@@ -7494,7 +7533,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
For more information about this feature see |undo-persistence|.
|
||||
The undo file is not read when 'undoreload' causes the buffer from
|
||||
before a reload to be saved for undo.
|
||||
WARNING: this is a very new feature. Use at your own risk!
|
||||
When 'undofile' is turned off the undo file is NOT deleted.
|
||||
|
||||
*'undolevels'* *'ul'*
|
||||
'undolevels' 'ul' number (default 100, 1000 for Unix, VMS,
|
||||
@@ -7887,7 +7926,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
global
|
||||
{not in Vi}
|
||||
When set case is ignored when completing file names and directories.
|
||||
Has no effect on systems where file name case is generally ignored.
|
||||
Has no effect when 'fileignorecase' is set.
|
||||
Does not apply when the shell is used to expand wildcards, which
|
||||
happens when there are special characters.
|
||||
|
||||
@@ -7906,6 +7945,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
CTRL-P/CTRL-N, cause the highlight to move to the appropriate match.
|
||||
When 'wildmode' is used, "wildmenu" mode is used where "full" is
|
||||
specified. "longest" and "list" do not start "wildmenu" mode.
|
||||
You can check the current mode with |wildmenumode()|.
|
||||
If there are more matches than can fit in the line, a ">" is shown on
|
||||
the right and/or a "<" is shown on the left. The status line scrolls
|
||||
as needed.
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*pattern.txt* For Vim version 7.3. Last change: 2012 May 18
|
||||
*pattern.txt* For Vim version 7.3. Last change: 2013 May 29
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -350,6 +350,27 @@ For starters, read chapter 27 of the user manual |usr_27.txt|.
|
||||
or \z( pattern \) |/\z(|
|
||||
|
||||
|
||||
*/\%#=* *two-engines*
|
||||
Vim includes two regexp engines:
|
||||
1. An old, backtracking engine that supports everything.
|
||||
2. A new, NFA engine that works much faster on some patterns, but does not
|
||||
support everything.
|
||||
|
||||
Vim will automatically select the right engine for you. However, if you run
|
||||
into a problem or want to specifically select one engine or the other, you can
|
||||
prepend one of the following to the pattern:
|
||||
|
||||
\%#=0 Force automatic selection. Only has an effect when
|
||||
'regexpengine' has been set to a non-zero value.
|
||||
\%#=1 Force using the old engine.
|
||||
\%#=2 Force using the NFA engine.
|
||||
|
||||
You can also use the 'regexpengine' option to change the default.
|
||||
|
||||
*E864* *E868* *E874* *E875* *E876* *E877* *E878*
|
||||
If selecting the NFA engine and it runs into something that is not implemented
|
||||
the pattern will not match. This is only useful when debugging Vim.
|
||||
|
||||
==============================================================================
|
||||
3. Magic */magic*
|
||||
|
||||
@@ -396,9 +417,10 @@ pattern.
|
||||
|
||||
==============================================================================
|
||||
4. Overview of pattern items *pattern-overview*
|
||||
*E865* *E866* *E867* *E869*
|
||||
|
||||
Overview of multi items. */multi* *E61* *E62*
|
||||
More explanation and examples below, follow the links. *E64*
|
||||
More explanation and examples below, follow the links. *E64* *E871*
|
||||
|
||||
multi ~
|
||||
'magic' 'nomagic' matches of the preceding atom ~
|
||||
@@ -504,16 +526,18 @@ Character classes {not in Vi}: */character-classes*
|
||||
x x a character with no special meaning matches itself
|
||||
|
||||
|/[]| [] \[] any character specified inside the []
|
||||
|/\%[]| \%[] \%[] a sequence of optionally matched atoms
|
||||
|/\%[]| \%[] \%[] a sequence of optionally matched atoms
|
||||
|
||||
|/\c| \c \c ignore case, do not use the 'ignorecase' option
|
||||
|/\C| \C \C match case, do not use the 'ignorecase' option
|
||||
|/\Z| \Z \Z ignore differences in Unicode "combining characters".
|
||||
Useful when searching voweled Hebrew or Arabic text.
|
||||
|
||||
|/\m| \m \m 'magic' on for the following chars in the pattern
|
||||
|/\M| \M \M 'magic' off for the following chars in the pattern
|
||||
|/\v| \v \v the following chars in the pattern are "very magic"
|
||||
|/\V| \V \V the following chars in the pattern are "very nomagic"
|
||||
|/\Z| \Z \Z ignore differences in Unicode "combining characters".
|
||||
Useful when searching voweled Hebrew or Arabic text.
|
||||
|/\%#=| \%#=1 \%#=1 select regexp engine |/zero-width|
|
||||
|
||||
|/\%d| \%d \%d match specified decimal character (eg \%d123)
|
||||
|/\%x| \%x \%x match specified hex character (eg \%x2a)
|
||||
@@ -581,7 +605,7 @@ overview.
|
||||
\? Just like \=. Cannot be used when searching backwards with the "?"
|
||||
command. {not in Vi}
|
||||
|
||||
*/\{* *E58* *E60* *E554*
|
||||
*/\{* *E58* *E60* *E554* *E870*
|
||||
\{n,m} Matches n to m of the preceding atom, as many as possible
|
||||
\{n} Matches n of the preceding atom
|
||||
\{n,} Matches at least n of the preceding atom, as many as possible
|
||||
@@ -674,6 +698,7 @@ overview.
|
||||
For speed it's often much better to avoid this multi. Try using "\zs"
|
||||
instead |/\zs|. To match the same as the above example:
|
||||
an\_s\+\zsfile
|
||||
At least set a limit for the look-behind, see below.
|
||||
|
||||
"\@<=" and "\@<!" check for matches just before what follows.
|
||||
Theoretically these matches could start anywhere before this position.
|
||||
@@ -686,6 +711,18 @@ overview.
|
||||
Example matches ~
|
||||
\1\@<=,\([a-z]\+\) ",abc" in "abc,abc"
|
||||
|
||||
\@123<=
|
||||
Like "\@<=" but only look back 123 bytes. This avoids trying lots
|
||||
of matches that are known to fail and make executing the pattern very
|
||||
slow. Example, check if there is a "<" just before "span":
|
||||
/<\@1<=span
|
||||
This will try matching "<" only one byte before "span", which is the
|
||||
only place that works anyway.
|
||||
After crossing a line boundary, the limit is relative to the end of
|
||||
the line. Thus the characters at the start of the line with the match
|
||||
are not counted (this is just to keep it simple).
|
||||
The number zero is the same as no limit.
|
||||
|
||||
*/\@<!*
|
||||
\@<! Matches with zero width if the preceding atom does NOT match just
|
||||
before what follows. Thus this matches if there is no position in the
|
||||
@@ -695,11 +732,16 @@ overview.
|
||||
The match with the preceding atom is made to end just before the match
|
||||
with what follows, thus an atom that ends in ".*" will work.
|
||||
Warning: This can be slow (because many positions need to be checked
|
||||
for a match).
|
||||
for a match). Use a limit if you can, see below.
|
||||
Example matches ~
|
||||
\(foo\)\@<!bar any "bar" that's not in "foobar"
|
||||
\(\/\/.*\)\@<!in "in" which is not after "//"
|
||||
|
||||
\@123<!
|
||||
Like "\@<!" but only look back 123 bytes. This avoids trying lots of
|
||||
matches that are known to fail and make executing the pattern very
|
||||
slow.
|
||||
|
||||
*/\@>*
|
||||
\@> Matches the preceding atom like matching a whole pattern. {not in Vi}
|
||||
Like "(?>pattern)" in Perl.
|
||||
@@ -962,7 +1004,8 @@ match ASCII characters, as indicated by the range.
|
||||
~ matches the last given substitute string */~* */\~*
|
||||
|
||||
\(\) A pattern enclosed by escaped parentheses. */\(* */\(\)* */\)*
|
||||
E.g., "\(^a\)" matches 'a' at the start of a line. *E51* *E54* *E55*
|
||||
E.g., "\(^a\)" matches 'a' at the start of a line.
|
||||
*E51* *E54* *E55* *E872* *E873*
|
||||
|
||||
\1 Matches the same string that was matched by */\1* *E65*
|
||||
the first sub-expression in \( and \). {not in Vi}
|
||||
@@ -993,6 +1036,8 @@ x A single character, with no special meaning, matches itself
|
||||
[xyz] any 'x', 'y' or 'z'
|
||||
[a-zA-Z]$ any alphabetic character at the end of a line
|
||||
\c[a-z]$ same
|
||||
[А-яЁё] Russian alphabet (with utf-8 and cp1251)
|
||||
|
||||
*/[\n]*
|
||||
With "\_" prepended the collection also includes the end-of-line.
|
||||
The same can be done by including "\n" in the collection. The
|
||||
@@ -1059,6 +1104,8 @@ x A single character, with no special meaning, matches itself
|
||||
any character that's not in "^]-\bdertnoUux". "[\xyz]" matches '\',
|
||||
'x', 'y' and 'z'. It's better to use "\\" though, future expansions
|
||||
may use other characters after '\'.
|
||||
- Omitting the trailing ] is not considered an error. "[]" works like
|
||||
"[]]", it matches the ']' character.
|
||||
- The following translations are accepted when the 'l' flag is not
|
||||
included in 'cpoptions' {not in Vi}:
|
||||
\e <Esc>
|
||||
@@ -1164,6 +1211,8 @@ When "\Z" appears anywhere in the pattern, composing characters are ignored.
|
||||
Thus only the base characters need to match, the composing characters may be
|
||||
different and the number of composing characters may differ. Only relevant
|
||||
when 'encoding' is "utf-8".
|
||||
Exception: If the pattern starts with one or more composing characters, these
|
||||
must match.
|
||||
|
||||
When a composing character appears at the start of the pattern of after an
|
||||
item that doesn't include the composing character, a match is found at any
|
||||
@@ -1173,8 +1222,20 @@ When using a dot and a composing character, this works the same as the
|
||||
composing character by itself, except that it doesn't matter what comes before
|
||||
this.
|
||||
|
||||
The order of composing characters matters, even though changing the order
|
||||
doesn't change what a character looks like. This may change in the future.
|
||||
The order of composing characters does not matter. Also, the text may have
|
||||
more composing characters than the pattern, it still matches. But all
|
||||
composing characters in the pattern must be found in the text.
|
||||
|
||||
Suppose B is a base character and x and y are composing characters:
|
||||
pattern text match ~
|
||||
Bxy Bxy yes (perfect match)
|
||||
Bxy Byx yes (order ignored)
|
||||
Bxy By no (x missing)
|
||||
Bxy Bx no (y missing)
|
||||
Bx Bx yes (perfect mach)
|
||||
Bx By no (x missing)
|
||||
Bx Bxy yes (extra y ignored)
|
||||
Bx Byx yes (extra y ignored)
|
||||
|
||||
==============================================================================
|
||||
9. Compare with Perl patterns *perl-patterns*
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
*pi_getscript.txt* For Vim version 7.0. Last change: 2011 Jun 23
|
||||
*pi_getscript.txt* For Vim version 7.0. Last change: 2012 Apr 07
|
||||
>
|
||||
GETSCRIPT REFERENCE MANUAL by Charles E. Campbell, Jr.
|
||||
GETSCRIPT REFERENCE MANUAL by Charles E. Campbell
|
||||
<
|
||||
Authors: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamilyA.Mbiz>
|
||||
Authors: Charles E. Campbell <NdrOchip@ScampbellPfamilyA.Mbiz>
|
||||
(remove NOSPAM from the email address)
|
||||
*GetLatestVimScripts-copyright*
|
||||
Copyright: (c) 2004-2012 by Charles E. Campbell, Jr. *glvs-copyright*
|
||||
Copyright: (c) 2004-2012 by Charles E. Campbell *glvs-copyright*
|
||||
The VIM LICENSE (see |copyright|) applies to the files in this
|
||||
package, including getscriptPlugin.vim, getscript.vim,
|
||||
GetLatestVimScripts.dist, and pi_getscript.txt, except use "getscript"
|
||||
@@ -343,6 +343,11 @@ after/syntax/c.vim contained in it to overwrite a user's c.vim.
|
||||
default= $HOME/vimfiles (windows)
|
||||
Override where :AutoInstall: scripts will be installed.
|
||||
Doesn't override vimball installation.
|
||||
>
|
||||
g:GetLatestVimScripts_scriptaddr
|
||||
< default='http://vim.sourceforge.net/script.php?script_id='
|
||||
Override this if your system needs
|
||||
... ='http://vim.sourceforge.net/script/script.php?script_id='
|
||||
|
||||
==============================================================================
|
||||
8. GetLatestVimScripts Algorithm *glvs-algorithm* *glvs-alg*
|
||||
@@ -380,7 +385,11 @@ The AutoInstall process will:
|
||||
==============================================================================
|
||||
9. GetLatestVimScripts History *getscript-history* *glvs-hist* {{{1
|
||||
|
||||
v44 Jun 23, 2011 : * handles additional decompression options for tarballs
|
||||
v35 Apr 07, 2012 : * (MengHuan Yu) pointed out that the script url has
|
||||
changed (somewhat). However, it doesn't work, and
|
||||
the original one does (under Linux). I'll make it
|
||||
yet-another-option.
|
||||
v34 Jun 23, 2011 : * handles additional decompression options for tarballs
|
||||
(tgz taz tbz txz)
|
||||
v33 May 31, 2011 : * using fnameescape() instead of escape()
|
||||
* *.xz support
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,4 +1,4 @@
|
||||
*pi_paren.txt* For Vim version 7.3. Last change: 2008 Jun 16
|
||||
*pi_paren.txt* For Vim version 7.3. Last change: 2013 May 08
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -46,7 +46,10 @@ are:
|
||||
closed folds.
|
||||
- 'synmaxcol' times 2 bytes before or after the cursor to avoid a delay
|
||||
in a long line with syntax highlighting.
|
||||
|
||||
- A timeout of 300 msec (60 msec in Insert mode). This can be changed with the
|
||||
g:matchparen_timeout and g:matchparen_insert_timeout variables and their
|
||||
buffer-local equivalents b:matchparen_timeout and
|
||||
b:matchparen_insert_timeout.
|
||||
|
||||
If you would like the |%| command to work better, the matchit plugin can be
|
||||
used, see |matchit-install|. This plugin also helps to skip matches in
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
*pi_tar.txt* For Vim version 7.3. Last change: 2012 Jan 17
|
||||
*pi_tar.txt* For Vim version 7.3. Last change: 2013 Apr 17
|
||||
|
||||
+====================+
|
||||
| Tar File Interface |
|
||||
+====================+
|
||||
|
||||
Author: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamily.AbizM>
|
||||
Author: Charles E. Campbell <NdrOchip@ScampbellPfamily.AbizM>
|
||||
(remove NOSPAM from Campbell's email first)
|
||||
Copyright 2005-2012: *tar-copyright*
|
||||
The VIM LICENSE (see |copyright|) applies to the files in this
|
||||
@@ -50,6 +50,21 @@ Copyright 2005-2012: *tar-copyright*
|
||||
*g:tar_extractcmd* , which by default is >
|
||||
"tar -xf"
|
||||
<
|
||||
*:TarDiff*
|
||||
DIFFERENCING SUPPORT~
|
||||
|
||||
:TarDiff [filename]
|
||||
|
||||
This command will attempt to show the differences between the tarball
|
||||
version of a file and the associated file on the system. In order to
|
||||
find that file on the system, the script uses the path associated with
|
||||
the file mentioned in the tarball. If the current directory is not
|
||||
correct for that path, :TarDiff will fail to find the associated file.
|
||||
|
||||
If the [filename] is given, that that filename (and path) will be used
|
||||
to specify the associated file.
|
||||
|
||||
|
||||
PREVENTING LOADING~
|
||||
|
||||
If for some reason you do not wish to use vim to examine tar'd files,
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
*pi_zip.txt* For Vim version 7.3. Last change: 2012 Jan 17
|
||||
*pi_zip.txt* For Vim version 7.3. Last change: 2013 Apr 17
|
||||
|
||||
+====================+
|
||||
| Zip File Interface |
|
||||
+====================+
|
||||
|
||||
Author: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamily.AbizM>
|
||||
Author: Charles E. Campbell <NdrOchip@ScampbellPfamily.AbizM>
|
||||
(remove NOSPAM from Campbell's email first)
|
||||
Copyright: Copyright (C) 2005-2011 Charles E Campbell, Jr *zip-copyright*
|
||||
Copyright: Copyright (C) 2005-2012 Charles E Campbell *zip-copyright*
|
||||
The VIM LICENSE (see |copyright|) applies to the files in this
|
||||
package, including zipPlugin.vim, zip.vim, and pi_zip.vim. except use
|
||||
"zip.vim" instead of "VIM". Like anything else that's free, zip.vim
|
||||
@@ -85,8 +85,13 @@ Copyright: Copyright (C) 2005-2011 Charles E Campbell, Jr *zip-copyright*
|
||||
|
||||
==============================================================================
|
||||
4. History *zip-history* {{{1
|
||||
v26 Nov 15, 2012 * (Jason Spiro) provided a lot of new extensions that
|
||||
are synonyms for .zip
|
||||
v25 Jun 27, 2011 * using keepj with unzip -Z
|
||||
(consistent with the -p variant)
|
||||
* (Ben Staniford) now uses
|
||||
has("win32unix") && executable("cygpath")
|
||||
before converting to cygwin-style paths
|
||||
v24 Jun 21, 2010 * (Cédric Bosdonnat) unzip seems to need its filenames
|
||||
fnameescape'd as well as shellquote'd
|
||||
* (Motoya Kurotsu) inserted keepj before 0d to protect
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*quickfix.txt* For Vim version 7.3. Last change: 2011 May 10
|
||||
*quickfix.txt* For Vim version 7.3. Last change: 2013 Mar 07
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -574,6 +574,8 @@ commands can be combined to create a NewGrep command: >
|
||||
'ignorecase' applies. To overrule it put |/\c| in the
|
||||
pattern to ignore case or |/\C| to match case.
|
||||
'smartcase' is not used.
|
||||
If {pattern} is empty (e.g. // is specified), the last
|
||||
used search pattern is used. |last-pattern|
|
||||
|
||||
When a number is put before the command this is used
|
||||
as the maximum number of matches to find. Use
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*quickref.txt* For Vim version 7.3. Last change: 2012 Feb 22
|
||||
*quickref.txt* For Vim version 7.3. Last change: 2013 May 20
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
*quickref* *Contents*
|
||||
tag subject tag subject ~
|
||||
|Q_ct| list of help files |Q_re| Repeating commands
|
||||
|Q_ct| list of help files |Q_re| Repeating commands
|
||||
|Q_lr| motion: Left-right |Q_km| Key mapping
|
||||
|Q_ud| motion: Up-down |Q_ab| Abbreviations
|
||||
|Q_tm| motion: Text object |Q_op| Options
|
||||
@@ -27,7 +27,7 @@
|
||||
|Q_co| change: Complex |Q_bu| Buffer list commands
|
||||
|Q_vi| Visual mode |Q_sy| Syntax highlighting
|
||||
|Q_to| Text objects |Q_gu| GUI commands
|
||||
|Q_fo| Folding
|
||||
|Q_fo| Folding
|
||||
|
||||
------------------------------------------------------------------------------
|
||||
N is used to indicate an optional count that can be given before the command.
|
||||
@@ -186,7 +186,7 @@ N is used to indicate an optional count that can be given before the command.
|
||||
|:marks| :marks print the active marks
|
||||
|CTRL-O| N CTRL-O go to Nth older position in jump list
|
||||
|CTRL-I| N CTRL-I go to Nth newer position in jump list
|
||||
|:ju| :ju[mps] print the jump list
|
||||
|:ju| :ju[mps] print the jump list
|
||||
------------------------------------------------------------------------------
|
||||
*Q_vm* Various motions
|
||||
|
||||
@@ -204,30 +204,30 @@ N is used to indicate an optional count that can be given before the command.
|
||||
------------------------------------------------------------------------------
|
||||
*Q_ta* Using tags
|
||||
|
||||
|:ta| :ta[g][!] {tag} jump to tag {tag}
|
||||
|:ta| :[count]ta[g][!] jump to [count]'th newer tag in tag list
|
||||
|:ta| :ta[g][!] {tag} jump to tag {tag}
|
||||
|:ta| :[count]ta[g][!] jump to [count]'th newer tag in tag list
|
||||
|CTRL-]| CTRL-] jump to the tag under cursor, unless changes
|
||||
have been made
|
||||
|:ts| :ts[elect][!] [tag] list matching tags and select one to jump to
|
||||
|:ts| :ts[elect][!] [tag] list matching tags and select one to jump to
|
||||
|:tjump| :tj[ump][!] [tag] jump to tag [tag] or select from list when
|
||||
there are multiple matches
|
||||
|:ltag| :lt[ag][!] [tag] jump to tag [tag] and add matching tags to the
|
||||
|:ltag| :lt[ag][!] [tag] jump to tag [tag] and add matching tags to the
|
||||
location list
|
||||
|
||||
|:tags| :tags print tag list
|
||||
|:tags| :tags print tag list
|
||||
|CTRL-T| N CTRL-T jump back from Nth older tag in tag list
|
||||
|:po| :[count]po[p][!] jump back from [count]'th older tag in tag list
|
||||
|:po| :[count]po[p][!] jump back from [count]'th older tag in tag list
|
||||
|:tnext| :[count]tn[ext][!] jump to [count]'th next matching tag
|
||||
|:tp| :[count]tp[revious][!] jump to [count]'th previous matching tag
|
||||
|:tr| :[count]tr[ewind][!] jump to [count]'th matching tag
|
||||
|:tl| :tl[ast][!] jump to last matching tag
|
||||
|:tr| :[count]tr[ewind][!] jump to [count]'th matching tag
|
||||
|:tl| :tl[ast][!] jump to last matching tag
|
||||
|
||||
|:ptag| :pt[ag] {tag} open a preview window to show tag {tag}
|
||||
|CTRL-W_}| CTRL-W } like CTRL-] but show tag in preview window
|
||||
|:ptag| :pt[ag] {tag} open a preview window to show tag {tag}
|
||||
|CTRL-W_}| CTRL-W } like CTRL-] but show tag in preview window
|
||||
|:pts| :pts[elect] like ":tselect" but show tag in preview window
|
||||
|:ptjump| :ptj[ump] like ":tjump" but show tag in preview window
|
||||
|:pclose| :pc[lose] close tag preview window
|
||||
|CTRL-W_z| CTRL-W z close tag preview window
|
||||
|CTRL-W_z| CTRL-W z close tag preview window
|
||||
------------------------------------------------------------------------------
|
||||
*Q_sc* Scrolling
|
||||
|
||||
@@ -260,7 +260,7 @@ These only work when 'wrap' is off:
|
||||
|:startreplace| :startr[eplace][!] start Replace mode, at EOL when [!] used
|
||||
|
||||
in Visual block mode:
|
||||
|v_b_I| I insert the same text in front of all the selected lines
|
||||
|v_b_I| I insert the same text in front of all the selected lines
|
||||
|v_b_A| A append the same text after all the selected lines
|
||||
------------------------------------------------------------------------------
|
||||
*Q_ai* Insert mode keys
|
||||
@@ -334,16 +334,16 @@ In Insert or Command-line mode:
|
||||
*Q_de* Deleting text
|
||||
|
||||
|x| N x delete N characters under and after the cursor
|
||||
|<Del>| N <Del> delete N characters under and after the cursor
|
||||
|<Del>| N <Del> delete N characters under and after the cursor
|
||||
|X| N X delete N characters before the cursor
|
||||
|d| N d{motion} delete the text that is moved over with {motion}
|
||||
|v_d| {visual}d delete the highlighted text
|
||||
|v_d| {visual}d delete the highlighted text
|
||||
|dd| N dd delete N lines
|
||||
|D| N D delete to the end of the line (and N-1 more lines)
|
||||
|J| N J join N-1 lines (delete <EOL>s)
|
||||
|v_J| {visual}J join the highlighted lines
|
||||
|v_J| {visual}J join the highlighted lines
|
||||
|gJ| N gJ like "J", but without inserting spaces
|
||||
|v_gJ| {visual}gJ like "{visual}J", but without inserting spaces
|
||||
|v_gJ| {visual}gJ like "{visual}J", but without inserting spaces
|
||||
|:d| :[range]d [x] delete [range] lines [into register x]
|
||||
------------------------------------------------------------------------------
|
||||
*Q_cm* Copying and moving text
|
||||
@@ -369,7 +369,7 @@ In Insert or Command-line mode:
|
||||
|R| N R enter Replace mode (repeat the entered text N times)
|
||||
|gR| N gR enter virtual Replace mode: Like Replace mode but
|
||||
without affecting layout
|
||||
|v_b_r| {visual}r{char}
|
||||
|v_b_r| {visual}r{char}
|
||||
in Visual block mode: Replace each char of the
|
||||
selected text with {char}
|
||||
|
||||
@@ -447,13 +447,13 @@ In Insert or Command-line mode:
|
||||
|
||||
|visual-index| list of Visual mode commands.
|
||||
|
||||
|v| v start highlighting characters } move cursor and use
|
||||
|V| V start highlighting linewise } operator to affect
|
||||
|v| v start highlighting characters } move cursor and use
|
||||
|V| V start highlighting linewise } operator to affect
|
||||
|CTRL-V| CTRL-V start highlighting blockwise } highlighted text
|
||||
|v_o| o exchange cursor position with start of highlighting
|
||||
|gv| gv start highlighting on previous visual area
|
||||
|v_v| v highlight characters or stop highlighting
|
||||
|v_V| V highlight linewise or stop highlighting
|
||||
|v_o| o exchange cursor position with start of highlighting
|
||||
|gv| gv start highlighting on previous visual area
|
||||
|v_v| v highlight characters or stop highlighting
|
||||
|v_V| V highlight linewise or stop highlighting
|
||||
|v_CTRL-V| CTRL-V highlight blockwise or stop highlighting
|
||||
------------------------------------------------------------------------------
|
||||
*Q_to* Text objects (only in Visual mode or after an operator)
|
||||
@@ -509,8 +509,8 @@ In Insert or Command-line mode:
|
||||
------------------------------------------------------------------------------
|
||||
*Q_km* Key mapping
|
||||
|
||||
|:map| :ma[p] {lhs} {rhs} map {lhs} to {rhs} in Normal and Visual mode
|
||||
|:map!| :ma[p]! {lhs} {rhs} map {lhs} to {rhs} in Insert and Command-line
|
||||
|:map| :ma[p] {lhs} {rhs} map {lhs} to {rhs} in Normal and Visual mode
|
||||
|:map!| :ma[p]! {lhs} {rhs} map {lhs} to {rhs} in Insert and Command-line
|
||||
mode
|
||||
|:noremap| :no[remap][!] {lhs} {rhs}
|
||||
same as ":map", no remapping for this {rhs}
|
||||
@@ -522,19 +522,19 @@ In Insert or Command-line mode:
|
||||
Normal and Visual mode
|
||||
|:map_l!| :ma[p]! [lhs] list mappings (starting with [lhs]) for
|
||||
Insert and Command-line mode
|
||||
|:cmap| :cmap/:cunmap/:cnoremap
|
||||
|:cmap| :cmap/:cunmap/:cnoremap
|
||||
like ":map!"/":unmap!"/":noremap!" but for
|
||||
Command-line mode only
|
||||
|:imap| :imap/:iunmap/:inoremap
|
||||
|:imap| :imap/:iunmap/:inoremap
|
||||
like ":map!"/":unmap!"/":noremap!" but for
|
||||
Insert mode only
|
||||
|:nmap| :nmap/:nunmap/:nnoremap
|
||||
|:nmap| :nmap/:nunmap/:nnoremap
|
||||
like ":map"/":unmap"/":noremap" but for
|
||||
Normal mode only
|
||||
|:vmap| :vmap/:vunmap/:vnoremap
|
||||
|:vmap| :vmap/:vunmap/:vnoremap
|
||||
like ":map"/":unmap"/":noremap" but for
|
||||
Visual mode only
|
||||
|:omap| :omap/:ounmap/:onoremap
|
||||
|:omap| :omap/:ounmap/:onoremap
|
||||
like ":map"/":unmap"/":noremap" but only for
|
||||
when an operator is pending
|
||||
|:mapc| :mapc[lear] remove mappings for Normal and Visual mode
|
||||
@@ -691,6 +691,7 @@ Short explanation of each option: *option-list*
|
||||
'fileencodings' 'fencs' automatically detected character encodings
|
||||
'fileformat' 'ff' file format used for file I/O
|
||||
'fileformats' 'ffs' automatically detected values for 'fileformat'
|
||||
'fileignorecase' 'fic' ignore case when using file names
|
||||
'filetype' 'ft' type of file, used for autocommands
|
||||
'fillchars' 'fcs' characters to use for displaying special items
|
||||
'fkmap' 'fk' Farsi keyboard mapping
|
||||
@@ -823,6 +824,7 @@ Short explanation of each option: *option-list*
|
||||
'quoteescape' 'qe' escape characters used in a string
|
||||
'readonly' 'ro' disallow writing the buffer
|
||||
'redrawtime' 'rdt' timeout for 'hlsearch' and |:match| highlighting
|
||||
'regexpengine' 're' default regexp engine to use
|
||||
'relativenumber' 'rnu' show relative line number in front of each line
|
||||
'remap' allow mappings to work recursively
|
||||
'report' threshold for reporting nr. of lines changed
|
||||
@@ -958,9 +960,9 @@ Short explanation of each option: *option-list*
|
||||
------------------------------------------------------------------------------
|
||||
*Q_ur* Undo/Redo commands
|
||||
|
||||
|u| N u undo last N changes
|
||||
|u| N u undo last N changes
|
||||
|CTRL-R| N CTRL-R redo last N undone changes
|
||||
|U| U restore last changed line
|
||||
|U| U restore last changed line
|
||||
------------------------------------------------------------------------------
|
||||
*Q_et* External commands
|
||||
|
||||
@@ -1011,7 +1013,7 @@ Short explanation of each option: *option-list*
|
||||
C4350, etc.)
|
||||
|:normal| :norm[al][!] {commands}
|
||||
execute Normal mode commands
|
||||
|Q| Q switch to "Ex" mode
|
||||
|Q| Q switch to "Ex" mode
|
||||
|
||||
|:redir| :redir >{file} redirect messages to {file}
|
||||
|:silent| :silent[!] {command} execute {command} silently
|
||||
@@ -1087,11 +1089,11 @@ Context-sensitive completion on the command-line:
|
||||
------------------------------------------------------------------------------
|
||||
*Q_ex* Special Ex characters
|
||||
|
||||
|:bar| | separates two commands (not for ":global" and ":!")
|
||||
|:bar| | separates two commands (not for ":global" and ":!")
|
||||
|:quote| " begins comment
|
||||
|
||||
|:_%| % current file name (only where a file name is expected)
|
||||
|:_#| #[num] alternate file name [num] (only where a file name is
|
||||
|:_%| % current file name (only where a file name is expected)
|
||||
|:_#| #[num] alternate file name [num] (only where a file name is
|
||||
expected)
|
||||
Note: The next seven are typed literally; these are not special keys!
|
||||
|:<abuf>| <abuf> buffer number, for use in an autocommand (only where a
|
||||
@@ -1171,18 +1173,18 @@ Context-sensitive completion on the command-line:
|
||||
Without !: Fail if changes have been made to the current buffer.
|
||||
With !: Discard any changes to the current buffer.
|
||||
|:edit_f| :e[dit][!] {file} edit {file}
|
||||
|:edit| :e[dit][!] reload the current file
|
||||
|:enew| :ene[w][!] edit a new, unnamed buffer
|
||||
|:edit| :e[dit][!] reload the current file
|
||||
|:enew| :ene[w][!] edit a new, unnamed buffer
|
||||
|:find| :fin[d][!] {file} find {file} in 'path' and edit it
|
||||
|
||||
|CTRL-^| N CTRL-^ edit alternate file N (equivalent to ":e #N")
|
||||
|gf| gf or ]f edit the file whose name is under the cursor
|
||||
|:pwd| :pwd print the current directory name
|
||||
|:cd| :cd [path] change the current directory to [path]
|
||||
|:cd-| :cd - back to previous current directory
|
||||
|:file| :f[ile] print the current file name and the cursor
|
||||
|CTRL-^| N CTRL-^ edit alternate file N (equivalent to ":e #N")
|
||||
|gf| gf or ]f edit the file whose name is under the cursor
|
||||
|:pwd| :pwd print the current directory name
|
||||
|:cd| :cd [path] change the current directory to [path]
|
||||
|:cd-| :cd - back to previous current directory
|
||||
|:file| :f[ile] print the current file name and the cursor
|
||||
position
|
||||
|:file| :f[ile] {name} set the current file name to {name}
|
||||
|:file| :f[ile] {name} set the current file name to {name}
|
||||
|:files| :files show alternate file names
|
||||
------------------------------------------------------------------------------
|
||||
*Q_fl* Using the argument list |argument-list|
|
||||
@@ -1198,12 +1200,12 @@ Context-sensitive completion on the command-line:
|
||||
|
||||
in current window in new window ~
|
||||
|:argument| :argu[ment] N :sar[gument] N edit file N
|
||||
|:next| :n[ext] :sn[ext] edit next file
|
||||
|:next| :n[ext] :sn[ext] edit next file
|
||||
|:next_f| :n[ext] {arglist} :sn[ext] {arglist} define new arg list
|
||||
and edit first file
|
||||
|:Next| :N[ext] :sN[ext] edit previous file
|
||||
|:Next| :N[ext] :sN[ext] edit previous file
|
||||
|:first| :fir[st] :sfir[st] edit first file
|
||||
|:last| :la[st] :sla[st] edit last file
|
||||
|:last| :la[st] :sla[st] edit last file
|
||||
------------------------------------------------------------------------------
|
||||
*Q_wq* Writing and quitting
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*starting.txt* For Vim version 7.3. Last change: 2012 Mar 16
|
||||
*starting.txt* For Vim version 7.3. Last change: 2013 May 29
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -438,6 +438,10 @@ a slash. Thus "-R" means recovery and "-/R" readonly.
|
||||
option should be used when Vim is started by a program that
|
||||
will wait for the edit session to finish (e.g., mail or
|
||||
readnews). See |amiga-window|.
|
||||
|
||||
MS-Windows: This option is not supported. However, when
|
||||
running Vim with an installed vim.bat or gvim.bat file it
|
||||
works.
|
||||
{not in Vi}
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*syntax.txt* For Vim version 7.3. Last change: 2012 Jul 16
|
||||
*syntax.txt* For Vim version 7.3. Last change: 2013 May 31
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -381,7 +381,11 @@ This is not a syntax file itself, but a script that converts the current
|
||||
window into HTML. Vim opens a new window in which it builds the HTML file.
|
||||
|
||||
After you save the resulting file, you can view it with any browser. The
|
||||
colors should be exactly the same as you see them in Vim.
|
||||
colors should be exactly the same as you see them in Vim. You can jump to
|
||||
specific lines by adding (for example) #L123 or #123 to the end of the URL in
|
||||
your browser's address bar (#123 only with javascript support). And with
|
||||
|g:html_dynamic_folds| enabled, you can show or hide the text that is folded
|
||||
in Vim.
|
||||
|
||||
You are not supposed to set the 'filetype' or 'syntax' option to "2html"!
|
||||
Source the script to convert the current file: >
|
||||
@@ -424,7 +428,11 @@ and last line to be converted. Example, using the last set Visual area: >
|
||||
|g:html_diff_one_file| is set, :TOhtml will convert
|
||||
all windows which are part of the diff in the current
|
||||
tab and place them side-by-side in a <table> element
|
||||
in the generated HTML.
|
||||
in the generated HTML. When this happens you can jump
|
||||
to lines in specific windows with (for example) #W1L42
|
||||
for line 42 in the first diffed window, or #W3L87 for
|
||||
line 87 in the third. Omitting the window ID will
|
||||
default to the first window if javascript is enabled.
|
||||
|
||||
Examples: >
|
||||
|
||||
@@ -999,6 +1007,14 @@ comment highlighting, add the following line to your startup file: >
|
||||
The ColdFusion syntax file is based on the HTML syntax file.
|
||||
|
||||
|
||||
CPP *cpp.vim* *ft-cpp-syntax*
|
||||
|
||||
Most of things are same as |ft-c-syntax|.
|
||||
|
||||
Variable Highlight ~
|
||||
cpp_no_c11 don't highlight C++11 standard items
|
||||
|
||||
|
||||
CSH *csh.vim* *ft-csh-syntax*
|
||||
|
||||
This covers the shell named "csh". Note that on some systems tcsh is actually
|
||||
@@ -1090,6 +1106,10 @@ Simpler is setting the filetype to "docbkxml" or "docbksgml": >
|
||||
or: >
|
||||
:set filetype=docbkxml
|
||||
|
||||
You can specify the DocBook version: >
|
||||
:let docbk_ver = 3
|
||||
When not set 4 is used.
|
||||
|
||||
|
||||
DOSBATCH *dosbatch.vim* *ft-dosbatch-syntax*
|
||||
|
||||
@@ -1227,17 +1247,17 @@ to your startup file.
|
||||
|
||||
ERLANG *erlang.vim* *ft-erlang-syntax*
|
||||
|
||||
The erlang highlighting supports Erlang (ERicsson LANGuage).
|
||||
Erlang is case sensitive and default extension is ".erl".
|
||||
Erlang is a functional programming language developed by Ericsson. Files with
|
||||
the following extensions are recognized as Erlang files: erl, hrl, yaws.
|
||||
|
||||
If you want to disable keywords highlighting, put in your .vimrc: >
|
||||
:let erlang_keywords = 1
|
||||
If you want to disable built-in-functions highlighting, put in your
|
||||
.vimrc file: >
|
||||
:let erlang_functions = 1
|
||||
If you want to disable special characters highlighting, put in
|
||||
your .vimrc: >
|
||||
:let erlang_characters = 1
|
||||
The BIFs (built-in functions) are highlighted by default. To disable this,
|
||||
put the following line in your vimrc: >
|
||||
|
||||
:let g:erlang_highlight_bifs = 0
|
||||
|
||||
To enable highlighting some special atoms, put this in your vimrc: >
|
||||
|
||||
:let g:erlang_highlight_special_atoms = 1
|
||||
|
||||
|
||||
FLEXWIKI *flexwiki.vim* *ft-flexwiki-syntax*
|
||||
@@ -2057,7 +2077,7 @@ Therefore, you should be careful about not using more space between sentences
|
||||
than you intend to have in your final document. For this reason, the common
|
||||
practice is to insert a carriage return immediately after all punctuation
|
||||
marks. If you want to have "even" text in your final processed output, you
|
||||
need to maintaining regular spacing in the input text. To mark both trailing
|
||||
need to maintain regular spacing in the input text. To mark both trailing
|
||||
spaces and two or more spaces after a punctuation as an error, use: >
|
||||
|
||||
:let nroff_space_errors = 1
|
||||
@@ -2274,7 +2294,7 @@ For highlighting parent error ] or ): >
|
||||
|
||||
let php_parent_error_close = 1
|
||||
|
||||
For skipping an php end tag, if there exists an open ( or [ without a closing
|
||||
For skipping a php end tag, if there exists an open ( or [ without a closing
|
||||
one: >
|
||||
|
||||
let php_parent_error_open = 1
|
||||
@@ -2436,24 +2456,33 @@ Pascal. Use this if you don't use assembly and Pascal: >
|
||||
|
||||
PYTHON *python.vim* *ft-python-syntax*
|
||||
|
||||
There are four options to control Python syntax highlighting.
|
||||
There are six options to control Python syntax highlighting.
|
||||
|
||||
For highlighted numbers: >
|
||||
:let python_highlight_numbers = 1
|
||||
:let python_no_number_highlight = 1
|
||||
|
||||
For highlighted builtin functions: >
|
||||
:let python_highlight_builtins = 1
|
||||
:let python_no_builtin_highlight = 1
|
||||
|
||||
For highlighted standard exceptions: >
|
||||
:let python_highlight_exceptions = 1
|
||||
:let python_no_exception_highlight = 1
|
||||
|
||||
For highlighted doctests and code inside: >
|
||||
:let python_no_doctest_highlight = 1
|
||||
or >
|
||||
:let python_no_doctest_code_highlight = 1
|
||||
(first option implies second one).
|
||||
|
||||
For highlighted trailing whitespace and mix of spaces and tabs: >
|
||||
:let python_highlight_space_errors = 1
|
||||
:let python_space_error_highlight = 1
|
||||
|
||||
If you want all possible Python highlighting (the same as setting the
|
||||
preceding three options): >
|
||||
preceding last option and unsetting all other ones): >
|
||||
:let python_highlight_all = 1
|
||||
|
||||
Note: only existence of these options matter, not their value. You can replace
|
||||
1 above with anything.
|
||||
|
||||
|
||||
QUAKE *quake.vim* *ft-quake-syntax*
|
||||
|
||||
@@ -2489,6 +2518,12 @@ This will add highlighting for the commands that BASH (version 2.05a and
|
||||
later, and part earlier) adds.
|
||||
|
||||
|
||||
RESTRUCTURED TEXT *rst.vim* *ft-rst-syntax*
|
||||
|
||||
You may set what syntax definitions should be used for code blocks via
|
||||
let rst_syntax_code_list = ['vim', 'lisp', ...]
|
||||
|
||||
|
||||
REXX *rexx.vim* *ft-rexx-syntax*
|
||||
|
||||
If you notice highlighting errors while scrolling backwards, which are fixed
|
||||
@@ -2901,6 +2936,35 @@ if any, is the text at the top of the screen supposed to be in?).
|
||||
Another cause of slow highlighting is due to syntax-driven folding; see
|
||||
|tex-folding| for a way around this.
|
||||
|
||||
*g:tex_fast*
|
||||
|
||||
Finally, if syntax highlighting is still too slow, you may set >
|
||||
|
||||
:let g:tex_fast= ""
|
||||
|
||||
in your .vimrc. Used this way, the g:tex_fast variable causes the syntax
|
||||
highlighting script to avoid defining any regions and associated
|
||||
synchronization. The result will be much faster syntax highlighting; the
|
||||
price: you will no longer have as much highlighting or any syntax-based
|
||||
folding, and you will be missing syntax-based error checking.
|
||||
|
||||
You may decide that some syntax is acceptable; you may use the following table
|
||||
selectively to enable just some syntax highlighting: >
|
||||
|
||||
b : allow bold and italic syntax
|
||||
c : allow texComment syntax
|
||||
m : allow texMatcher syntax (ie. {...} and [...])
|
||||
M : allow texMath syntax
|
||||
p : allow parts, chapter, section, etc syntax
|
||||
r : allow texRefZone syntax (nocite, bibliography, label, pageref, eqref)
|
||||
s : allow superscript/subscript regions
|
||||
S : allow texStyle syntax
|
||||
v : allow verbatim syntax
|
||||
V : allow texNewEnv and texNewCmd syntax
|
||||
<
|
||||
As an example, let g:tex_fast= "M" will allow math-associated highlighting
|
||||
but suppress all the other region-based syntax highlighting.
|
||||
|
||||
*tex-morecommands* *tex-package*
|
||||
Tex: Want To Highlight More Commands? ~
|
||||
|
||||
@@ -3795,7 +3859,7 @@ s-{nr} start of the matched pattern plus {nr} chars to the left
|
||||
e end of the matched pattern
|
||||
e+{nr} end of the matched pattern plus {nr} chars to the right
|
||||
e-{nr} end of the matched pattern plus {nr} chars to the left
|
||||
{nr} (for "lc" only): start matching {nr} chars to the left
|
||||
{nr} (for "lc" only): start matching {nr} chars right of the start
|
||||
|
||||
Examples: "ms=s+1", "hs=e-2", "lc=3".
|
||||
|
||||
@@ -3893,9 +3957,9 @@ External matches *:syn-ext-match*
|
||||
These extra regular expression items are available in region patterns:
|
||||
|
||||
*/\z(* */\z(\)* *E50* *E52*
|
||||
\z(\) Marks the sub-expression as "external", meaning that it is can
|
||||
be accessed from another pattern match. Currently only usable
|
||||
in defining a syntax region start pattern.
|
||||
\z(\) Marks the sub-expression as "external", meaning that it can be
|
||||
accessed from another pattern match. Currently only usable in
|
||||
defining a syntax region start pattern.
|
||||
|
||||
*/\z1* */\z2* */\z3* */\z4* */\z5*
|
||||
\z1 ... \z9 */\z6* */\z7* */\z8* */\z9* *E66* *E67*
|
||||
@@ -4582,7 +4646,8 @@ IncSearch 'incsearch' highlighting; also used for the text replaced with
|
||||
LineNr Line number for ":number" and ":#" commands, and when 'number'
|
||||
or 'relativenumber' option is set.
|
||||
*hl-CursorLineNr*
|
||||
CursorLineNr Like LineNr when 'cursorline' is set for the cursor line.
|
||||
CursorLineNr Like LineNr when 'cursorline' or 'relativenumber' is set for
|
||||
the cursor line.
|
||||
*hl-MatchParen*
|
||||
MatchParen The character under the cursor or just before it, if it
|
||||
is a paired bracket, and its match. |pi_paren.txt|
|
||||
@@ -4871,7 +4936,7 @@ restoring "b:current_syntax", since the syntax files do set
|
||||
|
||||
Once a window has its own syntax, syntax commands executed from other windows
|
||||
on the same buffer (including :syntax clear) have no effect. Conversely,
|
||||
syntax commands executed from that window do not effect other windows on the
|
||||
syntax commands executed from that window do not affect other windows on the
|
||||
same buffer.
|
||||
|
||||
A window with its own syntax reverts to normal behavior when another buffer
|
||||
|
||||
@@ -233,10 +233,12 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
'fex' options.txt /*'fex'*
|
||||
'ff' options.txt /*'ff'*
|
||||
'ffs' options.txt /*'ffs'*
|
||||
'fic' options.txt /*'fic'*
|
||||
'fileencoding' options.txt /*'fileencoding'*
|
||||
'fileencodings' options.txt /*'fileencodings'*
|
||||
'fileformat' options.txt /*'fileformat'*
|
||||
'fileformats' options.txt /*'fileformats'*
|
||||
'fileignorecase' options.txt /*'fileignorecase'*
|
||||
'filetype' options.txt /*'filetype'*
|
||||
'fillchars' options.txt /*'fillchars'*
|
||||
'fk' options.txt /*'fk'*
|
||||
@@ -523,6 +525,8 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
'noexpandtab' options.txt /*'noexpandtab'*
|
||||
'noexrc' options.txt /*'noexrc'*
|
||||
'nofen' options.txt /*'nofen'*
|
||||
'nofic' options.txt /*'nofic'*
|
||||
'nofileignorecase' options.txt /*'nofileignorecase'*
|
||||
'nofk' options.txt /*'nofk'*
|
||||
'nofkmap' options.txt /*'nofkmap'*
|
||||
'nofoldenable' options.txt /*'nofoldenable'*
|
||||
@@ -653,6 +657,8 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
'nottybuiltin' options.txt /*'nottybuiltin'*
|
||||
'nottyfast' options.txt /*'nottyfast'*
|
||||
'notx' options.txt /*'notx'*
|
||||
'noudf' options.txt /*'noudf'*
|
||||
'noundofile' options.txt /*'noundofile'*
|
||||
'novb' options.txt /*'novb'*
|
||||
'novice' vi_diff.txt /*'novice'*
|
||||
'novisualbell' options.txt /*'novisualbell'*
|
||||
@@ -732,9 +738,11 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
'quote motion.txt /*'quote*
|
||||
'quoteescape' options.txt /*'quoteescape'*
|
||||
'rdt' options.txt /*'rdt'*
|
||||
're' options.txt /*'re'*
|
||||
'readonly' options.txt /*'readonly'*
|
||||
'redraw' vi_diff.txt /*'redraw'*
|
||||
'redrawtime' options.txt /*'redrawtime'*
|
||||
'regexpengine' options.txt /*'regexpengine'*
|
||||
'relativenumber' options.txt /*'relativenumber'*
|
||||
'remap' options.txt /*'remap'*
|
||||
'report' options.txt /*'report'*
|
||||
@@ -964,6 +972,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
't_te' term.txt /*'t_te'*
|
||||
't_ti' term.txt /*'t_ti'*
|
||||
't_ts' term.txt /*'t_ts'*
|
||||
't_u7' term.txt /*'t_u7'*
|
||||
't_ue' term.txt /*'t_ue'*
|
||||
't_us' term.txt /*'t_us'*
|
||||
't_ut' term.txt /*'t_ut'*
|
||||
@@ -1384,6 +1393,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
/\ pattern.txt /*\/\\*
|
||||
/\$ pattern.txt /*\/\\$*
|
||||
/\%# pattern.txt /*\/\\%#*
|
||||
/\%#= pattern.txt /*\/\\%#=*
|
||||
/\%$ pattern.txt /*\/\\%$*
|
||||
/\%'m pattern.txt /*\/\\%'m*
|
||||
/\%( pattern.txt /*\/\\%(*
|
||||
@@ -1829,6 +1839,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
:RmVimball pi_vimball.txt /*:RmVimball*
|
||||
:Sexplore pi_netrw.txt /*:Sexplore*
|
||||
:TOhtml syntax.txt /*:TOhtml*
|
||||
:TarDiff pi_tar.txt /*:TarDiff*
|
||||
:Texplore pi_netrw.txt /*:Texplore*
|
||||
:UseVimball pi_vimball.txt /*:UseVimball*
|
||||
:Vexplore pi_netrw.txt /*:Vexplore*
|
||||
@@ -2584,7 +2595,9 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
|
||||
:pwd editing.txt /*:pwd*
|
||||
:py if_pyth.txt /*:py*
|
||||
:py3 if_pyth.txt /*:py3*
|
||||
:py3do if_pyth.txt /*:py3do*
|
||||
:py3file if_pyth.txt /*:py3file*
|
||||
:pydo if_pyth.txt /*:pydo*
|
||||
:pyf if_pyth.txt /*:pyf*
|
||||
:pyfile if_pyth.txt /*:pyfile*
|
||||
:python if_pyth.txt /*:python*
|
||||
@@ -4250,8 +4263,24 @@ E858 eval.txt /*E858*
|
||||
E859 eval.txt /*E859*
|
||||
E86 windows.txt /*E86*
|
||||
E860 eval.txt /*E860*
|
||||
E861 eval.txt /*E861*
|
||||
E862 eval.txt /*E862*
|
||||
E863 if_pyth.txt /*E863*
|
||||
E864 pattern.txt /*E864*
|
||||
E865 pattern.txt /*E865*
|
||||
E866 pattern.txt /*E866*
|
||||
E867 pattern.txt /*E867*
|
||||
E868 pattern.txt /*E868*
|
||||
E869 pattern.txt /*E869*
|
||||
E87 windows.txt /*E87*
|
||||
E870 pattern.txt /*E870*
|
||||
E871 pattern.txt /*E871*
|
||||
E872 pattern.txt /*E872*
|
||||
E873 pattern.txt /*E873*
|
||||
E874 pattern.txt /*E874*
|
||||
E875 pattern.txt /*E875*
|
||||
E876 pattern.txt /*E876*
|
||||
E877 pattern.txt /*E877*
|
||||
E878 pattern.txt /*E878*
|
||||
E88 windows.txt /*E88*
|
||||
E89 message.txt /*E89*
|
||||
E90 message.txt /*E90*
|
||||
@@ -4478,6 +4507,8 @@ TabLeave autocmd.txt /*TabLeave*
|
||||
Tcl if_tcl.txt /*Tcl*
|
||||
TermChanged autocmd.txt /*TermChanged*
|
||||
TermResponse autocmd.txt /*TermResponse*
|
||||
TextChanged autocmd.txt /*TextChanged*
|
||||
TextChangedI autocmd.txt /*TextChangedI*
|
||||
Transact-SQL ft_sql.txt /*Transact-SQL*
|
||||
U undo.txt /*U*
|
||||
UTF-8 mbyte.txt /*UTF-8*
|
||||
@@ -4768,7 +4799,8 @@ aw motion.txt /*aw*
|
||||
a{ motion.txt /*a{*
|
||||
a} motion.txt /*a}*
|
||||
b motion.txt /*b*
|
||||
b:changedtick-variable eval.txt /*b:changedtick-variable*
|
||||
b: eval.txt /*b:*
|
||||
b:changedtick eval.txt /*b:changedtick*
|
||||
b:changelog_name filetype.txt /*b:changelog_name*
|
||||
b:current_syntax-variable syntax.txt /*b:current_syntax-variable*
|
||||
b:netrw_lastfile pi_netrw.txt /*b:netrw_lastfile*
|
||||
@@ -5032,6 +5064,7 @@ clipboard-exclude options.txt /*clipboard-exclude*
|
||||
clipboard-html options.txt /*clipboard-html*
|
||||
clipboard-unnamed options.txt /*clipboard-unnamed*
|
||||
clipboard-unnamedplus options.txt /*clipboard-unnamedplus*
|
||||
clojure-indent indent.txt /*clojure-indent*
|
||||
cmdarg-variable eval.txt /*cmdarg-variable*
|
||||
cmdbang-variable eval.txt /*cmdbang-variable*
|
||||
cmdline-arguments vi_diff.txt /*cmdline-arguments*
|
||||
@@ -5180,6 +5213,7 @@ cpo-w options.txt /*cpo-w*
|
||||
cpo-x options.txt /*cpo-x*
|
||||
cpo-y options.txt /*cpo-y*
|
||||
cpo-{ options.txt /*cpo-{*
|
||||
cpp.vim syntax.txt /*cpp.vim*
|
||||
crash-recovery recover.txt /*crash-recovery*
|
||||
creating-menus gui.txt /*creating-menus*
|
||||
credits intro.txt /*credits*
|
||||
@@ -5653,8 +5687,10 @@ ft-ch-syntax syntax.txt /*ft-ch-syntax*
|
||||
ft-changelog-plugin filetype.txt /*ft-changelog-plugin*
|
||||
ft-changelog-syntax syntax.txt /*ft-changelog-syntax*
|
||||
ft-chill-syntax syntax.txt /*ft-chill-syntax*
|
||||
ft-clojure-indent indent.txt /*ft-clojure-indent*
|
||||
ft-cobol-syntax syntax.txt /*ft-cobol-syntax*
|
||||
ft-coldfusion-syntax syntax.txt /*ft-coldfusion-syntax*
|
||||
ft-cpp-syntax syntax.txt /*ft-cpp-syntax*
|
||||
ft-csh-syntax syntax.txt /*ft-csh-syntax*
|
||||
ft-css-omni insert.txt /*ft-css-omni*
|
||||
ft-cweb-syntax syntax.txt /*ft-cweb-syntax*
|
||||
@@ -5728,6 +5764,7 @@ ft-quake-syntax syntax.txt /*ft-quake-syntax*
|
||||
ft-r-indent indent.txt /*ft-r-indent*
|
||||
ft-readline-syntax syntax.txt /*ft-readline-syntax*
|
||||
ft-rexx-syntax syntax.txt /*ft-rexx-syntax*
|
||||
ft-rst-syntax syntax.txt /*ft-rst-syntax*
|
||||
ft-ruby-omni insert.txt /*ft-ruby-omni*
|
||||
ft-ruby-syntax syntax.txt /*ft-ruby-syntax*
|
||||
ft-scheme-syntax syntax.txt /*ft-scheme-syntax*
|
||||
@@ -5791,6 +5828,7 @@ g, motion.txt /*g,*
|
||||
g- undo.txt /*g-*
|
||||
g0 motion.txt /*g0*
|
||||
g8 various.txt /*g8*
|
||||
g: eval.txt /*g:*
|
||||
g:NetrwTopLvlMenu pi_netrw.txt /*g:NetrwTopLvlMenu*
|
||||
g:Netrw_corehandler pi_netrw.txt /*g:Netrw_corehandler*
|
||||
g:Netrw_funcref pi_netrw.txt /*g:Netrw_funcref*
|
||||
@@ -5816,6 +5854,12 @@ g:ada_space_errors ft_ada.txt /*g:ada_space_errors*
|
||||
g:ada_standard_types ft_ada.txt /*g:ada_standard_types*
|
||||
g:ada_with_gnat_project_files ft_ada.txt /*g:ada_with_gnat_project_files*
|
||||
g:ada_withuse_ordinary ft_ada.txt /*g:ada_withuse_ordinary*
|
||||
g:clojure_align_multiline_strings indent.txt /*g:clojure_align_multiline_strings*
|
||||
g:clojure_fuzzy_indent indent.txt /*g:clojure_fuzzy_indent*
|
||||
g:clojure_fuzzy_indent_blacklist indent.txt /*g:clojure_fuzzy_indent_blacklist*
|
||||
g:clojure_fuzzy_indent_patterns indent.txt /*g:clojure_fuzzy_indent_patterns*
|
||||
g:clojure_maxlines indent.txt /*g:clojure_maxlines*
|
||||
g:clojure_special_indent_words indent.txt /*g:clojure_special_indent_words*
|
||||
g:colors_name options.txt /*g:colors_name*
|
||||
g:decada ft_ada.txt /*g:decada*
|
||||
g:decada.Error_Format ft_ada.txt /*g:decada.Error_Format*
|
||||
@@ -5860,6 +5904,7 @@ g:html_whole_filler syntax.txt /*g:html_whole_filler*
|
||||
g:netrw_alto pi_netrw.txt /*g:netrw_alto*
|
||||
g:netrw_altv pi_netrw.txt /*g:netrw_altv*
|
||||
g:netrw_banner pi_netrw.txt /*g:netrw_banner*
|
||||
g:netrw_bannerbackslash pi_netrw.txt /*g:netrw_bannerbackslash*
|
||||
g:netrw_browse_split pi_netrw.txt /*g:netrw_browse_split*
|
||||
g:netrw_browsex_viewer pi_netrw.txt /*g:netrw_browsex_viewer*
|
||||
g:netrw_bufsettings pi_netrw.txt /*g:netrw_bufsettings*
|
||||
@@ -5872,6 +5917,7 @@ g:netrw_cygwin pi_netrw.txt /*g:netrw_cygwin*
|
||||
g:netrw_dav_cmd pi_netrw.txt /*g:netrw_dav_cmd*
|
||||
g:netrw_decompress pi_netrw.txt /*g:netrw_decompress*
|
||||
g:netrw_dirhistmax pi_netrw.txt /*g:netrw_dirhistmax*
|
||||
g:netrw_dynamic_maxfilenamelen pi_netrw.txt /*g:netrw_dynamic_maxfilenamelen*
|
||||
g:netrw_errorlvl pi_netrw.txt /*g:netrw_errorlvl*
|
||||
g:netrw_fastbrowse pi_netrw.txt /*g:netrw_fastbrowse*
|
||||
g:netrw_fetch_cmd pi_netrw.txt /*g:netrw_fetch_cmd*
|
||||
@@ -5947,6 +5993,8 @@ g:tar_readoptions pi_tar.txt /*g:tar_readoptions*
|
||||
g:tar_secure pi_tar.txt /*g:tar_secure*
|
||||
g:tar_writeoptions pi_tar.txt /*g:tar_writeoptions*
|
||||
g:tex_conceal syntax.txt /*g:tex_conceal*
|
||||
g:tex_fast syntax.txt /*g:tex_fast*
|
||||
g:tex_flavor filetype.txt /*g:tex_flavor*
|
||||
g:tex_isk syntax.txt /*g:tex_isk*
|
||||
g:var eval.txt /*g:var*
|
||||
g:vimball_home pi_vimball.txt /*g:vimball_home*
|
||||
@@ -6148,6 +6196,7 @@ gui_w16.txt gui_w16.txt /*gui_w16.txt*
|
||||
gui_w32.txt gui_w32.txt /*gui_w32.txt*
|
||||
gui_x11.txt gui_x11.txt /*gui_x11.txt*
|
||||
guifontwide_gtk2 options.txt /*guifontwide_gtk2*
|
||||
guifontwide_win_mbyte options.txt /*guifontwide_win_mbyte*
|
||||
guioptions_a options.txt /*guioptions_a*
|
||||
guu change.txt /*guu*
|
||||
gv visual.txt /*gv*
|
||||
@@ -6549,6 +6598,7 @@ keypad-point intro.txt /*keypad-point*
|
||||
keys() eval.txt /*keys()*
|
||||
known-bugs todo.txt /*known-bugs*
|
||||
l motion.txt /*l*
|
||||
l: eval.txt /*l:*
|
||||
l:var eval.txt /*l:var*
|
||||
lCursor mbyte.txt /*lCursor*
|
||||
lace.vim syntax.txt /*lace.vim*
|
||||
@@ -6683,6 +6733,7 @@ mapmode-s map.txt /*mapmode-s*
|
||||
mapmode-v map.txt /*mapmode-v*
|
||||
mapmode-x map.txt /*mapmode-x*
|
||||
mapping map.txt /*mapping*
|
||||
mapping-functions usr_41.txt /*mapping-functions*
|
||||
mark motion.txt /*mark*
|
||||
mark-functions usr_41.txt /*mark-functions*
|
||||
mark-motions motion.txt /*mark-motions*
|
||||
@@ -6794,6 +6845,7 @@ mzscheme-buffer if_mzsch.txt /*mzscheme-buffer*
|
||||
mzscheme-commands if_mzsch.txt /*mzscheme-commands*
|
||||
mzscheme-dynamic if_mzsch.txt /*mzscheme-dynamic*
|
||||
mzscheme-examples if_mzsch.txt /*mzscheme-examples*
|
||||
mzscheme-funcref if_mzsch.txt /*mzscheme-funcref*
|
||||
mzscheme-mzeval if_mzsch.txt /*mzscheme-mzeval*
|
||||
mzscheme-sandbox if_mzsch.txt /*mzscheme-sandbox*
|
||||
mzscheme-threads if_mzsch.txt /*mzscheme-threads*
|
||||
@@ -6838,8 +6890,10 @@ netrw-O pi_netrw.txt /*netrw-O*
|
||||
netrw-P pi_netrw.txt /*netrw-P*
|
||||
netrw-R pi_netrw.txt /*netrw-R*
|
||||
netrw-S pi_netrw.txt /*netrw-S*
|
||||
netrw-T pi_netrw.txt /*netrw-T*
|
||||
netrw-Tb pi_netrw.txt /*netrw-Tb*
|
||||
netrw-Th pi_netrw.txt /*netrw-Th*
|
||||
netrw-U pi_netrw.txt /*netrw-U*
|
||||
netrw-X pi_netrw.txt /*netrw-X*
|
||||
netrw-a pi_netrw.txt /*netrw-a*
|
||||
netrw-activate pi_netrw.txt /*netrw-activate*
|
||||
netrw-bookmark pi_netrw.txt /*netrw-bookmark*
|
||||
@@ -6906,6 +6960,7 @@ netrw-listbookmark pi_netrw.txt /*netrw-listbookmark*
|
||||
netrw-listhack pi_netrw.txt /*netrw-listhack*
|
||||
netrw-login pi_netrw.txt /*netrw-login*
|
||||
netrw-mB pi_netrw.txt /*netrw-mB*
|
||||
netrw-mF pi_netrw.txt /*netrw-mF*
|
||||
netrw-mT pi_netrw.txt /*netrw-mT*
|
||||
netrw-mb pi_netrw.txt /*netrw-mb*
|
||||
netrw-mc pi_netrw.txt /*netrw-mc*
|
||||
@@ -6960,6 +7015,7 @@ netrw-prvwin pi_netrw.txt /*netrw-prvwin*
|
||||
netrw-pscp pi_netrw.txt /*netrw-pscp*
|
||||
netrw-psftp pi_netrw.txt /*netrw-psftp*
|
||||
netrw-putty pi_netrw.txt /*netrw-putty*
|
||||
netrw-qF pi_netrw.txt /*netrw-qF*
|
||||
netrw-qb pi_netrw.txt /*netrw-qb*
|
||||
netrw-qf pi_netrw.txt /*netrw-qf*
|
||||
netrw-quickcom pi_netrw.txt /*netrw-quickcom*
|
||||
@@ -7289,7 +7345,12 @@ put-Visual-mode change.txt /*put-Visual-mode*
|
||||
py3eval() eval.txt /*py3eval()*
|
||||
pyeval() eval.txt /*pyeval()*
|
||||
python if_pyth.txt /*python*
|
||||
python-.locked if_pyth.txt /*python-.locked*
|
||||
python-Dictionary if_pyth.txt /*python-Dictionary*
|
||||
python-Function if_pyth.txt /*python-Function*
|
||||
python-List if_pyth.txt /*python-List*
|
||||
python-bindeval if_pyth.txt /*python-bindeval*
|
||||
python-bindeval-objects if_pyth.txt /*python-bindeval-objects*
|
||||
python-buffer if_pyth.txt /*python-buffer*
|
||||
python-buffers if_pyth.txt /*python-buffers*
|
||||
python-command if_pyth.txt /*python-command*
|
||||
@@ -7300,10 +7361,15 @@ python-error if_pyth.txt /*python-error*
|
||||
python-eval if_pyth.txt /*python-eval*
|
||||
python-examples if_pyth.txt /*python-examples*
|
||||
python-input if_pyth.txt /*python-input*
|
||||
python-options if_pyth.txt /*python-options*
|
||||
python-output if_pyth.txt /*python-output*
|
||||
python-pyeval if_pyth.txt /*python-pyeval*
|
||||
python-range if_pyth.txt /*python-range*
|
||||
python-tabpage if_pyth.txt /*python-tabpage*
|
||||
python-tabpages if_pyth.txt /*python-tabpages*
|
||||
python-vars if_pyth.txt /*python-vars*
|
||||
python-vim if_pyth.txt /*python-vim*
|
||||
python-vvars if_pyth.txt /*python-vvars*
|
||||
python-window if_pyth.txt /*python-window*
|
||||
python-windows if_pyth.txt /*python-windows*
|
||||
python.vim syntax.txt /*python.vim*
|
||||
@@ -7426,6 +7492,7 @@ rileft.txt rileft.txt /*rileft.txt*
|
||||
riscos os_risc.txt /*riscos*
|
||||
rot13 change.txt /*rot13*
|
||||
round() eval.txt /*round()*
|
||||
rst.vim syntax.txt /*rst.vim*
|
||||
rsync pi_netrw.txt /*rsync*
|
||||
ruby if_ruby.txt /*ruby*
|
||||
ruby-buffer if_ruby.txt /*ruby-buffer*
|
||||
@@ -7477,6 +7544,8 @@ save-file editing.txt /*save-file*
|
||||
save-settings starting.txt /*save-settings*
|
||||
scheme.vim syntax.txt /*scheme.vim*
|
||||
scp pi_netrw.txt /*scp*
|
||||
screencol() eval.txt /*screencol()*
|
||||
screenrow() eval.txt /*screenrow()*
|
||||
script usr_41.txt /*script*
|
||||
script-here if_perl.txt /*script-here*
|
||||
script-local map.txt /*script-local*
|
||||
@@ -7545,11 +7614,13 @@ sgr-mouse options.txt /*sgr-mouse*
|
||||
sh-awk syntax.txt /*sh-awk*
|
||||
sh-embed syntax.txt /*sh-embed*
|
||||
sh.vim syntax.txt /*sh.vim*
|
||||
sha256() eval.txt /*sha256()*
|
||||
shell-window tips.txt /*shell-window*
|
||||
shell_error-variable eval.txt /*shell_error-variable*
|
||||
shellescape() eval.txt /*shellescape()*
|
||||
shift intro.txt /*shift*
|
||||
shift-left-right change.txt /*shift-left-right*
|
||||
shiftwidth() eval.txt /*shiftwidth()*
|
||||
short-name-changed version4.txt /*short-name-changed*
|
||||
showing-menus gui.txt /*showing-menus*
|
||||
sign-commands sign.txt /*sign-commands*
|
||||
@@ -7811,6 +7882,7 @@ system-functions usr_41.txt /*system-functions*
|
||||
system-vimrc starting.txt /*system-vimrc*
|
||||
s~ change.txt /*s~*
|
||||
t motion.txt /*t*
|
||||
t: eval.txt /*t:*
|
||||
t:var eval.txt /*t:var*
|
||||
t_#2 term.txt /*t_#2*
|
||||
t_#4 term.txt /*t_#4*
|
||||
@@ -7955,6 +8027,7 @@ t_ti term.txt /*t_ti*
|
||||
t_tp version4.txt /*t_tp*
|
||||
t_ts term.txt /*t_ts*
|
||||
t_ts_old version4.txt /*t_ts_old*
|
||||
t_u7 term.txt /*t_u7*
|
||||
t_ue term.txt /*t_ue*
|
||||
t_undo version4.txt /*t_undo*
|
||||
t_us term.txt /*t_us*
|
||||
@@ -8125,6 +8198,7 @@ try-nested eval.txt /*try-nested*
|
||||
try-nesting eval.txt /*try-nesting*
|
||||
tutor usr_01.txt /*tutor*
|
||||
twice if_cscop.txt /*twice*
|
||||
two-engines pattern.txt /*two-engines*
|
||||
type() eval.txt /*type()*
|
||||
type-mistakes tips.txt /*type-mistakes*
|
||||
typecorr-settings usr_41.txt /*typecorr-settings*
|
||||
@@ -8205,6 +8279,7 @@ utf-8-in-xwindows mbyte.txt /*utf-8-in-xwindows*
|
||||
utf-8-typing mbyte.txt /*utf-8-typing*
|
||||
utf8 mbyte.txt /*utf8*
|
||||
v visual.txt /*v*
|
||||
v: eval.txt /*v:*
|
||||
v:beval_bufnr eval.txt /*v:beval_bufnr*
|
||||
v:beval_col eval.txt /*v:beval_col*
|
||||
v:beval_lnum eval.txt /*v:beval_lnum*
|
||||
@@ -8498,6 +8573,7 @@ vt100-function-keys term.txt /*vt100-function-keys*
|
||||
w motion.txt /*w*
|
||||
w32-clientserver remote.txt /*w32-clientserver*
|
||||
w32-xpm-support gui_w32.txt /*w32-xpm-support*
|
||||
w: eval.txt /*w:*
|
||||
w:current_syntax syntax.txt /*w:current_syntax*
|
||||
w:quickfix_title quickfix.txt /*w:quickfix_title*
|
||||
w:var eval.txt /*w:var*
|
||||
@@ -8506,6 +8582,7 @@ white-space pattern.txt /*white-space*
|
||||
whitespace pattern.txt /*whitespace*
|
||||
wildcard editing.txt /*wildcard*
|
||||
wildcards editing.txt /*wildcards*
|
||||
wildmenumode() eval.txt /*wildmenumode()*
|
||||
win16-!start gui_w16.txt /*win16-!start*
|
||||
win16-clipboard gui_w16.txt /*win16-clipboard*
|
||||
win16-colors gui_w16.txt /*win16-colors*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*term.txt* For Vim version 7.3. Last change: 2011 Feb 16
|
||||
*term.txt* For Vim version 7.3. Last change: 2013 Mar 13
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -294,6 +294,8 @@ Added by Vim (there are no standard codes for these):
|
||||
|termcap-cursor-shape|
|
||||
t_RV request terminal version string (for xterm) *t_RV* *'t_RV'*
|
||||
|xterm-8bit| |v:termresponse| |'ttymouse'| |xterm-codes|
|
||||
t_u7 request cursor position (for xterm) *t_u7* *'t_u7'*
|
||||
see |'ambiwidth'|
|
||||
|
||||
KEY CODES
|
||||
Note: Use the <> form if possible
|
||||
@@ -326,7 +328,7 @@ Note: Use the <> form if possible
|
||||
t_k8 <F8> function key 8 *<F8>* *t_k8* *'t_k8'*
|
||||
t_k9 <F9> function key 9 *<F9>* *t_k9* *'t_k9'*
|
||||
t_k; <F10> function key 10 *<F10>* *t_k;* *'t_k;'*
|
||||
t_F1 <F11> function key 11 *<F11>* *t_F1* *'t_F1'*
|
||||
t_F1 <F11> function key 11 *<F11>* *t_F1* *'t_F1'*
|
||||
t_F2 <F12> function key 12 *<F12>* *t_F2* *'t_F2'*
|
||||
t_F3 <F13> function key 13 *<F13>* *t_F3* *'t_F3'*
|
||||
t_F4 <F14> function key 14 *<F14>* *t_F4* *'t_F4'*
|
||||
@@ -356,9 +358,9 @@ Note: Use the <> form if possible
|
||||
t_kI <Insert> insert key *t_kI* *'t_kI'*
|
||||
t_kD <Del> delete key *t_kD* *'t_kD'*
|
||||
t_kb <BS> backspace key *t_kb* *'t_kb'*
|
||||
t_kB <S-Tab> back-tab (shift-tab) *<S-Tab>* *t_kB* *'t_kB'*
|
||||
t_kB <S-Tab> back-tab (shift-tab) *<S-Tab>* *t_kB* *'t_kB'*
|
||||
t_kh <Home> home key *t_kh* *'t_kh'*
|
||||
t_#2 <S-Home> shifted home key *<S-Home>* *t_#2* *'t_#2'*
|
||||
t_#2 <S-Home> shifted home key *<S-Home>* *t_#2* *'t_#2'*
|
||||
<xHome> alternate home key *<xHome>*
|
||||
t_@7 <End> end key *t_@7* *'t_@7'*
|
||||
t_*7 <S-End> shifted end key *<S-End>* *t_star7* *'t_star7'*
|
||||
@@ -371,8 +373,8 @@ Note: Use the <> form if possible
|
||||
t_K5 <kPageDown> keypad page-down key *t_K5* *'t_K5'*
|
||||
t_K6 <kPlus> keypad plus key *<kPlus>* *t_K6* *'t_K6'*
|
||||
t_K7 <kMinus> keypad minus key *<kMinus>* *t_K7* *'t_K7'*
|
||||
t_K8 <kDivide> keypad divide *<kDivide>* *t_K8* *'t_K8'*
|
||||
t_K9 <kMultiply> keypad multiply *<kMultiply>* *t_K9* *'t_K9'*
|
||||
t_K8 <kDivide> keypad divide *<kDivide>* *t_K8* *'t_K8'*
|
||||
t_K9 <kMultiply> keypad multiply *<kMultiply>* *t_K9* *'t_K9'*
|
||||
t_KA <kEnter> keypad enter key *<kEnter>* *t_KA* *'t_KA'*
|
||||
t_KB <kPoint> keypad decimal point *<kPoint>* *t_KB* *'t_KB'*
|
||||
t_KC <k0> keypad 0 *<k0>* *t_KC* *'t_KC'*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*todo.txt* For Vim version 7.3. Last change: 2012 Aug 15
|
||||
*todo.txt* For Vim version 7.3. Last change: 2013 Jun 01
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -34,47 +34,325 @@ not be repeated below, unless there is extra information.
|
||||
*known-bugs*
|
||||
-------------------- Known bugs and current work -----------------------
|
||||
|
||||
--- Python interface
|
||||
|
||||
Patch from ZyX, May 30: Fix some possible memory problems
|
||||
|
||||
Check: docs for .valid patch by ZyX, May 30
|
||||
Correction by Roland Eggner, May 31.
|
||||
|
||||
Tests are disabled because they fail.
|
||||
|
||||
Configure doesn't find Python 3 on Ubuntu 13.04. (Ken Takata, Apr 13)
|
||||
|
||||
Python SystemExit exception is not handled properly. Patch to catch the
|
||||
exception and give an error. (Yasuhiro Matsumoto)
|
||||
Does not work, tests fail.
|
||||
|
||||
Patch to complete after :py3. (Taro Muraoka, 2013 May 31)
|
||||
|
||||
":python os.chdir('/tmp')" makes short buffer names invalid. (Xavier de Gaye)
|
||||
Patch to make os.chdir() handle side effects. (Xavier de Gaye, 2013 May 17)
|
||||
Update May 19, also for os.fchdir().
|
||||
Adds a $VIMRUNTIME/python directory.
|
||||
ZyX: OK to add python and python3 directory.
|
||||
|
||||
Mac: OS/X 10.4 with Python 2.5 installed: configure finds an extra argument
|
||||
that breaks the build. (Brian Victor, 2008 Sep 1)
|
||||
|
||||
Patch to access screen under Python. (Marko Mahni, 2010 Jul 18)
|
||||
|
||||
Python: ":py raw_input('prompt')" doesn't work. (Manu Hack)
|
||||
|
||||
Win32: The Python interface only works with one version of Python, selected at
|
||||
compile time. Can this be made to work with version 2.1 and 2.2 dynamically?
|
||||
|
||||
Python: Be able to define a Python function that can be called directly from
|
||||
Vim script. Requires converting the arguments and return value, like with
|
||||
vim.bindeval().
|
||||
|
||||
--- runtime files
|
||||
|
||||
Syntax file for protocol buffers. (Feng Xiao, 2013 May 9)
|
||||
Has an ugly copyright notice.
|
||||
Add statement that it does not conflict with Vim license.
|
||||
|
||||
Patch for JavaScript syntax. (Kevin Locke, 2013 May 9)
|
||||
Claudio didn't respond yet.
|
||||
|
||||
--- Fast regexp engine
|
||||
|
||||
Error in HTML highlighting. (Hiroshi Shirosaki)
|
||||
|
||||
Tests for \{-} : Requires trying to start at every position?
|
||||
If so, rename nfa_has_backref to nfa_dup_states and re-use it for this.
|
||||
|
||||
Allow "^*" as a literal "*".
|
||||
|
||||
Need more testing for \1 back references.
|
||||
|
||||
Profiling:
|
||||
./vim -s ~/vim/test/loop.vim
|
||||
./vim -s ~/vim/test/xml.vim (Fix: Uses the old engine, see
|
||||
bt_regexp_debug.log)
|
||||
Need \@<=
|
||||
NFA engine could not handle "[<]\@<=[^ /!?<>"']\+"
|
||||
NFA engine could not handle "<!--\_.\{-}-->"
|
||||
|
||||
setting cpo_lit and cpo_bsl can be slow. Make them global.
|
||||
|
||||
Get example files for many languages. Compare syntax highlighting with old and
|
||||
new regexp, find regexp constructs where NFA does not work correctly.
|
||||
source ~/vim/regexp/runold.vim to update the "old" files.
|
||||
source ~/vim/regexp/runnew.vim to update the "new" files
|
||||
source ~/vim/regexp/diff.vim to find differences
|
||||
|
||||
More test files from the src/pkg/regexp/testdata directory in the Go repo.
|
||||
|
||||
It's very slow compared to the old engine...
|
||||
Performance tests:
|
||||
- ~/vim/text/FeiqCfg.xml (file from Netjune)
|
||||
- ~/vim/text/edl.svg (also XML)
|
||||
- glts has five tests. (May 25)
|
||||
- ~/vim/test/veryslow.js display last line (file from Daniel Fetchinson)
|
||||
- ~/vim/test/slowsearch
|
||||
- ~/vim/test/rgb.vim
|
||||
- search for a.*e*exn in the vim executable. Go to last line to use
|
||||
'hlsearch'.
|
||||
- Slow combination of folding and PHP syntax highlighting. Script to
|
||||
reproduce it. Caused by "syntax sync fromstart" in combination with patch
|
||||
7.2.274. (Christian Brabandt, 2010 May 27) Generally, folding with
|
||||
'foldmethod' set to "syntax" is slow. Do profiling to find out why.
|
||||
- It does not use any of the optimizations, such as required start pattern.
|
||||
- When lists are empty in nfa_regmatch() and match is true, it keeps looping
|
||||
without doing anything.
|
||||
|
||||
Does not work (yet) with NFA:
|
||||
- \z() \z1 .. "\z9": Previously matched text in syn HL.
|
||||
- ~: previous substitute pattern. Requires recursive compilation?
|
||||
- \%u, \%x, \%o, \%d followed by a composing character
|
||||
- \%V Visual
|
||||
- \%[abc]
|
||||
- \%' mark
|
||||
- \@< match before zero-width
|
||||
- \@> match whole pattern
|
||||
|
||||
--- bug fixes
|
||||
|
||||
Patch to avoid wrong error message for 1.0[0]. (Yasuhiro Matsumoto, 2013 May
|
||||
1)
|
||||
|
||||
Patch for if_lua. (Luis Carvalho, 2012 Aug 26, update Aug 29, another Aug 30,
|
||||
then Sep 1, reminder Oct 14)
|
||||
|
||||
Patch for if_perl. (Ike Devolder, May 27)
|
||||
|
||||
Patch to check if 'foldexpr' sets did_emsg. (Christian Brabandt, 2013 Mar 20)
|
||||
|
||||
Patch for 'backupcopy' default behavior for symlinks on Windows. (David Pope,
|
||||
2012 Mar 21, update Mar 31)
|
||||
With fix for memory leak: Ken Takata, 2012 Aug 24
|
||||
Another update Sep 24.
|
||||
Also patch from Joerg Bornemann, 2013 Apr 30.
|
||||
|
||||
Undo problem: line not removed as expected when using setline() from Insert
|
||||
mode. (Israel Chauca, 2010 May 13, more in second msg)
|
||||
Break undo when CTRL-R = changes the text? Or save more lines?
|
||||
Patch by Christian Brabandt, 2012 Nov 16.
|
||||
|
||||
Do allow real tags above the !_TAG entries. Undo older patch. Issue 90.
|
||||
|
||||
Matches might be highlighted correctly. Inefficient patch by Christian
|
||||
Brabandt, 2013 Feb 26.
|
||||
|
||||
Patch to use bold/italic fonts when 'guifontewide' is set. (Ken Takata, 2013
|
||||
Mar 31)
|
||||
|
||||
Problem with winfixheight and resizing. (Yukihiro Nakadaira, 2011 Sep 17)
|
||||
Patch Sep 18.
|
||||
|
||||
Patch for IME problems. Remove hacking code for old IM. (Yukihiro Nakadaira,
|
||||
2012 Jul 20)
|
||||
|
||||
Patch to fix finding toolbar bitmaps. Issue 129.
|
||||
|
||||
Combining characters are not used when executing a register with :@w.
|
||||
(William Fugh, 2013 Apr 5, more info from Ben Fritz)
|
||||
Patch by Christian Brabandt, 2013 Apr 6. Second one.
|
||||
|
||||
MS-Windows ACL support doesn't work well. Patch from Ken Takata, 2012 Aug 29.
|
||||
Update Aug 31.
|
||||
Another patch for MingW, 2012 Dec 29.
|
||||
|
||||
Bug in completion menu. (Olivier Teuliere, 2013 Feb 15)
|
||||
Patch by Christian Brabandt, Feb 16.
|
||||
|
||||
Issue 134: pasting in visual selection in empty buffer.
|
||||
Patch by Christian Brabandt, 2013 May 22.
|
||||
|
||||
'cursorline' is drawn incorrectly in diff mode. Patch by Christian Brabandt,
|
||||
2012 Apr 2.
|
||||
|
||||
When someone does a silly thing such as setting rows and columns to 65535,
|
||||
handle the out-of-memory and set them to sane values? (jimmywang, 2013 May 17)
|
||||
|
||||
InsertEnter doesn't prevent the cursor from moving when it goes to another
|
||||
line.
|
||||
|
||||
":diffoff" does not restore options from before starting diff mode.
|
||||
Patch by Christian Brabandt, 2013 May 26.
|
||||
|
||||
--- slightly incompatible changes
|
||||
|
||||
Patch to load ~/.vim/vimrc when ~/.vimrc isn't found. (Lech Lorens, 2013 Apr
|
||||
13)
|
||||
|
||||
It's probably a good idea to make a negative value for 'sts' use the value of
|
||||
'sw'. Patch by So8res, Oct 3 2012
|
||||
|
||||
When a buffer-local mapping is used, but a global mapping starts with the same
|
||||
characters, Vim currently waits for the next typed character to find out if
|
||||
the global mapping matches. It is probably better to let the local mapping
|
||||
win and not wait. (discussion with Andy Wokula, 2013 Jan 30)
|
||||
Patch by Michael Henry, 2013 Jan 30, update Feb 15.
|
||||
|
||||
Patch to store absolute path for cscope. (Christian Brabandt, 2013 May 31)
|
||||
|
||||
---- Fixes to be included before 7.4 above, less important stuff below ----
|
||||
|
||||
Several syntax file match "^\s*" which may get underlined if that's in the
|
||||
highlight group. Add a "\zs" after it?
|
||||
|
||||
Go through more coverity reports.
|
||||
|
||||
Discussion about canonicalization of Hebrew. (Ron Aaron, 2011 April 10)
|
||||
|
||||
Checking runtime scripts: Thilo Six, 2012 Jun 6.
|
||||
|
||||
GTK: problem with 'L' in 'guioptions' changing the window width.
|
||||
(Aaron Cornelius, 2012 Feb 6)
|
||||
|
||||
Checking runtime scripts: Thilo Six, 2012 Jun 6.
|
||||
|
||||
Javascript file where indent gets stuck on: GalaxyMaster, 2012 May 3.
|
||||
|
||||
The CompleteDone autocommand needs some info passed to it:
|
||||
- The word that was selected (empty if abandoned complete)
|
||||
- Type of completion: tag, omnifunc, user func.
|
||||
|
||||
":gundo" command: global undo. Undoes changes spread over multiple files in
|
||||
the order they were made. Also ":gredo". Both with a count. Useful when
|
||||
tests fail after making changes and you forgot in which files.
|
||||
Using ":call foo#d.f()" doesn't autoload the "foo.vim" file.
|
||||
That is, calling a dictionary function on an autoloaded dict.
|
||||
Works OK for echo, just not for ":call" and ":call call()". (Ted, 2011 Mar
|
||||
17)
|
||||
Patch by Christian Brabandt, 2013 Mar 23.
|
||||
Not 100% sure this is the right solution.
|
||||
|
||||
Win32: When a directory name contains an exclamation mark, completion doesn't
|
||||
complete the contents of the directory. No escaping for the "!"? (Jan
|
||||
Stocker, 2012 Jan 5)
|
||||
|
||||
Patch to support expression argument to sort() instead of a function name.
|
||||
Yasuhiro Matsumoto, 2013 May 31.
|
||||
Or should we add a more general mechanism, like lambda functions?
|
||||
|
||||
Problem caused by patch 7.3.638: window->open does not update window
|
||||
correctly. Issue 91.
|
||||
|
||||
Patch to fix that 'cedit' is recognized after :normal. (Christian Brabandt,
|
||||
2013 Mar 19, later message)
|
||||
|
||||
Patch to view coverage of the tests. (Nazri Ramliy, 2013 Feb 15)
|
||||
|
||||
Patch to invert characters differently in GTK. (Yukihiro Nakadaira, 2013 May
|
||||
5)
|
||||
|
||||
Patch to add the bufferlist() function. (Yegappan Lakshmanan, 2013 May 5)
|
||||
May 17: with winlist() and tabpagelist().
|
||||
May 19: with local variables.
|
||||
May 28: with options
|
||||
|
||||
Patch to support 'u' in interactive substitute. (Christian Brabandt, 2012 Sep
|
||||
28) With tests: Oct 9.
|
||||
|
||||
Patch to allow setting w:quickfix_title via setqflist() and setloclist()
|
||||
functions. (Christian Brabandt, 2013 May 8, update May 21)
|
||||
Patch to add getlocstack() / setlocstack(). (Christian Brabandt, 2013 May 14)
|
||||
Second one. Update May 22.
|
||||
|
||||
Patch to make fold updates much faster. (Christian Brabandt, 2012 Dec)
|
||||
|
||||
Patch for IME handling, adds 'imactivatefunc' and 'imstatusfunc' option.
|
||||
(Yukihiro Nakadaira, 2012 Aug 16)
|
||||
Patch to improve IME handling. (Yasuhiro Matsumoto, 2012 Jul 18)
|
||||
|
||||
Issue 54: document behavior of -complete, also expands arg.
|
||||
|
||||
- Add regex for 'paragraphs' and 'sections': 'parare' and 'sectre'. Combine
|
||||
the two into a regex for searching. (Ned Konz)
|
||||
Patch by Christian Brabandt, 2013 Apr 20, unfinished.
|
||||
|
||||
Bug: findfile("any", "http://;") returns http://any. (Andrew Pimlott, 2013 May
|
||||
7) Not sure if that can be fixed, but when using "file://" it should be
|
||||
possible to check if the file exists.
|
||||
|
||||
v:register is not directly reset to " after a delete command that specifies a
|
||||
register. It is reset after the next command. (Steve Vermeulen, 2013 Mar 16)
|
||||
|
||||
'ff' is wrong for one-line file without EOL. (Issue 77)
|
||||
|
||||
Patch to set antialiasing style on Windows. (Ondrej Balaz, 2013 Mar 14)
|
||||
Needs a different check for CLEARTYPE_QUALITY.
|
||||
|
||||
Issue 72: 'autochdir' causes problems for :vimgrep.
|
||||
|
||||
In the ATTENTION message about an existing swap file, mention the name of the
|
||||
process that is running. It might actually be some other program, e.g. after
|
||||
a reboot.
|
||||
|
||||
MS-Windows: Crash opening very long file name starting with "\\".
|
||||
(Christian Brock, 2012 Jun 29)
|
||||
|
||||
patch to add "combine" flag to syntax commands. (so8res, 2012 Dec 6)
|
||||
|
||||
Syntax update problem in one buffer opened in two windows, bottom window is
|
||||
not correctly updated. (Paul Harris, 2012 Feb 27)
|
||||
|
||||
Patch to add assignments in cscope. (Uli Meis, Estabrooks, 2012 Sep 1)
|
||||
Alternate patch by Gary Johnson, Sep 4.
|
||||
|
||||
Patch to add getsid(). (Tyru, 2011 Oct 2) Do we want this? Update Oct 4.
|
||||
Or use expand('<sid>')?
|
||||
|
||||
Patch to improve IME handling. (Yasuhiro Matsumoto, 2012 Jul 18)
|
||||
Patch to make confirm() display colors. (Christian Brabandt, 2012 Nov 9)
|
||||
|
||||
Patch to add functions for signs. (Christian Brabandt, 2013 Jan 27)
|
||||
|
||||
Patch to use directX to draw text on Windows. Adds the 'renderoptions'
|
||||
option. (Taro Muraoka, 2013 Jan 25, update 2013 Apr 3, May 14)
|
||||
|
||||
Patch to add 'completeselect' option. Specifies how to select a candidate in
|
||||
insert completion. (Shougo, 2013 May 29)
|
||||
Update to add to existing 'completeopt'. 2013 May 30
|
||||
|
||||
Problem with refresh:always in completion. (Tyler Wade, 2013 Mar 17)
|
||||
|
||||
b:undo_ftplugin cannot call a script-local function. (Boris Danilov, 2013 Jan
|
||||
7)
|
||||
|
||||
Patch for :tabcloseleft, after closing a tab go to left tab. (William Bowers,
|
||||
2012 Aug 4)
|
||||
|
||||
Patch to improve equivalence classes in regexp patterns.
|
||||
(Christian Brabandt, 2013 Jan 16, update Jan 17)
|
||||
|
||||
Patch with suggestions for starting.txt. (Tony Mechelynck, 2012 Oct 24)
|
||||
But use Gnome instead of GTK?
|
||||
|
||||
Patch to make FocusGained and FocusLost work in modern terminals. (Hayaki
|
||||
Saito, 2013 Apr 24)
|
||||
|
||||
Should be possible to enable/disable matchparen per window or buffer.
|
||||
Add a check for b:no_match_paren in Highlight_matching_Pair() (Marcin
|
||||
Szamotulski, 2012 Nov 8)
|
||||
|
||||
Crash in autocmd that unloads buffers in a BufUnload event. (Andrew Pimlott,
|
||||
2012 Aug 11) Disallow :new when BufUnload is being handled?
|
||||
|
||||
@@ -87,18 +365,36 @@ MS-Windows resizing problems:
|
||||
|
||||
'iminsert' global value set when using ":setlocal iminsert"? (Wu, 2012 Jun 23)
|
||||
|
||||
Help for b:undo_indent'. (Thilo Six, 2012 May 28)
|
||||
Patch to append regexp to tag commands to make it possible to select one out
|
||||
of many matches. (Cody Cutler, 2013 Mar 28)
|
||||
|
||||
Help for 'b:undo_indent'. (Thilo Six, 2012 May 28)
|
||||
Also question if examples are correct.
|
||||
|
||||
It should be possible to make globpath() return a list instead of a string,
|
||||
like with glob(). (Greg Novack, 2012 Nov 2)
|
||||
|
||||
The input map for CTRL-O in mswin.vim causes problems after CTRL-X CTRL-O.
|
||||
Suggestion for another map. (Philip Mat, 2012 Jun 18)
|
||||
But use "gi" instead of "a". Or use CTRL-\ CTRL-O.
|
||||
|
||||
Patch to support user name completion on MS-Windows. (Yasuhiro Matsumoto, 2012
|
||||
Aug 16)
|
||||
|
||||
Have an option for spell checking to not mark any Chinese, Japanese or other
|
||||
double-width characters as error. Or perhaps all characters above 256.
|
||||
(Bill Sun) Helps a lot for mixed Asian and latin text.
|
||||
|
||||
When there are no command line arguments ":next" and ":argu" give E163, which
|
||||
is confusing. Should say "the argument list is empty".
|
||||
|
||||
URXVT:
|
||||
- will get stuck if byte sequence does not containe expected semicolon.
|
||||
- will get stuck if byte sequence does not contain the expected semicolon.
|
||||
- Use urxvt mouse support also in xterm. Explanations:
|
||||
http://www.midnight-commander.org/ticket/2662
|
||||
|
||||
MS-Windows: test 17 fails. Analysis by Michael Soyka, 2012 Nov 5.
|
||||
|
||||
Patch to add tests for if_xcmdsrv.c., Jul 8, need some more work. (Brian Burns)
|
||||
New tests Jul 13. Update Jul 17. Discussion Jul 18.
|
||||
|
||||
@@ -106,18 +402,12 @@ When running Vim in silent ex mode, an existing swapfile causes Vim to wait
|
||||
for a user action without a prompt. (Maarten Billemont, 2012 Feb 3)
|
||||
Do give the prompt? Quit with an error?
|
||||
|
||||
Patch for 'backupcopy' default behavior for symlinks on Windows. (David Pope,
|
||||
2012 Mar 21, update Mar 31)
|
||||
|
||||
Patch to list user digraphs. (Christian Brabandt, 2012 Apr 14)
|
||||
|
||||
Patch for input method status. (Hirohito Higashi, 2012 Apr 18)
|
||||
|
||||
Problem with winfixheight and resizing. (Yukihiro Nakadaira, 2011 Sep 17)
|
||||
Patch Sep 18.
|
||||
|
||||
Patch for IME problems. Remove hacking code for old IM. (Yukihiro Nakadaira,
|
||||
2012 Jul 20)
|
||||
Patch to use .png icons for the toolbar on MS-Windows. (Martin Gieseking, 2013
|
||||
Apr 18)
|
||||
|
||||
Patch for has('unnamedplus') docs. (Tony Mechelynck, 2011 Sep 27)
|
||||
And one for gui_x11.txt.
|
||||
@@ -127,9 +417,7 @@ And one for gui_x11.txt.
|
||||
Version for latest MacVim: Tobia Conforto, 2009 Nov 23
|
||||
More recent version: https://retracile.net/wiki/VimBreakIndent
|
||||
Posted to vim-dev by Taylor Hedberg, 2011 Nov 25
|
||||
|
||||
Problem with starting Visual block mode with :norm when 'virtualedit' is set.
|
||||
(David glts, 2012 Jun 5)
|
||||
Update by Taylor Hedberg, 2013 May 30.
|
||||
|
||||
":cd" doesn't work when current directory path contains "**".
|
||||
finddir() has the same problem. (Yukihiro Nakadaira, 2012 Jan 10)
|
||||
@@ -139,10 +427,9 @@ Problem with l: dictionary being locked in a function. (ZyX, 2011 Jul 21)
|
||||
|
||||
Should use has("browsefilter") in ftplugins. Requires patch 7.3.593.
|
||||
|
||||
Issue 48: foldopen error can't be caught by try/catch
|
||||
Update for vim2html.pl. (Tyru, 2013 Feb 22)
|
||||
|
||||
"dg_" deletes including the last character, "d:normal! g_" doesn't.
|
||||
(Nomen Nescio, 2012 Jun 27)
|
||||
Issue 48: foldopen error can't be caught by try/catch
|
||||
|
||||
Patch to sort functions starting with '<' after others. Omit dict functions,
|
||||
they can't be called. (Yasuhiro Matsumoto, 2011 Oct 11)
|
||||
@@ -155,19 +442,11 @@ Nov 20)
|
||||
Patch to improve GUI find/replace dialog. (Christian Brabandt, 2012 May 26)
|
||||
Update Jun 2.
|
||||
|
||||
Patch to add ":py3do". (Lilydjwg, 2012 Apr 7)
|
||||
|
||||
`[ moves to character after insert, instead of the last inserted character.
|
||||
`] moves to character after insert, instead of the last inserted character.
|
||||
(Yukihiro Nakadaira, 2011 Dec 9)
|
||||
|
||||
Plugin for Modeleasy. (Massimiliano Tripoli, 2011 Nov 29)
|
||||
|
||||
When using remote-silent the -R flag is not passed on. (Axel Bender, 2012 May
|
||||
31)
|
||||
|
||||
Updated syntax file for ssh_config, maintainer doesn't respond.
|
||||
(Leonard Ehrenfried, 2011 Sep 26)
|
||||
|
||||
BufWinLeave triggers too late when quitting last window in a tab page. (Lech
|
||||
Lorens, 2012 Feb 21)
|
||||
|
||||
@@ -188,12 +467,6 @@ On MS-Windows a temp dir with a & init causes system() to fail. (Ben Fritz,
|
||||
'list' is set. (Dennis Preiser)
|
||||
Patch 7.3.116 was the wrong solution.
|
||||
Christian Brabandt has another incomplete patch. (2011 Jul 13)
|
||||
Also: Alignment in help with tabs gets messed up, esp. at ":help index".
|
||||
Probably need to make a tab work like there was no concealing. Possibly with
|
||||
an option. Like line wrapping works as if there is no concealing.
|
||||
Patch by Dominique Pelle, Also fixes "fC" problem.
|
||||
"fC" doesn't position the cursor correctly when there are concealed
|
||||
characters. Patch by Christian Brabandt, 2011 Oct 11)
|
||||
|
||||
With concealed text mouse click doesn't put the cursor in the right position.
|
||||
(Herb Sitz) Fix by Christian Brabandt, 2011 Jun 16. Doesn't work properly,
|
||||
@@ -203,15 +476,9 @@ Syntax region with 'concealends' and a 'cchar' value, 'conceallevel' set to 2,
|
||||
only one of the two ends gets the cchar displayed. (Brett Stahlman, 2010 Aug
|
||||
21, Ben Fritz, 2010 Sep 14)
|
||||
|
||||
'cursorline' is drawn incorrectly in diff mode. Patch by Christian Brabandt,
|
||||
2012 Apr 2.
|
||||
|
||||
'cursorline' works on a text line only. Add 'cursorscreenline' for
|
||||
highlighting the screen line. (Christian Brabandt, 2012 Mar 31)
|
||||
|
||||
Win32: Does building a 64 bit version with VC9 give warnings for int
|
||||
conversions? (Mike Williams)
|
||||
|
||||
Win32: Patch to use task dialogs when available. (Sergiu Dotenco, 2011 Sep 17)
|
||||
New feature, requires testing. Made some remarks.
|
||||
|
||||
@@ -231,6 +498,9 @@ Oct 26)
|
||||
|
||||
Bug in repeating Visual "u". (Lawrence Kesteloot, 2010 Dec 20)
|
||||
|
||||
Using "p" in Visual mode while specifying the small delete register "-
|
||||
overwrites the register before it is put. (Marcin Szamotulski, 2012 Nov 23)
|
||||
|
||||
With "unamedplus" in 'clipboard' pasting in Visual mode causes error for empty
|
||||
register. (Michael Seiwald, 2011 Jun 28) I can't reproduce it.
|
||||
|
||||
@@ -249,14 +519,8 @@ The error was 'RenderBadPicture (invalid Picture parameter)'.
|
||||
backtrace from your debugger if you break on the gdk_x_error() function.)
|
||||
Check that number of pixels doesn't go above 65535?
|
||||
|
||||
popup completion menu closes quickly when there is a fold in the buffer. (Jan
|
||||
Christoph Ebersbach, 2011 Jul 3)
|
||||
|
||||
Windows keys not set properly on Windows 7? (cncyber, 2010 Aug 26)
|
||||
|
||||
This line hangs Vim, because of syntax HL:
|
||||
call append(line, "INFO ....12....18....24....30....36....42....48....54....60....66....72....78%$")
|
||||
|
||||
When using a Vim server, a # in the path causes an error message.
|
||||
(Jeff Lanzarotta, 2011 Feb 17)
|
||||
|
||||
@@ -309,9 +573,6 @@ mapping, how to restore the script ID?
|
||||
Bug in try/catch: return with invalid compare throws error that isn't caught.
|
||||
(ZyX, 2011 Jan 26)
|
||||
|
||||
Highlighting stops working after changing it many times. Script to reproduce
|
||||
it: Pablo Contreras, 2010 Oct 12 Windows XP and 7. Font is never freed?
|
||||
|
||||
When setting a local option value from the global value, add a script ID that
|
||||
indicates this, so that ":verbose set" can give a hint. Check with options in
|
||||
the help file.
|
||||
@@ -396,6 +657,9 @@ New esperanto spell file can't be processed. (Dominique Pelle, 2011 Jan 30)
|
||||
"L'Italie" noted as a spell error at start of the sentence. (Dominique Pelle,
|
||||
2011 Feb 27)
|
||||
|
||||
Functions to read the actual contents of the screen, so that things like
|
||||
conceal can be tested. (Nazri Ramliy, 2013 Feb 18)
|
||||
|
||||
Copy/paste between Vim and Google chrome doesn't work well for multi-byte
|
||||
characters. (Ben Haskell, 2010 Sep 17)
|
||||
When putting text in the cut buffer (when exiting) and conversion doesn't work
|
||||
@@ -407,6 +671,9 @@ Experimental patch by Christian Brabandt, 2012 Apr 19.
|
||||
Editing a file with a ^M with 'ff' set to "mac", opening a help file, then the
|
||||
^M is displayed as ^J sometimes. Getting 'ff' value from wrong window/buffer?
|
||||
|
||||
'colorcolumn' has higher priority than hlsearch. Should probably be the other
|
||||
way around. (Nazri Ramliy, 2013 Feb 19)
|
||||
|
||||
When Vim is put in the background (SIGTSTP) and then gets a SIGHUP it doesn't
|
||||
exit. It exists as soon as back in the foreground. (Stephen Liang, 2011 Jan
|
||||
9) Caused by vim_handle_signal(SIGNAL_BLOCK); in ui.c.
|
||||
@@ -417,14 +684,14 @@ the command line. (Ingo Karkat, 2011 Jan 25)
|
||||
Since patch 7.2.46 Yankring plugin has become very slow, eventually make Vim
|
||||
crash? (Raiwil, 2010 Nov 17)
|
||||
|
||||
Python: Adding line to buffer other than the current one doesn't work
|
||||
correctly. (Rozbujnik, 2010 Dec 19)
|
||||
|
||||
Patch to add 'systemencoding', convert between 'encoding' and this for file
|
||||
names, shell commands and the like. (Kikuchan, 2010 Oct 14)
|
||||
Assume the system converts between the actual encoding of the filesystem to
|
||||
the system encoding (usually utf-8).
|
||||
|
||||
Patch to add GUI colors to the terminal, when it supports it. (ZyX, 2013 Jan
|
||||
26)
|
||||
|
||||
Problem producing tags file when hebrew.frx is present. It has a BOM.
|
||||
Results in E670. (Tony Mechelynck, 2010 May 2)
|
||||
|
||||
@@ -538,6 +805,11 @@ Add local time at start of --startuptime output.
|
||||
Requires configure check for localtime().
|
||||
Use format year-month-day hr:min:sec.
|
||||
|
||||
Patch to add "combine" to :syntax, combines highlight attributes. (Nate
|
||||
Soares, 2012 Dec 3)
|
||||
|
||||
Patch to make ":hi link" also take arguments. (Nate Soares, 2012 Dec 4)
|
||||
|
||||
Shell not recognized properly if it ends in "csh -f". (James Vega, 2009 Nov 3)
|
||||
Find tail? Might have a / in argument. Find space? Might have space in
|
||||
path.
|
||||
@@ -576,24 +848,11 @@ Problem with stop directory in findfile(). (Adam Simpkins, 2009 Aug 26)
|
||||
Using ']' as the end of a range in a pattern requires double escaping:
|
||||
/[@-\\]] (Andy Wokula, 2011 Jun 28)
|
||||
|
||||
Undo problem: line not removed as expected when using setline() from Insert
|
||||
mode. (Israel Chauca, 2010 May 13, more in second msg)
|
||||
Break undo when CTRL-R = changes the text? Or save more lines?
|
||||
|
||||
Slow combination of folding and PHP syntax highlighting. Script to reproduce
|
||||
it. Caused by "syntax sync fromstart" in combination with patch 7.2.274.
|
||||
(Christian Brabandt, 2010 May 27)
|
||||
Generally, folding with 'foldmethod' set to "syntax" is slow. Do profiling to
|
||||
find out why.
|
||||
|
||||
Syntax priority problem. (Charles Campbell, 2011 Sep 15)
|
||||
|
||||
When completion inserts the first match, it may trigger the line to be folded.
|
||||
Disable updating folds while completion is active? (Peter Odding, 2010 Jun 9)
|
||||
|
||||
Using ":call foo#d.f()" doesn't autoload the "foo.vim" file. Works OK for
|
||||
echo, just not for ":call" and ":call call()". (Ted, 2011 Mar 17)
|
||||
|
||||
When a:base in 'completefunc' starts with a number it's passed as a number,
|
||||
not a string. (Sean Ma) Need to add flag to call_func_retlist() to force a
|
||||
string value.
|
||||
@@ -622,7 +881,7 @@ to avoid changing 'eventignore'?
|
||||
Patch for displaying 0x200c and 0x200d. (Ali Gholami Rudi, 2009 May 6)
|
||||
Probably needs a bit of work.
|
||||
|
||||
List of encoding aliases. (Takao Fujiware, 2009 Jul 18)
|
||||
List of encoding aliases. (Takao Fujiwara, 2009 Jul 18)
|
||||
Are they all OK? Update Jul 22.
|
||||
|
||||
Win32: Improved Makefile for MSVC. (Leonardo Valeri Manera, 2010 Aug 18)
|
||||
@@ -652,7 +911,7 @@ Problem with <script> mappings (Andy Wokula, 2009 Mar 8)
|
||||
When starting Vim with "gvim -f -u non_existent_file > foo.txt" there are a
|
||||
few control characters in the output. (Dale Wiles, 2009 May 28)
|
||||
|
||||
'cmdwinheight is only used in last window when 'winheight' is a large value.
|
||||
'cmdwinheight' is only used in last window when 'winheight' is a large value.
|
||||
(Tony Mechelynck, 2009 Apr 15)
|
||||
|
||||
Status line containing winnr() isn't updated when splitting the window (Clark
|
||||
@@ -682,10 +941,6 @@ Now that colnr_T is int instead of unsigned, more type casts can be removed.
|
||||
'delcombine' does not work for the command line. (Tony Mechelynck, 2009 Jul
|
||||
20)
|
||||
|
||||
Unwanted file name escaping: ":echo input('file:' , '', 'file')"
|
||||
And use file name completion on a file with spaces. (Frederic Hardy, 2009 Mar
|
||||
23)
|
||||
|
||||
Don't load macmap.vim on startup, turn it into a plugin. (Ron Aaron,
|
||||
2009 Apr 7) Reminder Apr 14.
|
||||
|
||||
@@ -725,10 +980,6 @@ Support a 'systemencoding' option (for Unix). It specifies the encoding of
|
||||
file names. (Kikuchan, 2010 Oct 5). Useful on a latin1 or double-byte Asian
|
||||
system when 'encoding' is "utf-8".
|
||||
|
||||
Win32: A --remote command that has a directory name starting with a ( doesn't
|
||||
work, the backslash is removed, assuming that it escapes the (. (Valery
|
||||
Kondakoff, 2009 May 13)
|
||||
|
||||
Win32 GUI: Changing manifest helps for dpi changes (Joe Castro, 2009 Mar 27)
|
||||
|
||||
Win32 GUI: last message from startup doesn't show up when there is an echoerr
|
||||
@@ -746,7 +997,7 @@ very high. (Yegappan Lakshmanan, 2010 Jul 22, Michael Peeters, 2010 Jul 22)
|
||||
Directory wrong in session file, caused by ":lcd" in BufEnter autocommand.
|
||||
(Felix Kater, 2009 Mar 3)
|
||||
|
||||
Session file generates error upon loading, cause bu --remote-silent-tab.
|
||||
Session file generates error upon loading, cause by --remote-silent-tab.
|
||||
(7tommm (ytommm) 2010 Nov 24)
|
||||
|
||||
Using ~ works OK on 'a' with composing char, but not on 0x0418 with composing
|
||||
@@ -786,9 +1037,6 @@ shellescape() depends on 'shellshash' for quoting. That doesn't work when
|
||||
Use a different option or let it depend on whether 'shell' looks like a
|
||||
unix-like shell?
|
||||
|
||||
Allow patches to add something to version.c, like with an official patch, so
|
||||
that :version output shows which patches have been applied.
|
||||
|
||||
Bug: in Ex mode (after "Q") backslash before line break, when yanked into a
|
||||
register and executed, results in <Nul>: instead of line break.
|
||||
(Konrad Schwarz, 2010 Apr 16)
|
||||
@@ -815,6 +1063,7 @@ ATTENTION message? (Tony Mechelynck, 2008 Dec 1)
|
||||
Also: swap files are in ~/tmp/ One has relative file name ".mozilla/...".
|
||||
|
||||
Add v:motion_force. (Kana Natsuno, 2008 Dec 6)
|
||||
Maybe call it v:motiontype.
|
||||
|
||||
Runtime files for Clojure. (Toralf Wittner, 2008 Jun 25)
|
||||
|
||||
@@ -867,8 +1116,6 @@ error message? Or is this easy to implement? (Nathan Stratton Treadway, 2008
|
||||
Aug 20) This is in ucs2bytes(), search for 0xBF. Using the ++bad argument is
|
||||
at the other match for 0xBF.
|
||||
|
||||
Fix for matchparen HL doesn't work. beep.
|
||||
|
||||
When adding "-complete=file" to a user command this also changes how the
|
||||
argument is processed for <f-args>. (Ivan Tishchenko, 2008 Aug 19)
|
||||
|
||||
@@ -914,6 +1161,15 @@ escaping characters where the backslash is not removed later. Asked Chris for
|
||||
an alternate solution, also for src/ex_getln.c.
|
||||
This also fails when the file or directory name contains "%". (Thoml, 2008
|
||||
July 7)
|
||||
Using --remote-silent while the current directory has a # in the name does not
|
||||
work, the # needs to be escaped. (Tramblay Bruno, 2012 Sep 15)
|
||||
|
||||
When using remote-silent the -R flag is not passed on. (Axel Bender, 2012 May
|
||||
31)
|
||||
|
||||
Win32: A --remote command that has a directory name starting with a ( doesn't
|
||||
work, the backslash is removed, assuming that it escapes the (. (Valery
|
||||
Kondakoff, 2009 May 13)
|
||||
|
||||
Problem with 'langmap' being used on the rhs of a mapping. (Nikolai Weibull,
|
||||
2008 May 14)
|
||||
@@ -928,6 +1184,14 @@ Oct 19) Check for "col" being "MAXCOL" separately?
|
||||
Unexpectedly inserting a double quote. (Anton Woellert, 2008 Mar 23)
|
||||
Works OK when 'cmdheight' is 2.
|
||||
|
||||
8 Use a mechanism similar to omni completion to figure out the kind of tab
|
||||
for CTRL-] and jump to the appropriate matching tag (if there are
|
||||
several).
|
||||
Alternative: be able to define a function that takes the tag name and uses
|
||||
taglist() to find the right location. With indication of using CTRL-] so
|
||||
that the context can be taken into account. (Robert Webb)
|
||||
Patch by Christian Brabandt, 2013 May 31.
|
||||
|
||||
Test54 should not use shell commands. Make it portable.
|
||||
|
||||
The utf class table is missing some entries:
|
||||
@@ -995,18 +1259,6 @@ Would be more consistent when an existing tab is re-used. (Tony Mechelynck)
|
||||
|
||||
Add ":nofold". Range will apply without expanding to closed fold.
|
||||
|
||||
Including NFA regexp code:
|
||||
Use "\%#= to set the engine: 0 = automatic, 1 = backtracking, 2 = new.
|
||||
Useful in tests.
|
||||
Performance tests:
|
||||
- ~/vim/test/veryslow.js (file from Daniel Fetchinson)
|
||||
- ~/vim/test/slowsearch
|
||||
- ~/vim/test/rgb.vim
|
||||
- ~/vim/text/FeiqCfg.xml (file from Netjune)
|
||||
- ~/vim/text/edl.svg (also XML)
|
||||
- search for a.*e*exn in the vim executable. Go to last line to use
|
||||
'hlsearch'.
|
||||
|
||||
Using Aap to build Vim: add remarks about how to set personal preferences.
|
||||
Example on http://www.calmar.ws/tmp/aap.html
|
||||
|
||||
@@ -1154,11 +1406,6 @@ makes his own wrapper). Add a magic string with the version number to the
|
||||
Changes for Win32 makefile. (Mike Williams, 2007 Jan 22, Alexei Alexandrov,
|
||||
2007 Feb 8)
|
||||
|
||||
Patch for Win32 clipboard under Cygwin. (Frodak Baksik, Feb 15)
|
||||
Sutcliffe says it works well.
|
||||
Update 2007 May 22 for Vim 7.1
|
||||
Update 2008 Dec 2008 for Vim 7.2.xx (Sharonov)
|
||||
|
||||
Win32: Can't complete shell command names. Why is setting xp_context in
|
||||
set_one_cmd_context() inside #ifndef BACKSLASH_IN_FILENAME?
|
||||
|
||||
@@ -1196,10 +1443,6 @@ pointer in long and seek offset in 64 bit var.
|
||||
|
||||
Win32: patch for fullscreen mode. (Liushaolin, 2008 April 17)
|
||||
|
||||
Win32: When there is 4 Gbyte of memory mch_avail_mem() doesn't work properly.
|
||||
Unfinished patch by Jelle Geerts, 2008 Aug 24.
|
||||
Let mch_avail_mem() return Kbyte instead?
|
||||
|
||||
Win32: When 'shell' is bash shellescape() doesn't always do the right thing.
|
||||
Depends on 'shellslash', 'shellquote' and 'shellxquote', but shellescape()
|
||||
only takes 'shellslash' into account.
|
||||
@@ -1248,9 +1491,6 @@ if_ruby.c.
|
||||
|
||||
":helpgrep" should use the directory from 'helpfile'.
|
||||
|
||||
Patch to dynamically load Python on Solaris. (Danek Duvall, 2009 Feb 16)
|
||||
Needs more work.
|
||||
|
||||
The need_fileinfo flag is messy. Instead make the message right away and put
|
||||
it in keep_msg?
|
||||
|
||||
@@ -1292,9 +1532,6 @@ When doing ":quit" the Netbeans "killed" event isn't sent. (Xavier de Gaye,
|
||||
2008 Nov 10) call netbeans_file_closed() at the end of buf_freeall(), or in
|
||||
all places where buf_freeall() is called?
|
||||
|
||||
":python os.chdir('/tmp')" makes short buffer names invalid. (Xavier de Gaye)
|
||||
Check directory and call shorten_fnames()?
|
||||
|
||||
aucmd_prepbuf() should also use a window in another tab page.
|
||||
|
||||
When unloading a buffer in a BufHidden autocommand the hidden flag is reset?
|
||||
@@ -1330,9 +1567,6 @@ somehow? Or use a new function.
|
||||
|
||||
Mac: Using gvim: netrw window disappears. (Nick Lo, 2006 Jun 21)
|
||||
|
||||
Mac: OS/X 10.4 with Python 2.5 installed: configure finds an extra argument
|
||||
that breaks the build. (Brian Victor, 2008 Sep 1)
|
||||
|
||||
Add an option to specify the character to use when a double-width character is
|
||||
moved to the next line. Default '>', set to a space to blank it out. Check
|
||||
that char is single width when it's set (compare with 'listchars').
|
||||
@@ -1469,9 +1703,6 @@ resulting in highlighted "{" in that window, not in the other.
|
||||
In mswin.vim: Instead of mapping <C-V> for Insert mode in a complicated way,
|
||||
can it be done like ":imap <C-V> <MiddleMouse>" without negative side effects?
|
||||
|
||||
Completion menu disappears when using 'cursorcolumn'. (Sven-Hendrik Haase,
|
||||
2011 May 23)
|
||||
|
||||
GTK: when the Tab pages bar appears or disappears while the window is
|
||||
maximized the window is no longer maximized. Patch that has some idea but
|
||||
doesn't work from Geoffrey Antos, 2008 May 5.
|
||||
@@ -1509,6 +1740,9 @@ Win32, NTFS: When editing a specific infostream directly and 'backupcopy' is
|
||||
name is something like "c:\path\foo.txt:bar", includes a colon. (Alex
|
||||
Jakushev, 2008 Feb 1)
|
||||
|
||||
printf() uses the field width in bytes. Can it be made character width,
|
||||
perhaps with a modifier? What does Posix say?
|
||||
|
||||
Small problem displaying diff filler line when opening windows with a script.
|
||||
(David Luyer, 2007 Mar 1 ~/Mail/oldmail/mool/in.15872 )
|
||||
|
||||
@@ -1575,8 +1809,7 @@ Patch to support horizontal scroll wheel in GTK. Untested. (Bjorn Winckler,
|
||||
|
||||
|
||||
At next release:
|
||||
- Rename src/Makefile and create a new one like toplevel Makefile that
|
||||
creates auto/config.mk when it's not there? (Ben Schmidt, 2011 Feb 11)
|
||||
- Build a huge version by default.
|
||||
- Improve plugin handling: Automatic updates, handle dependencies?
|
||||
E.g. Vundle: https://github.com/gmarik/vundle
|
||||
|
||||
@@ -1618,7 +1851,6 @@ More patches:
|
||||
more friendly for the Vim distribution.
|
||||
New version received 2008 Jan 6.
|
||||
No maintenance in two years...
|
||||
- Patch to access screen under Python. (Marko Mahni, 2010 Jul 18)
|
||||
- Patch to open dropped files in new tabs. (Michael Trim, 2010 Aug 3)
|
||||
|
||||
Awaiting updated patches:
|
||||
@@ -2170,8 +2402,6 @@ Macintosh:
|
||||
the :catch commands are always executed, also when the file is edited
|
||||
normally. Should reset did_emsg and undo side effects. Also make sure
|
||||
the ATTENTION message shows up. Servatius Brandt works on this.
|
||||
8 ":g//" gives "Pattern not found error" with E486. Should not use the
|
||||
error number, it's not a regular error message.
|
||||
7 Vimtutor leaves escape sequence in terminal. This is the xterm response to
|
||||
requesting the version number. (Yasuhiro Matsumoto)
|
||||
8 When redirecting and using ":silent" the current column for displaying and
|
||||
@@ -2199,7 +2429,6 @@ Macintosh:
|
||||
8 When doing Insert mode completion a mapping cannot recursively call
|
||||
edit(), because the completion information is global. Put everything in
|
||||
an allocated structure?
|
||||
6 Python: ":py raw_input('prompt')" doesn't work. (Manu Hack)
|
||||
8 Command line completion: buffers "foo.txt" and "../b/foo.txt", completing
|
||||
":buf foo<Tab>" doesn't find the second one. (George V. Reilly)
|
||||
7 mb_off2cells() doesn't work correctly on the tail byte of a double-byte
|
||||
@@ -3448,12 +3677,6 @@ Tags:
|
||||
make the filename or the whole option use |wildcards| globing, better
|
||||
would be to merge the 2 kinds of globing. originally (Erik Falor, 2008
|
||||
April 18), updated (Ian Kelling, 2008 July 4)
|
||||
8 Use a mechanism similar to omni completion to figure out the kind of tab
|
||||
for CTRL-] and jump to the appropriate matching tag (if there are
|
||||
several).
|
||||
Alternative: be able to define a function that takes the tag name and uses
|
||||
taglist() to find the right location. With indication of using CTRL-] so
|
||||
that the context can be taken into account. (Robert Webb)
|
||||
7 Can CTRL-] (jump to tag) include a following "." and "->" to restrict the
|
||||
number of possible matches? Check tags file for an item that has members.
|
||||
(Flemming Madsen)
|
||||
@@ -3496,9 +3719,6 @@ Tags:
|
||||
Win32 GUI:
|
||||
8 Make debug mode work while starting up (vim -D). Open console window for
|
||||
the message and input?
|
||||
7 The Python interface only works with one version of Python, selected at
|
||||
compile time. Can this be made to work with version 2.1 and 2.2
|
||||
dynamically?
|
||||
7 GvimExt: when there are several existing Vims, move the list to a submenu.
|
||||
(Mike McCollister)
|
||||
8 When using "Edit with Vim" for one file it changes directory, when several
|
||||
@@ -3860,9 +4080,6 @@ Command line completion:
|
||||
|
||||
|
||||
Command line history:
|
||||
9 Remember which command lines were actually typed and were not loaded from
|
||||
viminfo. When writing viminfo append only these lines, so that lines from
|
||||
other Vim's are not overwritten.
|
||||
- Add "KeyWasTyped" flag: It's reset before each command and set when a
|
||||
character from the keyboard is consumed. Value is used to decide to put a
|
||||
command line in history or not. Put line in history if it didn't
|
||||
@@ -4051,7 +4268,7 @@ Select mode:
|
||||
8 In blockwise mode, typed characters are inserted in front of the block,
|
||||
backspace deletes a column before the block. (Steve Hall)
|
||||
7 Alt-leftmouse starts block mode selection in MS Word.
|
||||
See http://www.vim.org/tips/tip.php?tip_id=743
|
||||
See http://vim.wikia.com/wiki/Use_Alt-Mouse_to_select_blockwise.
|
||||
7 Add Cmdline-select mode. Like Select mode, but used on the command line.
|
||||
- Change gui_send_mouse_event() to pass on mouse events when 'mouse'
|
||||
contains 'C' or 'A'.
|
||||
@@ -4207,6 +4424,7 @@ Incsearch:
|
||||
|
||||
|
||||
Searching:
|
||||
9 Should have an option for :vimgrep to find lines without a match.
|
||||
8 Add "g/" and "gb" to search for a pattern in the Visually selected text?
|
||||
"g?" is already used for rot13.
|
||||
The vis.vim script has a ":S" command that does something like this.
|
||||
@@ -4338,6 +4556,9 @@ Searching:
|
||||
|
||||
|
||||
Undo:
|
||||
9 ":gundo" command: global undo. Undoes changes spread over multiple files
|
||||
in the order they were made. Also ":gredo". Both with a count. Useful
|
||||
when tests fail after making changes and you forgot in which files.
|
||||
9 After undo/redo, in the message show whether the buffer is modified or
|
||||
not.
|
||||
8 Use timestamps for undo, so that a version a certain time ago can be found
|
||||
@@ -4522,6 +4743,7 @@ Options:
|
||||
7 There is 'titleold', why is there no 'iconold'? (Chazelas)
|
||||
7 Make 'scrolloff' a global-local option, so that it can be different in the
|
||||
quickfix window, for example. (Gary Holloway)
|
||||
Also do 'sidescrolloff'.
|
||||
|
||||
|
||||
External commands:
|
||||
@@ -4711,8 +4933,6 @@ Debug mode:
|
||||
|
||||
|
||||
Various improvements:
|
||||
9 Python: be able to define a Python function that can be called directly
|
||||
from Vim script. Requires converting the arguments and return value.
|
||||
7 Add plugins for formatting? Should be able to make a choice depending on
|
||||
the language of a file (English/Korean/Japanese/etc.).
|
||||
Setting the 'langformat' option to "chinese" would load the
|
||||
@@ -4737,7 +4957,6 @@ Various improvements:
|
||||
7 Allow a window not to have a statusline. Makes it possible to use a
|
||||
window as a buffer-tab selection.
|
||||
8 Allow non-active windows to have a different statusline. (Yakov Lerner)
|
||||
6 Python interface: add vim.message() function. (Michal Vitecek, 2002 Nov 5)
|
||||
7 Support using ":vert" with User commands. Add expandable items <vert>.
|
||||
Do the same for ":browse" and ":confirm"?
|
||||
For ":silent" and ":debug" apply to the whole user command.
|
||||
@@ -4968,8 +5187,6 @@ Various improvements:
|
||||
- Add a variant of CTRL-V that stops interpretation of more than one
|
||||
character. For entering mappings on the command line where a key contains
|
||||
several special characters, e.g. a trailing newline.
|
||||
- Add regex for 'paragraphs' and 'sections': 'parare' and 'sectre'. Combine
|
||||
the two into a regex for searching. (Ned Konz)
|
||||
- Make '2' option in 'formatoptions' also work inside comments.
|
||||
- Add 's' flag to 'formatoptions': Do not break when inside a string. (Dodt)
|
||||
- When window size changed (with the mouse) and made too small, set it back
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*uganda.txt* For Vim version 7.3. Last change: 2012 May 28
|
||||
*uganda.txt* For Vim version 7.3. Last change: 2012 Dec 02
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -238,6 +238,7 @@ Canada: Contact Kibaale Children's Fund (KCF) in Surrey, Canada. They
|
||||
Holland: Transfer to the account of "Stichting ICCF Holland" in Lisse.
|
||||
This will allow for tax deduction if you live in Holland.
|
||||
Postbank, nr. 4548774
|
||||
IBAN: NL95 INGB 0004 5487 74
|
||||
|
||||
Germany: It is possible to make donations that allow for a tax return.
|
||||
Check the ICCF web site for the latest information:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*usr_05.txt* For Vim version 7.3. Last change: 2009 Jun 04
|
||||
*usr_05.txt* For Vim version 7.3. Last change: 2012 Nov 20
|
||||
|
||||
VIM USER MANUAL - by Bram Moolenaar
|
||||
|
||||
@@ -49,8 +49,7 @@ For MS-DOS and MS-Windows you can use one of these:
|
||||
|
||||
The vimrc file can contain all the commands that you type after a colon. The
|
||||
most simple ones are for setting options. For example, if you want Vim to
|
||||
always start with the 'incsearch' option on, add this line you your vimrc
|
||||
file: >
|
||||
always start with the 'incsearch' option on, add this line your vimrc file: >
|
||||
|
||||
set incsearch
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ side by side. All this is possible with split windows.
|
||||
|08.6| Commands for all windows
|
||||
|08.7| Viewing differences with vimdiff
|
||||
|08.8| Various
|
||||
|08.9| Tab pages
|
||||
|08.9| Tab pages
|
||||
|
||||
Next chapter: |usr_09.txt| Using the GUI
|
||||
Previous chapter: |usr_07.txt| Editing more than one file
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*usr_21.txt* For Vim version 7.3. Last change: 2008 Nov 09
|
||||
*usr_21.txt* For Vim version 7.3. Last change: 2012 Nov 02
|
||||
|
||||
VIM USER MANUAL - by Bram Moolenaar
|
||||
|
||||
@@ -282,7 +282,7 @@ example, use: >
|
||||
SESSION HERE, SESSION THERE
|
||||
|
||||
The obvious way to use sessions is when working on different projects.
|
||||
Suppose you store you session files in the directory "~/.vim". You are
|
||||
Suppose you store your session files in the directory "~/.vim". You are
|
||||
currently working on the "secret" project and have to switch to the "boring"
|
||||
project: >
|
||||
|
||||
@@ -295,7 +295,7 @@ is saved, using ":mksession!". This overwrites the previous session. The
|
||||
next time you load the secret session you can continue where you were at this
|
||||
point. And finally you load the new "boring" session.
|
||||
|
||||
If you open help windows, split and close various window, and generally mess
|
||||
If you open help windows, split and close various windows, and generally mess
|
||||
up the window layout, you can go back to the last saved session: >
|
||||
|
||||
:source ~/.vim/boring.vim
|
||||
@@ -423,10 +423,10 @@ and nine numbered 1 to 9.
|
||||
A VIEW WITH A NAME
|
||||
|
||||
The second basic way to use views is by storing the view in a file with a name
|
||||
you chose. This view can be loaded while editing another file. Vim will then
|
||||
switch to editing the file specified in the view. Thus you can use this to
|
||||
quickly switch to editing another file, with all its options set as you saved
|
||||
them.
|
||||
you choose. This view can be loaded while editing another file. Vim will
|
||||
then switch to editing the file specified in the view. Thus you can use this
|
||||
to quickly switch to editing another file, with all its options set as you
|
||||
saved them.
|
||||
For example, to save the view of the current file: >
|
||||
|
||||
:mkview ~/.vim/main.vim
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*usr_22.txt* For Vim version 7.3. Last change: 2010 Feb 21
|
||||
*usr_22.txt* For Vim version 7.3. Last change: 2012 Nov 15
|
||||
|
||||
VIM USER MANUAL - by Bram Moolenaar
|
||||
|
||||
@@ -326,9 +326,9 @@ shorter to type: >
|
||||
|
||||
The output could look like this:
|
||||
|
||||
1 #h "help.txt" line 62 ~
|
||||
2 %a+ "usr_21.txt" line 1 ~
|
||||
3 "usr_toc.txt" line 1 ~
|
||||
1 #h "help.txt" line 62 ~
|
||||
2 %a + "usr_21.txt" line 1 ~
|
||||
3 "usr_toc.txt" line 1 ~
|
||||
|
||||
The first column contains the buffer number. You can use this to edit the
|
||||
buffer without having to type the name, see below.
|
||||
|
||||
@@ -18,7 +18,7 @@ This chapter explains the different ways this can be done.
|
||||
|28.7| Folding by syntax
|
||||
|28.8| Folding by expression
|
||||
|28.9| Folding unchanged lines
|
||||
|28.10| Which fold method to use?
|
||||
|28.10| Which fold method to use?
|
||||
|
||||
Next chapter: |usr_29.txt| Moving through programs
|
||||
Previous chapter: |usr_27.txt| Search commands and patterns
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*usr_41.txt* For Vim version 7.3. Last change: 2012 Mar 16
|
||||
*usr_41.txt* For Vim version 7.3. Last change: 2013 Feb 20
|
||||
|
||||
VIM USER MANUAL - by Bram Moolenaar
|
||||
|
||||
@@ -863,12 +863,15 @@ Window size and position: *window-size-functions*
|
||||
winsaveview() get view of current window
|
||||
winrestview() restore saved view of current window
|
||||
|
||||
Various: *various-functions*
|
||||
mode() get current editing mode
|
||||
visualmode() last visual mode used
|
||||
Mappings: *mapping-functions*
|
||||
hasmapto() check if a mapping exists
|
||||
mapcheck() check if a matching mapping exists
|
||||
maparg() get rhs of a mapping
|
||||
wildmenumode() check if the wildmode is active
|
||||
|
||||
Various: *various-functions*
|
||||
mode() get current editing mode
|
||||
visualmode() last visual mode used
|
||||
exists() check if a variable, function, etc. exists
|
||||
has() check if a feature is supported in Vim
|
||||
changenr() return number of most recent change
|
||||
@@ -1581,7 +1584,7 @@ Here the comment part will be ignored. However, Vim will try to unmap
|
||||
|
||||
RESTORING THE VIEW
|
||||
|
||||
Sometimes you want to make a change and go back to where cursor was.
|
||||
Sometimes you want to make a change and go back to where the cursor was.
|
||||
Restoring the relative position would also be nice, so that the same line
|
||||
appears at the top of the window.
|
||||
This example yanks the current line, puts it above the first line in the
|
||||
@@ -1681,7 +1684,7 @@ in your plugin file!
|
||||
HEADER
|
||||
|
||||
You will probably add new corrections to the plugin and soon have several
|
||||
versions laying around. And when distributing this file, people will want to
|
||||
versions lying around. And when distributing this file, people will want to
|
||||
know who wrote this wonderful plugin and where they can send remarks.
|
||||
Therefore, put a header at the top of your plugin: >
|
||||
|
||||
|
||||
@@ -248,7 +248,7 @@ Subjects that can be read independently.
|
||||
|28.7| Folding by syntax
|
||||
|28.8| Folding by expression
|
||||
|28.9| Folding unchanged lines
|
||||
|28.10| Which fold method to use?
|
||||
|28.10| Which fold method to use?
|
||||
|
||||
|usr_29.txt| Moving through programs
|
||||
|29.1| Using tags
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*various.txt* For Vim version 7.3. Last change: 2012 Aug 03
|
||||
*various.txt* For Vim version 7.3. Last change: 2013 May 18
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -174,27 +174,37 @@ g8 Print the hex values of the bytes used in the
|
||||
the command-line. {commands} are executed like they
|
||||
are typed. For undo all commands are undone together.
|
||||
Execution stops when an error is encountered.
|
||||
|
||||
If the [!] is given, mappings will not be used.
|
||||
Without it, when this command is called from a
|
||||
non-remappable mapping (|:noremap|), the argument can
|
||||
be mapped anyway.
|
||||
|
||||
{commands} should be a complete command. If
|
||||
{commands} does not finish a command, the last one
|
||||
will be aborted as if <Esc> or <C-C> was typed.
|
||||
The display isn't updated while ":normal" is busy.
|
||||
This implies that an insert command must be completed
|
||||
(to start Insert mode, see |:startinsert|). A ":"
|
||||
command must be completed as well. And you can't use
|
||||
"Q" or "gQ" to start Ex mode.
|
||||
|
||||
The display is not updated while ":normal" is busy.
|
||||
|
||||
{commands} cannot start with a space. Put a count of
|
||||
1 (one) before it, "1 " is one space.
|
||||
|
||||
The 'insertmode' option is ignored for {commands}.
|
||||
|
||||
This command cannot be followed by another command,
|
||||
since any '|' is considered part of the command.
|
||||
|
||||
This command can be used recursively, but the depth is
|
||||
limited by 'maxmapdepth'.
|
||||
When this command is called from a non-remappable
|
||||
mapping |:noremap|, the argument can be mapped anyway.
|
||||
|
||||
An alternative is to use |:execute|, which uses an
|
||||
expression as argument. This allows the use of
|
||||
printable characters to represent special characters.
|
||||
|
||||
Example: >
|
||||
:exe "normal \<c-w>\<c-w>"
|
||||
< {not in Vi, of course}
|
||||
@@ -353,75 +363,75 @@ N *+mouseshape* |'mouseshape'|
|
||||
B *+mouse_dec* Unix only: Dec terminal mouse handling |dec-mouse|
|
||||
N *+mouse_gpm* Unix only: Linux console mouse handling |gpm-mouse|
|
||||
B *+mouse_netterm* Unix only: netterm mouse handling |netterm-mouse|
|
||||
N *+mouse_pterm* QNX only: pterm mouse handling |qnx-terminal|
|
||||
N *+mouse_pterm* QNX only: pterm mouse handling |qnx-terminal|
|
||||
N *+mouse_sysmouse* Unix only: *BSD console mouse handling |sysmouse|
|
||||
B *+mouse_sgr* Unix only: sgr mouse handling |sgr-mouse|
|
||||
N *+mouse_urxvt* Unix only: urxvt mouse handling |urxvt-mouse|
|
||||
N *+mouse_xterm* Unix only: xterm mouse handling |xterm-mouse|
|
||||
B *+multi_byte* 16 and 32 bit characters |multibyte|
|
||||
B *+mouse_urxvt* Unix only: urxvt mouse handling |urxvt-mouse|
|
||||
N *+mouse_xterm* Unix only: xterm mouse handling |xterm-mouse|
|
||||
N *+multi_byte* 16 and 32 bit characters |multibyte|
|
||||
*+multi_byte_ime* Win32 input method for multibyte chars |multibyte-ime|
|
||||
N *+multi_lang* non-English language support |multi-lang|
|
||||
N *+multi_lang* non-English language support |multi-lang|
|
||||
m *+mzscheme* Mzscheme interface |mzscheme|
|
||||
m *+mzscheme/dyn* Mzscheme interface |mzscheme-dynamic| |/dyn|
|
||||
m *+netbeans_intg* |netbeans|
|
||||
m *+ole* Win32 GUI only: |ole-interface|
|
||||
N *+path_extra* Up/downwards search in 'path' and 'tags'
|
||||
m *+ole* Win32 GUI only: |ole-interface|
|
||||
N *+path_extra* Up/downwards search in 'path' and 'tags'
|
||||
m *+perl* Perl interface |perl|
|
||||
m *+perl/dyn* Perl interface |perl-dynamic| |/dyn|
|
||||
N *+persistent_undo* Persistent undo |undo-persistence|
|
||||
*+postscript* |:hardcopy| writes a PostScript file
|
||||
*+postscript* |:hardcopy| writes a PostScript file
|
||||
N *+printer* |:hardcopy| command
|
||||
H *+profile* |:profile| command
|
||||
m *+python* Python 2 interface |python|
|
||||
m *+python/dyn* Python 2 interface |python-dynamic| |/dyn|
|
||||
m *+python/dyn* Python 2 interface |python-dynamic| |/dyn|
|
||||
m *+python3* Python 3 interface |python|
|
||||
m *+python3/dyn* Python 3 interface |python-dynamic| |/dyn|
|
||||
m *+python3/dyn* Python 3 interface |python-dynamic| |/dyn|
|
||||
N *+quickfix* |:make| and |quickfix| commands
|
||||
N *+reltime* |reltime()| function, 'hlsearch'/'incsearch' timeout,
|
||||
'redrawtime' option
|
||||
B *+rightleft* Right to left typing |'rightleft'|
|
||||
m *+ruby* Ruby interface |ruby|
|
||||
m *+ruby/dyn* Ruby interface |ruby-dynamic| |/dyn|
|
||||
N *+scrollbind* |'scrollbind'|
|
||||
N *+scrollbind* |'scrollbind'|
|
||||
B *+signs* |:sign|
|
||||
N *+smartindent* |'smartindent'|
|
||||
N *+smartindent* |'smartindent'|
|
||||
m *+sniff* SniFF interface |sniff|
|
||||
N *+startuptime* |--startuptime| argument
|
||||
N *+statusline* Options 'statusline', 'rulerformat' and special
|
||||
N *+startuptime* |--startuptime| argument
|
||||
N *+statusline* Options 'statusline', 'rulerformat' and special
|
||||
formats of 'titlestring' and 'iconstring'
|
||||
m *+sun_workshop* |workshop|
|
||||
N *+syntax* Syntax highlighting |syntax|
|
||||
*+system()* Unix only: opposite of |+fork|
|
||||
N *+tag_binary* binary searching in tags file |tag-binary-search|
|
||||
N *+tag_binary* binary searching in tags file |tag-binary-search|
|
||||
N *+tag_old_static* old method for static tags |tag-old-static|
|
||||
m *+tag_any_white* any white space allowed in tags file |tag-any-white|
|
||||
m *+tcl* Tcl interface |tcl|
|
||||
m *+tcl* Tcl interface |tcl|
|
||||
m *+tcl/dyn* Tcl interface |tcl-dynamic| |/dyn|
|
||||
*+terminfo* uses |terminfo| instead of termcap
|
||||
N *+termresponse* support for |t_RV| and |v:termresponse|
|
||||
N *+textobjects* |text-objects| selection
|
||||
N *+textobjects* |text-objects| selection
|
||||
*+tgetent* non-Unix only: able to use external termcap
|
||||
N *+title* Setting the window 'title' and 'icon'
|
||||
N *+toolbar* |gui-toolbar|
|
||||
N *+user_commands* User-defined commands. |user-commands|
|
||||
N *+viminfo* |'viminfo'|
|
||||
N *+vertsplit* Vertically split windows |:vsplit|
|
||||
N *+virtualedit* |'virtualedit'|
|
||||
N *+virtualedit* |'virtualedit'|
|
||||
S *+visual* Visual mode |Visual-mode|
|
||||
N *+visualextra* extra Visual mode commands |blockwise-operators|
|
||||
N *+visualextra* extra Visual mode commands |blockwise-operators|
|
||||
N *+vreplace* |gR| and |gr|
|
||||
N *+wildignore* |'wildignore'|
|
||||
N *+wildignore* |'wildignore'|
|
||||
N *+wildmenu* |'wildmenu'|
|
||||
S *+windows* more than one window
|
||||
m *+writebackup* |'writebackup'| is default on
|
||||
m *+xim* X input method |xim|
|
||||
m *+writebackup* |'writebackup'| is default on
|
||||
m *+xim* X input method |xim|
|
||||
*+xfontset* X fontset support |xfontset|
|
||||
m *+xpm_w32* Win32 GUI only: pixmap support |w32-xpm-support|
|
||||
*+xsmp* XSMP (X session management) support
|
||||
*+xsmp_interact* interactive XSMP (X session management) support
|
||||
N *+xterm_clipboard* Unix only: xterm clipboard handling
|
||||
m *+xterm_save* save and restore xterm screen |xterm-screens|
|
||||
N *+X11* Unix only: can restore window title |X11|
|
||||
m *+xterm_save* save and restore xterm screen |xterm-screens|
|
||||
N *+X11* Unix only: can restore window title |X11|
|
||||
|
||||
*/dyn* *E370* *E448*
|
||||
To some of the features "/dyn" is added when the
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
.\" Traduction Lundi 7 ao<61>t 2000 par Richard Hitier
|
||||
.\" Traduction lundi 7 ao<61>t 2000 par Richard Hitier
|
||||
.\" (richard.hitier@dial.oleane.com)
|
||||
.\" Mise <20> jour de la traduction par David Blanchet
|
||||
.\" (david.blanchet@free.fr) 2006-06-10
|
||||
.\" Mise <20> jour de la traduction par Dominique Pell<6C>
|
||||
.\" (dominique.pelle@gmail.com) 2008-11-29
|
||||
.\" (dominique.pelle@gmail.com) 2013-05-10
|
||||
.\"
|
||||
.TH VIM 1 "22 F<EFBFBD>vrier 2002"
|
||||
.TH VIM 1 "22 f<EFBFBD>vrier 2002"
|
||||
.SH NOM
|
||||
vim \- Vi IMproved, <20>diteur de texte pour programmeurs
|
||||
.SH SYNOPSIS
|
||||
@@ -156,7 +156,7 @@ Ex
|
||||
{commande} est interpr<70>t<EFBFBD>e comme une commande Ex.
|
||||
Si la {commande} contient des espaces, elle doit <20>tre entour<75>e
|
||||
de doubles-apostrophes (cela d<>pend du shell utilis<69>).
|
||||
Exemple: Vim "+set si" main.c
|
||||
Exemple : Vim "+set si" main.c
|
||||
.br
|
||||
Note : vous pouvez utiliser jusqu'<27> 10 commandes "+" ou "\-c".
|
||||
.TP
|
||||
@@ -204,7 +204,7 @@ Fonctionne comme vimdiff(1).
|
||||
\-d {p<>riph}
|
||||
Ouvre {p<>riph} pour l'utiliser comme terminal.
|
||||
Uniquement sur Amiga.
|
||||
Exemple:
|
||||
Exemple :
|
||||
"\-d con:20/30/600/150".
|
||||
.TP
|
||||
\-D
|
||||
@@ -269,7 +269,7 @@ quitte.
|
||||
Si
|
||||
.B Vim
|
||||
a <20>t<EFBFBD> compil<69> avec le support de la fonctionnalit<69> RIGHTLEFT pour l'<27>dition de
|
||||
fichiers de droite <20> gauche et les claviers h<>breu, cette option lance
|
||||
fichiers de droite <20> gauche et les claviers h<>breux, cette option lance
|
||||
.B Vim
|
||||
en mode H<>breu, c.-<2D>-d. avec les options 'hkmap' et 'rightleft' activ<69>es.
|
||||
Sinon, un message d'erreur est <20>mis et
|
||||
@@ -435,7 +435,7 @@ Mode restreint. Fonctionne comme si l'ex
|
||||
\-\-
|
||||
D<EFBFBD>limite la fin des options.
|
||||
Les arguments qui suivent seront consid<69>r<EFBFBD>s comme des noms de fichiers.
|
||||
Cela permet d'<27>diter des fichier d<>butant par un '\-'.
|
||||
Cela permet d'<27>diter des fichiers d<>butant par un '\-'.
|
||||
.TP
|
||||
\-\-echo\-wid
|
||||
IHM graphique GTK uniquement : retourne la Window ID sur stdout.
|
||||
@@ -586,4 +586,4 @@ Cette page de manuel a
|
||||
.br
|
||||
Cette page de manuel a <20>t<EFBFBD> mise <20> jour par David Blanchet.
|
||||
<david.blanchet@free.fr> 2006-04-10.
|
||||
Mise <20> jour 2012-05-06, Dominique Pell<6C> <dominique.pelle@gmail.com>
|
||||
Mise <20> jour 2013-05-10, Dominique Pell<6C> <dominique.pelle@gmail.com>
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
.\" Traduction Lundi 7 août 2000 par Richard Hitier
|
||||
.\" Traduction lundi 7 août 2000 par Richard Hitier
|
||||
.\" (richard.hitier@dial.oleane.com)
|
||||
.\" Mise à jour de la traduction par David Blanchet
|
||||
.\" (david.blanchet@free.fr) 2006-06-10
|
||||
.\" Mise à jour de la traduction par Dominique Pellé
|
||||
.\" (dominique.pelle@gmail.com) 2008-11-29
|
||||
.\" (dominique.pelle@gmail.com) 2013-05-10
|
||||
.\"
|
||||
.TH VIM 1 "22 Février 2002"
|
||||
.TH VIM 1 "22 février 2002"
|
||||
.SH NOM
|
||||
vim \- Vi IMproved, éditeur de texte pour programmeurs
|
||||
.SH SYNOPSIS
|
||||
@@ -156,7 +156,7 @@ Exécute {commande} après la lecture du premier fichier.
|
||||
{commande} est interprétée comme une commande Ex.
|
||||
Si la {commande} contient des espaces, elle doit être entourée
|
||||
de doubles-apostrophes (cela dépend du shell utilisé).
|
||||
Exemple: Vim "+set si" main.c
|
||||
Exemple : Vim "+set si" main.c
|
||||
.br
|
||||
Note : vous pouvez utiliser jusqu'à 10 commandes "+" ou "\-c".
|
||||
.TP
|
||||
@@ -204,7 +204,7 @@ Fonctionne comme vimdiff(1).
|
||||
\-d {périph}
|
||||
Ouvre {périph} pour l'utiliser comme terminal.
|
||||
Uniquement sur Amiga.
|
||||
Exemple:
|
||||
Exemple :
|
||||
"\-d con:20/30/600/150".
|
||||
.TP
|
||||
\-D
|
||||
@@ -269,7 +269,7 @@ quitte.
|
||||
Si
|
||||
.B Vim
|
||||
a été compilé avec le support de la fonctionnalité RIGHTLEFT pour l'édition de
|
||||
fichiers de droite à gauche et les claviers hébreu, cette option lance
|
||||
fichiers de droite à gauche et les claviers hébreux, cette option lance
|
||||
.B Vim
|
||||
en mode Hébreu, c.-à-d. avec les options 'hkmap' et 'rightleft' activées.
|
||||
Sinon, un message d'erreur est émis et
|
||||
@@ -435,7 +435,7 @@ Mode restreint. Fonctionne comme si l'exécutable commençait par la lettre 'r'.
|
||||
\-\-
|
||||
Délimite la fin des options.
|
||||
Les arguments qui suivent seront considérés comme des noms de fichiers.
|
||||
Cela permet d'éditer des fichier débutant par un '\-'.
|
||||
Cela permet d'éditer des fichiers débutant par un '\-'.
|
||||
.TP
|
||||
\-\-echo\-wid
|
||||
IHM graphique GTK uniquement : retourne la Window ID sur stdout.
|
||||
@@ -586,4 +586,4 @@ Cette page de manuel a été traduite par Richard Hitier.
|
||||
.br
|
||||
Cette page de manuel a été mise à jour par David Blanchet.
|
||||
<david.blanchet@free.fr> 2006-04-10.
|
||||
Mise à jour 2012-05-06, Dominique Pellé <dominique.pelle@gmail.com>
|
||||
Mise à jour par Dominique Pellé <dominique.pelle@gmail.com> 2013-05-10
|
||||
|
||||
@@ -66,7 +66,7 @@ position.
|
||||
lines as used for the last Visual operation, but at
|
||||
the current cursor position, multiplied by [count].
|
||||
When the previous Visual operation was on a block both
|
||||
the width and height of the block are multipiled by
|
||||
the width and height of the block are multiplied by
|
||||
[count].
|
||||
When there was no previous Visual operation [count]
|
||||
characters are selected. This is like moving the
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
*windows.txt* For Vim version 7.3. Last change: 2012 Apr 13
|
||||
*windows.txt* For Vim version 7.3. Last change: 2012 Nov 15
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -939,9 +939,9 @@ list of buffers. |unlisted-buffer|
|
||||
:buffers[!] *:buffers* *:ls*
|
||||
:ls[!] Show all buffers. Example:
|
||||
|
||||
1 #h "/test/text" line 1 ~
|
||||
2u "asdf" line 0 ~
|
||||
3 %a+ "version.c" line 1 ~
|
||||
1 #h "/test/text" line 1 ~
|
||||
2u "asdf" line 0 ~
|
||||
3 %a + "version.c" line 1 ~
|
||||
|
||||
When the [!] is included the list will show unlisted buffers
|
||||
(the term "unlisted" is a bit confusing then...).
|
||||
|
||||
@@ -159,7 +159,7 @@ fichier n'est pas adressable, seuls les vides sont autoris
|
||||
combl<EFBFBD>s par des octets nuls.
|
||||
.PP
|
||||
.I xxd \-r
|
||||
ne g<>n<EFBFBD>re aucune erreur lors de l'analyse. Le probl<62>me sont pass<73>s
|
||||
ne g<>n<EFBFBD>re aucune erreur lors de l'analyse. Les probl<62>mes sont pass<73>s
|
||||
silencieusement.
|
||||
.PP
|
||||
Lors de l'<27>dition de la repr<70>sentation hexad<61>cimale, veuillez noter que
|
||||
@@ -307,7 +307,7 @@ Convertir le fichier de l'exemple pr
|
||||
000fffc: 0000 0000 40 ....A
|
||||
.PP
|
||||
Cr<EFBFBD>er un fichier d'un octet, contenant seulement le caract<63>re 'A'.
|
||||
Les nombres apr<70>s '\-r \-s' s'ajoutent au num<75>ros de lignes trouv<75>es dans le
|
||||
Le nombre apr<70>s '\-r \-s' s'ajoute aux num<75>ros de lignes trouv<75>es dans le
|
||||
fichier ; les octets initiaux sont supprim<69>s.
|
||||
.br
|
||||
\fI% echo '010000: 41' | xxd \-r \-s \-0x10000 \> fichier\fR
|
||||
@@ -393,4 +393,4 @@ Modifications mineures par Bram Moolenaar.
|
||||
.SH TRADUCTION
|
||||
Cette page de manuel a <20>t<EFBFBD> traduite par David Blanchet
|
||||
<david.blanchet@free.fr> 2004-12-24.
|
||||
Mise <20> jour 2012-05-06, Dominique Pell<6C> <dominique.pelle@gmail.com>
|
||||
Mise <20> jour 2013-05-10, Dominique Pell<6C> <dominique.pelle@gmail.com>
|
||||
|
||||
@@ -159,7 +159,7 @@ fichier n'est pas adressable, seuls les vides sont autorisés, et ils seront
|
||||
comblés par des octets nuls.
|
||||
.PP
|
||||
.I xxd \-r
|
||||
ne génère aucune erreur lors de l'analyse. Le problème sont passés
|
||||
ne génère aucune erreur lors de l'analyse. Les problèmes sont passés
|
||||
silencieusement.
|
||||
.PP
|
||||
Lors de l'édition de la représentation hexadécimale, veuillez noter que
|
||||
@@ -307,7 +307,7 @@ Convertir le fichier de l'exemple précédent avec la fonctionnalité "autoskip"
|
||||
000fffc: 0000 0000 40 ....A
|
||||
.PP
|
||||
Créer un fichier d'un octet, contenant seulement le caractère 'A'.
|
||||
Les nombres après '\-r \-s' s'ajoutent au numéros de lignes trouvées dans le
|
||||
Le nombre après '\-r \-s' s'ajoute aux numéros de lignes trouvées dans le
|
||||
fichier ; les octets initiaux sont supprimés.
|
||||
.br
|
||||
\fI% echo '010000: 41' | xxd \-r \-s \-0x10000 \> fichier\fR
|
||||
@@ -393,4 +393,4 @@ Modifications mineures par Bram Moolenaar.
|
||||
.SH TRADUCTION
|
||||
Cette page de manuel a été traduite par David Blanchet
|
||||
<david.blanchet@free.fr> 2004-12-24.
|
||||
Mise à jour 2012-05-06, Dominique Pellé <dominique.pelle@gmail.com>
|
||||
Mise à jour 2013-05-10, Dominique Pellé <dominique.pelle@gmail.com>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim support file to detect file types
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2012 Aug 02
|
||||
" Last Change: 2013 Jun 01
|
||||
|
||||
" Listen very carefully, I will say this only once
|
||||
if exists("did_load_filetypes")
|
||||
@@ -128,12 +128,20 @@ au BufNewFile,BufRead .asoundrc,*/usr/share/alsa/alsa.conf,*/etc/asound.conf set
|
||||
" Arc Macro Language
|
||||
au BufNewFile,BufRead *.aml setf aml
|
||||
|
||||
" APT config file
|
||||
au BufNewFile,BufRead apt.conf setf aptconf
|
||||
au BufNewFile,BufRead */.aptitude/config setf aptconf
|
||||
au BufNewFile,BufRead */etc/apt/apt.conf.d/{[-_[:alnum:]]\+,[-_.[:alnum:]]\+.conf} setf aptconf
|
||||
|
||||
" Arch Inventory file
|
||||
au BufNewFile,BufRead .arch-inventory,=tagging-method setf arch
|
||||
|
||||
" ART*Enterprise (formerly ART-IM)
|
||||
au BufNewFile,BufRead *.art setf art
|
||||
|
||||
" AsciiDoc
|
||||
au BufNewFile,BufRead *.asciidoc setf asciidoc
|
||||
|
||||
" ASN.1
|
||||
au BufNewFile,BufRead *.asn,*.asn1 setf asn
|
||||
|
||||
@@ -320,6 +328,9 @@ au BufNewFile,BufRead calendar setf calendar
|
||||
" C#
|
||||
au BufNewFile,BufRead *.cs setf cs
|
||||
|
||||
" CSDL
|
||||
au BufNewFile,BufRead *.csdl setf csdl
|
||||
|
||||
" Cabal
|
||||
au BufNewFile,BufRead *.cabal setf cabal
|
||||
|
||||
@@ -484,6 +495,9 @@ au BufNewFile,BufRead *.prg
|
||||
\ setf clipper |
|
||||
\ endif
|
||||
|
||||
" Clojure
|
||||
au BufNewFile,BufRead *.clj,*.cljs setf clojure
|
||||
|
||||
" Cmake
|
||||
au BufNewFile,BufRead CMakeLists.txt,*.cmake,*.cmake.in setf cmake
|
||||
|
||||
@@ -633,6 +647,9 @@ au BufNewFile,BufRead *.dsl setf dsl
|
||||
" DTD (Document Type Definition for XML)
|
||||
au BufNewFile,BufRead *.dtd setf dtd
|
||||
|
||||
" DTS/DSTI (device tree files)
|
||||
au BufNewFile,BufRead *.dts,*.dtsi setf dts
|
||||
|
||||
" EDIF (*.edf,*.edif,*.edn,*.edo)
|
||||
au BufNewFile,BufRead *.ed\(f\|if\|n\|o\) setf edif
|
||||
|
||||
@@ -735,11 +752,13 @@ au BufNewFile,BufRead *.mo,*.gdmo setf gdmo
|
||||
au BufNewFile,BufRead *.ged,lltxxxxx.txt setf gedcom
|
||||
|
||||
" Git
|
||||
au BufNewFile,BufRead *.git/COMMIT_EDITMSG setf gitcommit
|
||||
au BufNewFile,BufRead *.git/COMMIT_EDITMSG setf gitcommit
|
||||
au BufNewFile,BufRead *.git/MERGE_MSG setf gitcommit
|
||||
au BufNewFile,BufRead *.git/config,.gitconfig,.gitmodules setf gitconfig
|
||||
au BufNewFile,BufRead *.git/modules/**/COMMIT_EDITMSG setf gitcommit
|
||||
au BufNewFile,BufRead *.git/modules/**/config setf gitconfig
|
||||
au BufNewFile,BufRead git-rebase-todo setf gitrebase
|
||||
au BufNewFile,BufRead *.git/modules/**/config setf gitconfig
|
||||
au BufNewFile,BufRead */.config/git/config setf gitconfig
|
||||
au BufNewFile,BufRead git-rebase-todo setf gitrebase
|
||||
au BufNewFile,BufRead .msg.[0-9]*
|
||||
\ if getline(1) =~ '^From.*# This line is ignored.$' |
|
||||
\ setf gitsendemail |
|
||||
@@ -766,7 +785,7 @@ au BufNewFile,BufRead gnashrc,.gnashrc,gnashpluginrc,.gnashpluginrc setf gnash
|
||||
" Gitolite
|
||||
au BufNewFile,BufRead gitolite.conf setf gitolite
|
||||
au BufNewFile,BufRead */gitolite-admin/conf/* call s:StarSetf('gitolite')
|
||||
au BufNewFile,BufRead {,.}gitolite.rc,example.gitolite.rc setf perl
|
||||
au BufNewFile,BufRead {,.}gitolite.rc,example.gitolite.rc setf perl
|
||||
|
||||
" Gnuplot scripts
|
||||
au BufNewFile,BufRead *.gpi setf gnuplot
|
||||
@@ -1067,6 +1086,9 @@ au BufNewFile,BufRead *[mM]akefile,*.mk,*.mak,*.dsp setf make
|
||||
" MakeIndex
|
||||
au BufNewFile,BufRead *.ist,*.mst setf ist
|
||||
|
||||
" Mallard
|
||||
au BufNewFile,BufRead *.page setf mallard
|
||||
|
||||
" Manpage
|
||||
au BufNewFile,BufRead *.man setf man
|
||||
|
||||
@@ -1080,7 +1102,7 @@ au BufNewFile,BufRead *.mv,*.mpl,*.mws setf maple
|
||||
au BufNewFile,BufRead *.map setf map
|
||||
|
||||
" Markdown
|
||||
au BufNewFile,BufRead *.markdown,*.mdown,*.mkd,*.mkdn,README.md setf markdown
|
||||
au BufNewFile,BufRead *.markdown,*.mdown,*.mkd,*.mkdn,*.mdwn,README.md setf markdown
|
||||
|
||||
" Mason
|
||||
au BufNewFile,BufRead *.mason,*.mhtml setf mason
|
||||
@@ -1558,7 +1580,7 @@ au BufNewFile,BufRead *.reg
|
||||
au BufNewFile,BufRead *.rib setf rib
|
||||
|
||||
" Rexx
|
||||
au BufNewFile,BufRead *.rexx,*.rex,*.jrexx,*.rxj,*.orx setf rexx
|
||||
au BufNewFile,BufRead *.rex,*.orx,*.rxo,*.rxj,*.jrexx,*.rexxj,*.rexx,*.testGroup,*.testUnit setf rexx
|
||||
|
||||
" R (Splus)
|
||||
if has("fname_case")
|
||||
@@ -1626,6 +1648,9 @@ au BufNewFile,BufRead resolv.conf setf resolv
|
||||
" Relax NG Compact
|
||||
au BufNewFile,BufRead *.rnc setf rnc
|
||||
|
||||
" Relax NG XML
|
||||
au BufNewFile,BufRead *.rng setf rng
|
||||
|
||||
" RPL/2
|
||||
au BufNewFile,BufRead *.rpl setf rpl
|
||||
|
||||
@@ -1737,7 +1762,8 @@ au BufNewFile,BufRead *.sgm,*.sgml
|
||||
\ if getline(1).getline(2).getline(3).getline(4).getline(5) =~? 'linuxdoc' |
|
||||
\ setf sgmllnx |
|
||||
\ elseif getline(1) =~ '<!DOCTYPE.*DocBook' || getline(2) =~ '<!DOCTYPE.*DocBook' |
|
||||
\ let b:docbk_type="sgml" |
|
||||
\ let b:docbk_type = "sgml" |
|
||||
\ let b:docbk_ver = 4 |
|
||||
\ setf docbk |
|
||||
\ else |
|
||||
\ setf sgml |
|
||||
@@ -1772,6 +1798,10 @@ func! SetFileTypeSH(name)
|
||||
" Some .sh scripts contain #!/bin/tcsh.
|
||||
call SetFileTypeShell("tcsh")
|
||||
return
|
||||
elseif a:name =~ '\<zsh\>'
|
||||
" Some .sh scripts contain #!/bin/zsh.
|
||||
call SetFileTypeShell("zsh")
|
||||
return
|
||||
elseif a:name =~ '\<ksh\>'
|
||||
let b:is_kornshell = 1
|
||||
if exists("b:is_bash")
|
||||
@@ -1872,6 +1902,8 @@ au BufNewFile,BufRead *.st setf st
|
||||
au BufNewFile,BufRead *.cls
|
||||
\ if getline(1) =~ '^%' |
|
||||
\ setf tex |
|
||||
\ elseif getline(1)[0] == '#' && getline(1) =~ 'rexx' |
|
||||
\ setf rexx |
|
||||
\ else |
|
||||
\ setf st |
|
||||
\ endif
|
||||
@@ -2169,8 +2201,12 @@ au BufNewFile,BufRead *.uc setf uc
|
||||
au BufNewFile,BufRead */etc/updatedb.conf setf updatedb
|
||||
|
||||
" Upstart (init(8)) config files
|
||||
au BufNewFile,BufRead */etc/init/*.conf,*/.init/*.conf setf upstart
|
||||
au BufNewFile,BufRead */etc/init/*.override,*/.init/*.override setf upstart
|
||||
au BufNewFile,BufRead */usr/share/upstart/*.conf setf upstart
|
||||
au BufNewFile,BufRead */usr/share/upstart/*.override setf upstart
|
||||
au BufNewFile,BufRead */etc/init/*.conf,*/etc/init/*.override setf upstart
|
||||
au BufNewFile,BufRead */.init/*.conf,*/.init/*.override setf upstart
|
||||
au BufNewFile,BufRead */.config/upstart/*.conf setf upstart
|
||||
au BufNewFile,BufRead */.config/upstart/*.override setf upstart
|
||||
|
||||
" Vera
|
||||
au BufNewFile,BufRead *.vr,*.vri,*.vrh setf vera
|
||||
@@ -2293,8 +2329,16 @@ func! s:FTxml()
|
||||
let n = 1
|
||||
while n < 100 && n < line("$")
|
||||
let line = getline(n)
|
||||
if line =~ '<!DOCTYPE.*DocBook'
|
||||
" DocBook 4 or DocBook 5.
|
||||
let is_docbook4 = line =~ '<!DOCTYPE.*DocBook'
|
||||
let is_docbook5 = line =~ ' xmlns="http://docbook.org/ns/docbook"'
|
||||
if is_docbook4 || is_docbook5
|
||||
let b:docbk_type = "xml"
|
||||
if is_docbook5
|
||||
let b:docbk_ver = 5
|
||||
else
|
||||
let b:docbk_ver = 4
|
||||
endif
|
||||
setf docbk
|
||||
return
|
||||
endif
|
||||
@@ -2372,10 +2416,10 @@ endfunc
|
||||
au BufNewFile,BufRead *.yaml,*.yml setf yaml
|
||||
|
||||
" yum conf (close enough to dosini)
|
||||
au BufNewFile,BufRead */etc/yum.conf setf dosini
|
||||
au BufNewFile,BufRead */etc/yum.conf setf dosini
|
||||
|
||||
" Zimbu
|
||||
au BufNewFile,BufRead *.zu setf zimbu
|
||||
au BufNewFile,BufRead *.zu setf zimbu
|
||||
|
||||
" Zope
|
||||
" dtml (zope dynamic template markup language), pt (zope page template),
|
||||
@@ -2520,6 +2564,20 @@ au BufNewFile,BufRead *termcap*
|
||||
\| let b:ptcap_type = "term" | call s:StarSetf('ptcap')
|
||||
\|endif
|
||||
|
||||
" ReDIF
|
||||
" Only used when the .rdf file was not detected to be XML.
|
||||
au BufRead,BufNewFile *.rdf call s:Redif()
|
||||
func! s:Redif()
|
||||
let lnum = 1
|
||||
while lnum <= 5 && lnum < line('$')
|
||||
if getline(lnum) =~ "^\ctemplate-type:"
|
||||
setf redif
|
||||
return
|
||||
endif
|
||||
let lnum = lnum + 1
|
||||
endwhile
|
||||
endfunc
|
||||
|
||||
" Remind
|
||||
au BufNewFile,BufRead .reminders* call s:StarSetf('remind')
|
||||
|
||||
@@ -2548,7 +2606,7 @@ au BufNewFile,BufRead *xmodmap* call s:StarSetf('xmodmap')
|
||||
au BufNewFile,BufRead */etc/xinetd.d/* call s:StarSetf('xinetd')
|
||||
|
||||
" yum conf (close enough to dosini)
|
||||
au BufNewFile,BufRead */etc/yum.repos.d/* call s:StarSetf('dosini')
|
||||
au BufNewFile,BufRead */etc/yum.repos.d/* call s:StarSetf('dosini')
|
||||
|
||||
" Z-Shell script
|
||||
au BufNewFile,BufRead zsh*,zlog* call s:StarSetf('zsh')
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Aap recipe
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2003 Nov 04
|
||||
" Last Change: 2013 Apr 05
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -19,7 +19,7 @@ let b:undo_ftplugin = "setl fo< com< et<"
|
||||
setlocal fo-=t fo+=croql
|
||||
|
||||
" Set 'comments' to format dashed lists in comments.
|
||||
setlocal comments=s:#\ -,m:#\ \,e:#,n:#,fb:-
|
||||
setlocal comments=s:#\ -,m:#\ \ ,e:#,n:#,fb:-
|
||||
|
||||
" Expand tabs to spaces to avoid trouble.
|
||||
setlocal expandtab
|
||||
|
||||
29
runtime/ftplugin/abap.vim
Normal file
29
runtime/ftplugin/abap.vim
Normal file
@@ -0,0 +1,29 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: ABAP
|
||||
" Author: Steven Oliver <oliver.steven@gmail.com>
|
||||
" Copyright: Copyright (c) 2013 Steven Oliver
|
||||
" License: You may redistribute this under the same terms as Vim itself
|
||||
" --------------------------------------------------------------------------
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if (exists("b:did_ftplugin"))
|
||||
finish
|
||||
endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let s:cpo_save = &cpo
|
||||
set cpo&vim
|
||||
|
||||
setlocal softtabstop=2 shiftwidth=2
|
||||
setlocal suffixesadd=.abap
|
||||
|
||||
" Windows allows you to filter the open file dialog
|
||||
if has("gui_win32") && !exists("b:browsefilter")
|
||||
let b:browsefilter = "ABAP Source Files (*.abap)\t*.abap\n" .
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
endif
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
unlet s:cpo_save
|
||||
|
||||
" vim: set sw=4 sts=4 et tw=80 :
|
||||
@@ -7,7 +7,7 @@
|
||||
" Neil Bird <neil@fnxweb.com>
|
||||
" $Author: krischik $
|
||||
" $Date: 2008-07-08 16:29:01 +0200 (Di, 08 Jul 2008) $
|
||||
" Version: 4.6
|
||||
" Version: 4.6 with patch from David Bürgin
|
||||
" $Revision: 887 $
|
||||
" $HeadURL: https://gnuada.svn.sourceforge.net/svnroot/gnuada/trunk/tools/vim/ftplugin/ada.vim $
|
||||
" History: 24.05.2006 MK Unified Headers
|
||||
@@ -42,7 +42,7 @@ set cpoptions-=C
|
||||
|
||||
" Section: Comments {{{1
|
||||
"
|
||||
setlocal comments=O:--,:--\ \
|
||||
setlocal comments=O:--,:--\ \
|
||||
setlocal commentstring=--\ \ %s
|
||||
setlocal complete=.,w,b,u,t,i
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: generic Changelog file
|
||||
" Maintainer: Nikolai Weibull <now@bitwi.se>
|
||||
" Latest Revision: 2011-05-02
|
||||
" Latest Revision: 2012-08-23
|
||||
" Variables:
|
||||
" g:changelog_timeformat (deprecated: use g:changelog_dateformat instead) -
|
||||
" description: the timeformat used in ChangeLog entries.
|
||||
@@ -106,10 +106,10 @@ if &filetype == 'changelog'
|
||||
|
||||
function! s:passwd_field(line, field)
|
||||
let fields = split(a:line, ':', 1)
|
||||
if len(fields) < field
|
||||
if len(fields) < a:field
|
||||
return ""
|
||||
endif
|
||||
return fields[field - 1]
|
||||
return fields[a:field - 1]
|
||||
endfunction
|
||||
|
||||
function! s:capitalize(word)
|
||||
|
||||
79
runtime/ftplugin/clojure.vim
Normal file
79
runtime/ftplugin/clojure.vim
Normal file
@@ -0,0 +1,79 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Clojure
|
||||
" Author: Meikel Brandmeyer <mb@kotka.de>
|
||||
"
|
||||
" Maintainer: Sung Pae <self@sungpae.com>
|
||||
" URL: https://github.com/guns/vim-clojure-static
|
||||
" License: Same as Vim
|
||||
" Last Change: 30 January 2013
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let s:cpo_save = &cpo
|
||||
set cpo&vim
|
||||
|
||||
let b:undo_ftplugin = 'setlocal define< formatoptions< comments< commentstring<'
|
||||
|
||||
" There will be false positives, but this is better than missing the whole set
|
||||
" of user-defined def* definitions.
|
||||
setlocal define=\\v[(/]def(ault)@!\\S*
|
||||
|
||||
" Remove 't' from 'formatoptions' to avoid auto-wrapping code. The '+=croql'
|
||||
" is standard ftplugin boilerplate, although it is arguably intrusive.
|
||||
setlocal formatoptions-=t formatoptions+=croql
|
||||
|
||||
" Lisp comments are routinely nested (e.g. ;;; SECTION HEADING)
|
||||
setlocal comments=n:;
|
||||
setlocal commentstring=;\ %s
|
||||
|
||||
" Provide insert mode completions for special forms and clojure.core. As
|
||||
" 'omnifunc' is set by popular Clojure REPL client plugins, we also set
|
||||
" 'completefunc' so that the user has some form of completion available when
|
||||
" 'omnifunc' is set and no REPL connection exists.
|
||||
for s:setting in ['omnifunc', 'completefunc']
|
||||
if exists('&' . s:setting) && empty(eval('&' . s:setting))
|
||||
execute 'setlocal ' . s:setting . '=clojurecomplete#Complete'
|
||||
let b:undo_ftplugin .= ' | setlocal ' . s:setting . '<'
|
||||
endif
|
||||
endfor
|
||||
|
||||
" Take all directories of the CLOJURE_SOURCE_DIRS environment variable
|
||||
" and add them to the path option.
|
||||
"
|
||||
" This is a legacy option for VimClojure users.
|
||||
if exists('$CLOJURE_SOURCE_DIRS')
|
||||
for s:dir in split($CLOJURE_SOURCE_DIRS, (has("win32") || has("win64")) ? ';' : ':')
|
||||
let s:dir = fnameescape(s:dir)
|
||||
" Whitespace escaping for Windows
|
||||
let s:dir = substitute(s:dir, '\', '\\\\', 'g')
|
||||
let s:dir = substitute(s:dir, '\ ', '\\ ', 'g')
|
||||
execute "setlocal path+=" . s:dir . "/**"
|
||||
endfor
|
||||
let b:undo_ftplugin .= ' | setlocal path<'
|
||||
endif
|
||||
|
||||
" Skip brackets in ignored syntax regions when using the % command
|
||||
if exists('loaded_matchit')
|
||||
let b:match_words = &matchpairs
|
||||
let b:match_skip = 's:comment\|string\|regex\|character'
|
||||
let b:undo_ftplugin .= ' | unlet! b:match_words b:match_skip'
|
||||
endif
|
||||
|
||||
" Win32 can filter files in the browse dialog
|
||||
if has("gui_win32") && !exists("b:browsefilter")
|
||||
let b:browsefilter = "Clojure Source Files (*.clj)\t*.clj\n" .
|
||||
\ "ClojureScript Source Files (*.cljs)\t*.cljs\n" .
|
||||
\ "Java Source Files (*.java)\t*.java\n" .
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
let b:undo_ftplugin .= ' | unlet! b:browsefilter'
|
||||
endif
|
||||
|
||||
let &cpo = s:cpo_save
|
||||
|
||||
unlet! s:cpo_save s:setting s:dir
|
||||
|
||||
" vim:sts=4 sw=4 et:
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin
|
||||
" Language: Cucumber
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Last Change: 2010 Aug 09
|
||||
" Last Change: 2013 Jun 01
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if (exists("b:did_ftplugin"))
|
||||
@@ -9,6 +9,9 @@ if (exists("b:did_ftplugin"))
|
||||
endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let s:keepcpo= &cpo
|
||||
set cpo&vim
|
||||
|
||||
setlocal formatoptions-=t formatoptions+=croql
|
||||
setlocal comments=:# commentstring=#\ %s
|
||||
setlocal omnifunc=CucumberComplete
|
||||
@@ -18,11 +21,27 @@ let b:undo_ftplugin = "setl fo< com< cms< ofu<"
|
||||
let b:cucumber_root = expand('%:p:h:s?.*[\/]\%(features\|stories\)\zs[\/].*??')
|
||||
|
||||
if !exists("g:no_plugin_maps") && !exists("g:no_cucumber_maps")
|
||||
nmap <silent><buffer> <C-]> :<C-U>exe <SID>jump('edit',v:count)<CR>
|
||||
nmap <silent><buffer> <C-W>] :<C-U>exe <SID>jump('split',v:count)<CR>
|
||||
nmap <silent><buffer> <C-W><C-]> :<C-U>exe <SID>jump('split',v:count)<CR>
|
||||
nmap <silent><buffer> <C-W>} :<C-U>exe <SID>jump('pedit',v:count)<CR>
|
||||
let b:undo_ftplugin .= "| sil! iunmap! <C-]>| sil! iunmap! <C-W>]| sil! iunmap! <C-W><C-]>| sil! iunmap! <C-W>}"
|
||||
nnoremap <silent><buffer> <C-]> :<C-U>exe <SID>jump('edit',v:count)<CR>
|
||||
nnoremap <silent><buffer> [<C-D> :<C-U>exe <SID>jump('edit',v:count)<CR>
|
||||
nnoremap <silent><buffer> ]<C-D> :<C-U>exe <SID>jump('edit',v:count)<CR>
|
||||
nnoremap <silent><buffer> <C-W>] :<C-U>exe <SID>jump('split',v:count)<CR>
|
||||
nnoremap <silent><buffer> <C-W><C-]> :<C-U>exe <SID>jump('split',v:count)<CR>
|
||||
nnoremap <silent><buffer> <C-W>d :<C-U>exe <SID>jump('split',v:count)<CR>
|
||||
nnoremap <silent><buffer> <C-W><C-D> :<C-U>exe <SID>jump('split',v:count)<CR>
|
||||
nnoremap <silent><buffer> <C-W>} :<C-U>exe <SID>jump('pedit',v:count)<CR>
|
||||
nnoremap <silent><buffer> [d :<C-U>exe <SID>jump('pedit',v:count)<CR>
|
||||
nnoremap <silent><buffer> ]d :<C-U>exe <SID>jump('pedit',v:count)<CR>
|
||||
let b:undo_ftplugin .=
|
||||
\ "|sil! nunmap <buffer> <C-]>" .
|
||||
\ "|sil! nunmap <buffer> [<C-D>" .
|
||||
\ "|sil! nunmap <buffer> ]<C-D>" .
|
||||
\ "|sil! nunmap <buffer> <C-W>]" .
|
||||
\ "|sil! nunmap <buffer> <C-W><C-]>" .
|
||||
\ "|sil! nunmap <buffer> <C-W>d" .
|
||||
\ "|sil! nunmap <buffer> <C-W><C-D>" .
|
||||
\ "|sil! nunmap <buffer> <C-W>}" .
|
||||
\ "|sil! nunmap <buffer> [d" .
|
||||
\ "|sil! nunmap <buffer> ]d"
|
||||
endif
|
||||
|
||||
function! s:jump(command,count)
|
||||
@@ -38,7 +57,7 @@ function! s:jump(command,count)
|
||||
endfunction
|
||||
|
||||
function! s:allsteps()
|
||||
let step_pattern = '\C^\s*\K\k*\>\s*\zs\S.\{-\}\ze\s*\%(do\|{\)\s*\%(|[^|]*|\s*\)\=\%($\|#\)'
|
||||
let step_pattern = '\C^\s*\K\k*\>\s*(\=\s*\zs\S.\{-\}\ze\s*)\=\s*\%(do\|{\)\s*\%(|[^|]*|\s*\)\=\%($\|#\)'
|
||||
let steps = []
|
||||
for file in split(glob(b:cucumber_root.'/**/*.rb'),"\n")
|
||||
let lines = readfile(file)
|
||||
@@ -55,7 +74,7 @@ function! s:allsteps()
|
||||
endfunction
|
||||
|
||||
function! s:steps(lnum)
|
||||
let c = indent(a:lnum) + 1
|
||||
let c = match(getline(a:lnum), '\S') + 1
|
||||
while synIDattr(synID(a:lnum,c,1),'name') !~# '^$\|Region$'
|
||||
let c = c + 1
|
||||
endwhile
|
||||
@@ -129,4 +148,7 @@ function! CucumberComplete(findstart,base) abort
|
||||
return sort(steps)
|
||||
endfunction
|
||||
|
||||
let &cpo = s:keepcpo
|
||||
unlet s:keepcpo
|
||||
|
||||
" vim:set sts=2 sw=2:
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
" Vim filetype plugin
|
||||
" Language: generic git output
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if (exists("b:did_ftplugin"))
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin
|
||||
" Language: git commit file
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Last Change: 2012 April 7
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if (exists("b:did_ftplugin"))
|
||||
@@ -11,9 +11,9 @@ endif
|
||||
runtime! ftplugin/git.vim
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
setlocal nomodeline
|
||||
setlocal nomodeline tabstop=8 formatoptions-=croq formatoptions+=tl
|
||||
|
||||
let b:undo_ftplugin = 'setl modeline<'
|
||||
let b:undo_ftplugin = 'setl modeline< tabstop< formatoptions<'
|
||||
|
||||
if &textwidth == 0
|
||||
" make sure that log messages play nice with git-log on standard terminals
|
||||
|
||||
32
runtime/ftplugin/gprof.vim
Normal file
32
runtime/ftplugin/gprof.vim
Normal file
@@ -0,0 +1,32 @@
|
||||
" Language: gprof
|
||||
" Maintainer: Dominique Pelle <dominique.pelle@gmail.com>
|
||||
" Last Change: 2012 May 20
|
||||
|
||||
" When cursor is on one line of the gprof call graph,
|
||||
" calling this function jumps to this function in the call graph.
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
endif
|
||||
let b:did_ftplugin=1
|
||||
|
||||
fun! <SID>GprofJumpToFunctionIndex()
|
||||
let l:line = getline('.')
|
||||
if l:line =~ '[\d\+\]$'
|
||||
" We're in a line in the call graph.
|
||||
norm $y%
|
||||
call search('^' . escape(@", '[]'), 'sw')
|
||||
norm zz
|
||||
elseif l:line =~ '^\(\s\+[0-9\.]\+\)\{3}\s\+'
|
||||
" We're in line in the flat profile.
|
||||
norm 55|y$
|
||||
call search('^\[\d\+\].*\d\s\+' . escape(@", '[]*.'), 'sW')
|
||||
norm zz
|
||||
endif
|
||||
endfun
|
||||
|
||||
" Pressing <C-]> on a line in the gprof flat profile or in
|
||||
" the call graph, jumps to the corresponding function inside
|
||||
" the flat profile.
|
||||
map <silent> <C-]> :call <SID>GprofJumpToFunctionIndex()<CR>
|
||||
|
||||
" vim:sw=2 fdm=indent
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin
|
||||
" Language: Haml
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Last Change: 2012 Mar 11
|
||||
" Language: Haml
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Last Change: 2013 Jun 01
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -18,6 +18,7 @@ let s:match_words = ""
|
||||
|
||||
runtime! ftplugin/html.vim ftplugin/html_*.vim ftplugin/html/*.vim
|
||||
unlet! b:did_ftplugin
|
||||
set matchpairs-=<:>
|
||||
|
||||
" Override our defaults if these were set by an included ftplugin.
|
||||
if exists("b:undo_ftplugin")
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
" URL: http://sites.google.com/site/khorser/opensource/vim
|
||||
" Original author: Dorai Sitaram <ds26@gte.com>
|
||||
" Original URL: http://www.ccs.neu.edu/~dorai/vimplugins/vimplugins.html
|
||||
" Last Change: Mar 5, 2012
|
||||
" Last Change: Feb 12, 2013
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -19,10 +19,11 @@ setl define=^\\s*(def\\k*
|
||||
setl formatoptions-=t
|
||||
setl iskeyword+=+,-,*,/,%,<,=,>,:,$,?,!,@-@,94
|
||||
setl lisp
|
||||
setl commentstring=;%s
|
||||
|
||||
" make comments behaviour like in c.vim
|
||||
" e.g. insertion of ;;; and ;; on normal "O" or "o" when staying in comment
|
||||
setl comments^=:;;;,:;;,sr:#\|,mb:\|,ex:\|#
|
||||
setl formatoptions+=croql
|
||||
|
||||
let b:undo_ftplugin = "setlocal comments< define< formatoptions< iskeyword< lisp<"
|
||||
let b:undo_ftplugin = "setlocal comments< define< formatoptions< iskeyword< lisp< commentstring<"
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Mail
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2009 Jun 03
|
||||
" Last Change: 2012 Nov 20
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -9,7 +9,7 @@ if exists("b:did_ftplugin")
|
||||
endif
|
||||
let b:did_ftplugin = 1
|
||||
|
||||
let b:undo_ftplugin = "setl modeline< tw< fo<"
|
||||
let b:undo_ftplugin = "setl modeline< tw< fo< comments<"
|
||||
|
||||
" Don't use modelines in e-mail messages, avoid trojan horses and nasty
|
||||
" "jokes" (e.g., setting 'textwidth' to 5).
|
||||
@@ -23,6 +23,9 @@ endif
|
||||
" Set 'formatoptions' to break text lines and keep the comment leader ">".
|
||||
setlocal fo+=tcql
|
||||
|
||||
" Add n:> to 'comments, in case it was removed elsewhere
|
||||
setlocal comments+=n:>
|
||||
|
||||
" Add mappings, unless the user doesn't want this.
|
||||
if !exists("no_plugin_maps") && !exists("no_mail_maps")
|
||||
" Quote text by inserting "> "
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Make
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2006 Jun 17
|
||||
" Last Change: 2013 Apr 22
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -26,3 +26,8 @@ setlocal commentstring=#\ %s
|
||||
|
||||
" Including files.
|
||||
let &l:include = '^\s*include'
|
||||
|
||||
" For matchit.vim, suggested by Albert Netymk.
|
||||
if exists("loaded_matchit")
|
||||
let b:match_words = '\<if\(n\)\=\(eq\|def\)\>:\<else\>:\<endif\>,\<define\>:\<endef\>'
|
||||
endif
|
||||
|
||||
@@ -1,17 +1,16 @@
|
||||
" Vim filetype plugin
|
||||
" Language: Markdown
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Last Change: 2011 Dec 14
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
if exists("b:did_ftplugin")
|
||||
finish
|
||||
endif
|
||||
|
||||
runtime! ftplugin/html.vim ftplugin/html_*.vim ftplugin/html/*.vim
|
||||
unlet! b:did_ftplugin
|
||||
|
||||
setlocal comments=fb:*,fb:-,fb:+,n:> commentstring=>\ %s
|
||||
setlocal formatoptions+=tcqln
|
||||
setlocal formatoptions+=tcqln formatoptions-=r formatoptions-=o
|
||||
setlocal formatlistpat=^\\s*\\d\\+\\.\\s\\+\\\|^[-*+]\\s\\+
|
||||
|
||||
if exists('b:undo_ftplugin')
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Perl
|
||||
" Maintainer: Andy Lester <andy@petdance.com>
|
||||
" URL: http://github.com/petdance/vim-perl
|
||||
" Last Change: 2012 Mar 11
|
||||
" Language: Perl
|
||||
" Maintainer: vim-perl <vim-perl@googlegroups.com>
|
||||
" Homepage: http://github.com/vim-perl/vim-perl
|
||||
" Bugs/requests: http://github.com/vim-perl/vim-perl/issues
|
||||
" Last Change: 2013-05-11
|
||||
|
||||
if exists("b:did_ftplugin") | finish | endif
|
||||
let b:did_ftplugin = 1
|
||||
@@ -12,7 +13,8 @@ let b:did_ftplugin = 1
|
||||
let s:save_cpo = &cpo
|
||||
set cpo-=C
|
||||
|
||||
setlocal formatoptions+=crq
|
||||
setlocal formatoptions-=t
|
||||
setlocal formatoptions+=crqol
|
||||
setlocal keywordprg=perldoc\ -f
|
||||
|
||||
setlocal comments=:#
|
||||
@@ -29,7 +31,7 @@ endif
|
||||
" Provided by Ned Konz <ned at bike-nomad dot com>
|
||||
"---------------------------------------------
|
||||
setlocal include=\\<\\(use\\\|require\\)\\>
|
||||
setlocal includeexpr=substitute(substitute(v:fname,'::','/','g'),'$','.pm','')
|
||||
setlocal includeexpr=substitute(substitute(substitute(v:fname,'::','/','g'),'->\*','',''),'$','.pm','')
|
||||
setlocal define=[^A-Za-z_]
|
||||
|
||||
" The following line changes a global variable but is necessary to make
|
||||
@@ -38,7 +40,7 @@ setlocal define=[^A-Za-z_]
|
||||
" problem for you, add an after/ftplugin/perl.vim file that contains
|
||||
" set isfname-=:
|
||||
set isfname+=:
|
||||
"setlocal iskeyword=48-57,_,A-Z,a-z,:
|
||||
set iskeyword+=:
|
||||
|
||||
" Set this once, globally.
|
||||
if !exists("perlpath")
|
||||
@@ -60,13 +62,27 @@ if !exists("perlpath")
|
||||
endif
|
||||
endif
|
||||
|
||||
let &l:path=perlpath
|
||||
" Append perlpath to the existing path value, if it is set. Since we don't
|
||||
" use += to do it because of the commas in perlpath, we have to handle the
|
||||
" global / local settings, too.
|
||||
if &l:path == ""
|
||||
if &g:path == ""
|
||||
let &l:path=perlpath
|
||||
else
|
||||
let &l:path=&g:path.",".perlpath
|
||||
endif
|
||||
else
|
||||
let &l:path=&l:path.",".perlpath
|
||||
endif
|
||||
"---------------------------------------------
|
||||
|
||||
" Undo the stuff we changed.
|
||||
let b:undo_ftplugin = "setlocal fo< com< cms< inc< inex< def< isf< kp<" .
|
||||
let b:undo_ftplugin = "setlocal fo< com< cms< inc< inex< def< isf< kp< path<" .
|
||||
\ " | unlet! b:browsefilter"
|
||||
|
||||
" proper matching for matchit plugin
|
||||
let b:match_skip = 's:comment\|string\|perlQQ\|perlShellCommand\|perlHereDoc\|perlSubstitution\|perlTranslation\|perlMatch\|perlFormatField'
|
||||
|
||||
" Restore the saved compatibility options.
|
||||
let &cpo = s:save_cpo
|
||||
unlet s:save_cpo
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Perl 6
|
||||
" Maintainer: Andy Lester <andy@petdance.com>
|
||||
" URL: http://github.com/petdance/vim-perl/tree/master
|
||||
" Last Change: 2012 Mar 11
|
||||
" Contributors: Hinrik Örn Sigurðsson <hinrik.sig@gmail.com>
|
||||
" Language: Perl 6
|
||||
" Maintainer: vim-perl <vim-perl@googlegroups.com>
|
||||
" Homepage: http://github.com/vim-perl/vim-perl
|
||||
" Bugs/requests: http://github.com/vim-perl/vim-perl/issues
|
||||
" Last Change: 2013-05-11
|
||||
" Contributors: Hinrik Örn Sigurðsson <hinrik.sig@gmail.com>
|
||||
"
|
||||
" Based on ftplugin/perl.vim by Dan Sharp <dwsharp at hotmail dot com>
|
||||
|
||||
@@ -15,16 +16,19 @@ let b:did_ftplugin = 1
|
||||
let s:save_cpo = &cpo
|
||||
set cpo-=C
|
||||
|
||||
setlocal formatoptions+=crq
|
||||
setlocal formatoptions-=t
|
||||
setlocal formatoptions+=crqol
|
||||
setlocal keywordprg=p6doc
|
||||
|
||||
setlocal comments=:#
|
||||
setlocal commentstring=#%s
|
||||
|
||||
" Change the browse dialog on Win32 to show mainly Perl-related files
|
||||
if has("gui_win32")
|
||||
let b:browsefilter = "Perl Source Files (*.pl)\t*.pl\n" .
|
||||
\ "Perl Modules (*.pm)\t*.pm\n" .
|
||||
\ "Perl Documentation Files (*.pod)\t*.pod\n" .
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
\ "Perl Modules (*.pm)\t*.pm\n" .
|
||||
\ "Perl Documentation Files (*.pod)\t*.pod\n" .
|
||||
\ "All Files (*.*)\t*.*\n"
|
||||
endif
|
||||
|
||||
" Provided by Ned Konz <ned at bike-nomad dot com>
|
||||
@@ -39,10 +43,34 @@ setlocal define=[^A-Za-z_]
|
||||
" after/ftplugin/perl6.vim file that contains
|
||||
" set isfname-=:
|
||||
set isfname+=:
|
||||
setlocal iskeyword=48-57,_,A-Z,a-z,:,-
|
||||
|
||||
" Set this once, globally.
|
||||
if !exists("perlpath")
|
||||
if executable("perl6")
|
||||
try
|
||||
if &shellxquote != '"'
|
||||
let perlpath = system('perl6 -e "@*INC.join(q/,/).say"')
|
||||
else
|
||||
let perlpath = system("perl6 -e '@*INC.join(q/,/).say'")
|
||||
endif
|
||||
let perlpath = substitute(perlpath,',.$',',,','')
|
||||
catch /E145:/
|
||||
let perlpath = ".,,"
|
||||
endtry
|
||||
else
|
||||
" If we can't call perl to get its path, just default to using the
|
||||
" current directory and the directory of the current file.
|
||||
let perlpath = ".,,"
|
||||
endif
|
||||
endif
|
||||
|
||||
let &l:path=perlpath
|
||||
"---------------------------------------------
|
||||
|
||||
" Undo the stuff we changed.
|
||||
let b:undo_ftplugin = "setlocal fo< com< cms< inc< inex< def< isk<" .
|
||||
\ " | unlet! b:browsefilter"
|
||||
\ " | unlet! b:browsefilter"
|
||||
|
||||
" Restore the saved compatibility options.
|
||||
let &cpo = s:save_cpo
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
" URL: http://sites.google.com/site/khorser/opensource/vim
|
||||
" Original author: Dorai Sitaram <ds26@gte.com>
|
||||
" Original URL: http://www.ccs.neu.edu/~dorai/vimplugins/vimplugins.html
|
||||
" Last Change: Mar 5, 2012
|
||||
" Last Change: Feb 12, 2013
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -20,6 +20,7 @@ setl define=^\\s*(def\\k*
|
||||
setl formatoptions-=t
|
||||
setl iskeyword+=+,-,*,/,%,<,=,>,:,$,?,!,@-@,94
|
||||
setl lisp
|
||||
setl commentstring=;%s
|
||||
|
||||
" make comments behaviour like in c.vim
|
||||
" e.g. insertion of ;;; and ;; on normal "O" or "o" when staying in comment
|
||||
@@ -44,4 +45,4 @@ if exists("b:is_chicken") || exists("is_chicken")
|
||||
setl lispwords+=cond-expand,and-let*,foreign-lambda,foreign-lambda*
|
||||
endif
|
||||
|
||||
let b:undo_ftplugin = "setlocal comments< define< formatoptions< iskeyword< lispwords< lisp<"
|
||||
let b:undo_ftplugin = "setlocal comments< define< formatoptions< iskeyword< lispwords< lisp< commentstring<"
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
" SQL filetype plugin file
|
||||
" Language: SQL (Common for Oracle, Microsoft SQL Server, Sybase)
|
||||
" Version: 8.0
|
||||
" Version: 11.0
|
||||
" Maintainer: David Fishburn <dfishburn dot vim at gmail dot com>
|
||||
" Last Change: 2012 May 18
|
||||
" Last Change: 2013 May 13
|
||||
" Download: http://vim.sourceforge.net/script.php?script_id=454
|
||||
|
||||
" For more details please use:
|
||||
@@ -30,34 +30,52 @@
|
||||
" To change the default dialect, add the following to your vimrc:
|
||||
" let g:sql_type_default = 'sqlanywhere'
|
||||
"
|
||||
" This file also creates a command, SQLGetType, which allows you to
|
||||
" This file also creates a command, SQLGetType, which allows you to
|
||||
" determine what the current dialect is in use.
|
||||
" :SQLGetType
|
||||
"
|
||||
" History
|
||||
"
|
||||
" Version 11.0 (May 2013)
|
||||
"
|
||||
" NF: Updated to use SyntaxComplete's new regex support for syntax groups.
|
||||
"
|
||||
" Version 10.0 (Dec 2012)
|
||||
"
|
||||
" NF: Changed all maps to use noremap instead of must map
|
||||
" NF: Changed all visual maps to use xnoremap instead of vnoremap as they
|
||||
" should only be used in visual mode and not select mode.
|
||||
" BF: Most of the maps were using doubled up backslashes before they were
|
||||
" changed to using the search() function, which meant they no longer
|
||||
" worked.
|
||||
"
|
||||
" Version 9.0
|
||||
"
|
||||
" NF: Completes 'b:undo_ftplugin'
|
||||
" BF: Correctly set cpoptions when creating script
|
||||
"
|
||||
" Version 8.0
|
||||
"
|
||||
"
|
||||
" NF: Improved the matchit plugin regex (Talek)
|
||||
"
|
||||
" Version 7.0
|
||||
"
|
||||
"
|
||||
" NF: Calls the sqlcomplete#ResetCacheSyntax() function when calling
|
||||
" SQLSetType.
|
||||
"
|
||||
" Version 6.0
|
||||
"
|
||||
"
|
||||
" NF: Adds the command SQLGetType
|
||||
"
|
||||
" Version 5.0
|
||||
"
|
||||
" NF: Adds the ability to choose the keys to control SQL completion, just add
|
||||
"
|
||||
" NF: Adds the ability to choose the keys to control SQL completion, just add
|
||||
" the following to your .vimrc:
|
||||
" let g:ftplugin_sql_omni_key = '<C-C>'
|
||||
" let g:ftplugin_sql_omni_key_right = '<Right>'
|
||||
" let g:ftplugin_sql_omni_key_left = '<Left>'
|
||||
"
|
||||
" BF: format-options - Auto-wrap comments using textwidth was turned off
|
||||
" BF: format-options - Auto-wrap comments using textwidth was turned off
|
||||
" by mistake.
|
||||
|
||||
|
||||
@@ -81,7 +99,7 @@ setlocal formatoptions+=c
|
||||
" This works with both Vim 6 and 7.
|
||||
|
||||
if !exists("*SQL_SetType")
|
||||
" NOTE: You cannot use function! since this file can be
|
||||
" NOTE: You cannot use function! since this file can be
|
||||
" sourced from within this function. That will result in
|
||||
" an error reported by Vim.
|
||||
function SQL_GetList(ArgLead, CmdLine, CursorPos)
|
||||
@@ -105,9 +123,9 @@ if !exists("*SQL_SetType")
|
||||
"
|
||||
" Recursively, since there are many filenames that contain
|
||||
" the word SQL in the indent, syntax and ftplugin directory
|
||||
let sqls = substitute( sqls,
|
||||
\ '[\n]\%(.\{-}\)\(\w\+\.\w\+\)\n\@=',
|
||||
\ '\1\n',
|
||||
let sqls = substitute( sqls,
|
||||
\ '[\n]\%(.\{-}\)\(\w\+\.\w\+\)\n\@=',
|
||||
\ '\1\n',
|
||||
\ 'g'
|
||||
\ )
|
||||
|
||||
@@ -142,10 +160,10 @@ if !exists("*SQL_SetType")
|
||||
function SQL_SetType(name)
|
||||
|
||||
" User has decided to override default SQL scripts and
|
||||
" specify a vendor specific version
|
||||
" specify a vendor specific version
|
||||
" (ie Oracle, Informix, SQL Anywhere, ...)
|
||||
" So check for an remove any settings that prevent the
|
||||
" scripts from being executed, and then source the
|
||||
" scripts from being executed, and then source the
|
||||
" appropriate Vim scripts.
|
||||
if exists("b:did_ftplugin")
|
||||
unlet b:did_ftplugin
|
||||
@@ -163,10 +181,10 @@ if !exists("*SQL_SetType")
|
||||
endif
|
||||
|
||||
" Ensure the name is in the correct format
|
||||
let new_sql_type = substitute(a:name,
|
||||
let new_sql_type = substitute(a:name,
|
||||
\ '\s*\([^\.]\+\)\(\.\w\+\)\?', '\L\1', '')
|
||||
|
||||
" Do not specify a buffer local variable if it is
|
||||
" Do not specify a buffer local variable if it is
|
||||
" the default value
|
||||
if new_sql_type == 'sql'
|
||||
let new_sql_type = 'sqloracle'
|
||||
@@ -175,7 +193,7 @@ if !exists("*SQL_SetType")
|
||||
|
||||
" Remove any cached SQL since a new sytax will have different
|
||||
" items and groups
|
||||
if !exists('g:loaded_sql_completion') || 100 == g:loaded_sql_completion
|
||||
if !exists('g:loaded_sql_completion') || g:loaded_sql_completion >= 100
|
||||
call sqlcomplete#ResetCacheSyntax()
|
||||
endif
|
||||
|
||||
@@ -203,10 +221,10 @@ endif
|
||||
|
||||
if !exists("*SQL_GetType")
|
||||
function SQL_GetType()
|
||||
if exists('b:sql_type_override')
|
||||
if exists('b:sql_type_override')
|
||||
echomsg "Current SQL dialect in use:".b:sql_type_override
|
||||
else
|
||||
echomsg "Current SQL dialect in use:".g:sql_type_default
|
||||
echomsg "Current SQL dialect in use:".g:sql_type_default
|
||||
endif
|
||||
endfunction
|
||||
command! -nargs=0 SQLGetType :call SQL_GetType()
|
||||
@@ -233,7 +251,8 @@ if exists("b:did_ftplugin")
|
||||
finish
|
||||
endif
|
||||
|
||||
let b:undo_ftplugin = "setl comments<"
|
||||
let b:undo_ftplugin = "setl comments< formatoptions< define< omnifunc<" .
|
||||
\ " | unlet! b:browsefilter b:match_words"
|
||||
|
||||
" Don't load another plugin for this buffer
|
||||
let b:did_ftplugin = 1
|
||||
@@ -280,7 +299,7 @@ if !exists("b:match_words")
|
||||
" doend
|
||||
"
|
||||
" case
|
||||
" when
|
||||
" when
|
||||
" when
|
||||
" default
|
||||
" end case
|
||||
@@ -296,8 +315,10 @@ if !exists("b:match_words")
|
||||
" create[ or replace] procedure|function|event
|
||||
" \ '^\s*\<\%(do\|for\|while\|loop\)\>.*:'.
|
||||
|
||||
let b:match_words =
|
||||
\ '\<begin\>:\<end\>\W*$,'.
|
||||
" For ColdFusion support
|
||||
setlocal matchpairs+=<:>
|
||||
let b:match_words = &matchpairs .
|
||||
\ ',\<begin\>:\<end\>\W*$,'.
|
||||
\
|
||||
\ s:notend . '\<if\>:'.
|
||||
\ '\<elsif\>\|\<elseif\>\|\<else\>:'.
|
||||
@@ -337,14 +358,14 @@ let &l:define = '\c\<\(VARIABLE\|DECLARE\|IN\|OUT\|INOUT\)\>'
|
||||
|
||||
" Mappings to move to the next BEGIN ... END block
|
||||
" \W - no characters or digits
|
||||
nmap <buffer> <silent> ]] :call search('\\c^\\s*begin\\>', 'W' )<CR>
|
||||
nmap <buffer> <silent> [[ :call search('\\c^\\s*begin\\>', 'bW' )<CR>
|
||||
nmap <buffer> <silent> ][ :call search('\\c^\\s*end\\W*$', 'W' )<CR>
|
||||
nmap <buffer> <silent> [] :call search('\\c^\\s*end\\W*$', 'bW' )<CR>
|
||||
vmap <buffer> <silent> ]] :<C-U>exec "normal! gv"<Bar>call search('\\c^\\s*begin\\>', 'W' )<CR>
|
||||
vmap <buffer> <silent> [[ :<C-U>exec "normal! gv"<Bar>call search('\\c^\\s*begin\\>', 'bW' )<CR>
|
||||
vmap <buffer> <silent> ][ :<C-U>exec "normal! gv"<Bar>call search('\\c^\\s*end\\W*$', 'W' )<CR>
|
||||
vmap <buffer> <silent> [] :<C-U>exec "normal! gv"<Bar>call search('\\c^\\s*end\\W*$', 'bW' )<CR>
|
||||
nnoremap <buffer> <silent> ]] :call search('\c^\s*begin\>', 'W' )<CR>
|
||||
nnoremap <buffer> <silent> [[ :call search('\c^\s*begin\>', 'bW' )<CR>
|
||||
nnoremap <buffer> <silent> ][ :call search('\c^\s*end\W*$', 'W' )<CR>
|
||||
nnoremap <buffer> <silent> [] :call search('\c^\s*end\W*$', 'bW' )<CR>
|
||||
xnoremap <buffer> <silent> ]] :<C-U>exec "normal! gv"<Bar>call search('\c^\s*begin\>', 'W' )<CR>
|
||||
xnoremap <buffer> <silent> [[ :<C-U>exec "normal! gv"<Bar>call search('\c^\s*begin\>', 'bW' )<CR>
|
||||
xnoremap <buffer> <silent> ][ :<C-U>exec "normal! gv"<Bar>call search('\c^\s*end\W*$', 'W' )<CR>
|
||||
xnoremap <buffer> <silent> [] :<C-U>exec "normal! gv"<Bar>call search('\c^\s*end\W*$', 'bW' )<CR>
|
||||
|
||||
|
||||
" By default only look for CREATE statements, but allow
|
||||
@@ -361,7 +382,7 @@ endif
|
||||
" backwards, you must use \{,1}
|
||||
if !exists('g:ftplugin_sql_objects')
|
||||
let g:ftplugin_sql_objects = 'function,procedure,event,' .
|
||||
\ '\\(existing\\\\|global\\s\\+temporary\\s\\+\\)\\\{,1}' .
|
||||
\ '\(existing\\|global\s\+temporary\s\+\)\{,1}' .
|
||||
\ 'table,trigger' .
|
||||
\ ',schema,service,publication,database,datatype,domain' .
|
||||
\ ',index,subscription,synchronization,view,variable'
|
||||
@@ -382,47 +403,47 @@ endif
|
||||
|
||||
" Replace all ,'s with bars, except ones with numbers after them.
|
||||
" This will most likely be a \{,1} string.
|
||||
let s:ftplugin_sql_objects =
|
||||
\ '\\c^\\s*' .
|
||||
\ '\\(\\(' .
|
||||
\ substitute(g:ftplugin_sql_statements, ',\d\@!', '\\\\\\|', 'g') .
|
||||
\ '\\)\\s\\+\\(or\\s\\+replace\\\s\+\\)\\{,1}\\)\\{,1}' .
|
||||
\ '\\<\\(' .
|
||||
\ substitute(g:ftplugin_sql_objects, ',\d\@!', '\\\\\\|', 'g') .
|
||||
\ '\\)\\>'
|
||||
let s:ftplugin_sql_objects =
|
||||
\ '\c^\s*' .
|
||||
\ '\(\(' .
|
||||
\ substitute(g:ftplugin_sql_statements, ',\d\@!', '\\\\|', 'g') .
|
||||
\ '\)\s\+\(or\s\+replace\s\+\)\{,1}\)\{,1}' .
|
||||
\ '\<\(' .
|
||||
\ substitute(g:ftplugin_sql_objects, ',\d\@!', '\\\\|', 'g') .
|
||||
\ '\)\>'
|
||||
|
||||
" Mappings to move to the next CREATE ... block
|
||||
exec "nmap <buffer> <silent> ]} :call search('".s:ftplugin_sql_objects."', 'W')<CR>"
|
||||
exec "nmap <buffer> <silent> [{ :call search('".s:ftplugin_sql_objects."', 'bW')<CR>"
|
||||
exec "nnoremap <buffer> <silent> ]} :call search('".s:ftplugin_sql_objects."', 'W')<CR>"
|
||||
exec "nnoremap <buffer> <silent> [{ :call search('".s:ftplugin_sql_objects."', 'bW')<CR>"
|
||||
" Could not figure out how to use a :call search() string in visual mode
|
||||
" without it ending visual mode
|
||||
" Unfortunately, this will add a entry to the search history
|
||||
exec 'vmap <buffer> <silent> ]} /'.s:ftplugin_sql_objects.'<CR>'
|
||||
exec 'vmap <buffer> <silent> [{ ?'.s:ftplugin_sql_objects.'<CR>'
|
||||
exec 'xnoremap <buffer> <silent> ]} /'.s:ftplugin_sql_objects.'<CR>'
|
||||
exec 'xnoremap <buffer> <silent> [{ ?'.s:ftplugin_sql_objects.'<CR>'
|
||||
|
||||
" Mappings to move to the next COMMENT
|
||||
"
|
||||
" Had to double the \ for the \| separator since this has a special
|
||||
" meaning on maps
|
||||
let b:comment_leader = '\\(--\\\|\\/\\/\\\|\\*\\\|\\/\\*\\\|\\*\\/\\)'
|
||||
let b:comment_leader = '\(--\\|\/\/\\|\*\\|\/\*\\|\*\/\)'
|
||||
" Find the start of the next comment
|
||||
let b:comment_start = '^\\(\\s*'.b:comment_leader.'.*\\n\\)\\@<!'.
|
||||
\ '\\(\\s*'.b:comment_leader.'\\)'
|
||||
let b:comment_start = '^\(\s*'.b:comment_leader.'.*\n\)\@<!'.
|
||||
\ '\(\s*'.b:comment_leader.'\)'
|
||||
" Find the end of the previous comment
|
||||
let b:comment_end = '\\(^\\s*'.b:comment_leader.'.*\\n\\)'.
|
||||
\ '\\(^\\s*'.b:comment_leader.'\\)\\@!'
|
||||
let b:comment_end = '\(^\s*'.b:comment_leader.'.*\n\)'.
|
||||
\ '\(^\s*'.b:comment_leader.'\)\@!'
|
||||
" Skip over the comment
|
||||
let b:comment_jump_over = "call search('".
|
||||
\ '^\\(\\s*'.b:comment_leader.'.*\\n\\)\\@<!'.
|
||||
\ '^\(\s*'.b:comment_leader.'.*\n\)\@<!'.
|
||||
\ "', 'W')"
|
||||
let b:comment_skip_back = "call search('".
|
||||
\ '^\\(\\s*'.b:comment_leader.'.*\\n\\)\\@<!'.
|
||||
\ '^\(\s*'.b:comment_leader.'.*\n\)\@<!'.
|
||||
\ "', 'bW')"
|
||||
" Move to the start and end of comments
|
||||
exec 'nnoremap <silent><buffer> ]" :call search('."'".b:comment_start."'".', "W" )<CR>'
|
||||
exec 'nnoremap <silent><buffer> [" :call search('."'".b:comment_end."'".', "W" )<CR>'
|
||||
exec 'vnoremap <silent><buffer> ]" :<C-U>exec "normal! gv"<Bar>call search('."'".b:comment_start."'".', "W" )<CR>'
|
||||
exec 'vnoremap <silent><buffer> [" :<C-U>exec "normal! gv"<Bar>call search('."'".b:comment_end."'".', "W" )<CR>'
|
||||
exec 'xnoremap <silent><buffer> ]" :<C-U>exec "normal! gv"<Bar>call search('."'".b:comment_start."'".', "W" )<CR>'
|
||||
exec 'xnoremap <silent><buffer> [" :<C-U>exec "normal! gv"<Bar>call search('."'".b:comment_end."'".', "W" )<CR>'
|
||||
|
||||
" Comments can be of the form:
|
||||
" /*
|
||||
@@ -431,7 +452,7 @@ exec 'vnoremap <silent><buffer> [" :<C-U>exec "normal! gv"<Bar>call search('."'"
|
||||
" or
|
||||
" --
|
||||
" or
|
||||
" //
|
||||
" //
|
||||
setlocal comments=s1:/*,mb:*,ex:*/,:--,://
|
||||
|
||||
" Set completion with CTRL-X CTRL-O to autoloaded function.
|
||||
@@ -441,42 +462,50 @@ if exists('&omnifunc')
|
||||
" OMNI function prior to setting up the SQL OMNI function
|
||||
let b:sql_compl_savefunc = &omnifunc
|
||||
|
||||
" Source it to determine it's version
|
||||
runtime autoload/sqlcomplete.vim
|
||||
" This is used by the sqlcomplete.vim plugin
|
||||
" Source it for it's global functions
|
||||
runtime autoload/syntaxcomplete.vim
|
||||
runtime autoload/syntaxcomplete.vim
|
||||
|
||||
setlocal omnifunc=sqlcomplete#Complete
|
||||
" Prevent the intellisense plugin from loading
|
||||
let b:sql_vis = 1
|
||||
if !exists('g:omni_sql_no_default_maps')
|
||||
let regex_extra = ''
|
||||
if exists('g:loaded_syntax_completion') && exists('g:loaded_sql_completion')
|
||||
if g:loaded_syntax_completion > 120 && g:loaded_sql_completion > 140
|
||||
let regex_extra = '\\w*'
|
||||
endif
|
||||
endif
|
||||
" Static maps which use populate the completion list
|
||||
" using Vim's syntax highlighting rules
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'a <C-\><C-O>:call sqlcomplete#Map("syntax")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'k <C-\><C-O>:call sqlcomplete#Map("sqlKeyword")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'f <C-\><C-O>:call sqlcomplete#Map("sqlFunction")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'o <C-\><C-O>:call sqlcomplete#Map("sqlOption")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'T <C-\><C-O>:call sqlcomplete#Map("sqlType")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'s <C-\><C-O>:call sqlcomplete#Map("sqlStatement")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'a <C-\><C-O>:call sqlcomplete#Map("syntax")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'k <C-\><C-O>:call sqlcomplete#Map("sqlKeyword'.regex_extra.'")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'f <C-\><C-O>:call sqlcomplete#Map("sqlFunction'.regex_extra.'")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'o <C-\><C-O>:call sqlcomplete#Map("sqlOption'.regex_extra.'")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'T <C-\><C-O>:call sqlcomplete#Map("sqlType'.regex_extra.'")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'s <C-\><C-O>:call sqlcomplete#Map("sqlStatement'.regex_extra.'")<CR><C-X><C-O>'
|
||||
" Dynamic maps which use populate the completion list
|
||||
" using the dbext.vim plugin
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'t <C-\><C-O>:call sqlcomplete#Map("table")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'p <C-\><C-O>:call sqlcomplete#Map("procedure")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'v <C-\><C-O>:call sqlcomplete#Map("view")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'c <C-\><C-O>:call sqlcomplete#Map("column")<CR><C-X><C-O>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'l <C-\><C-O>:call sqlcomplete#Map("column_csv")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'t <C-\><C-O>:call sqlcomplete#Map("table")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'p <C-\><C-O>:call sqlcomplete#Map("procedure")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'v <C-\><C-O>:call sqlcomplete#Map("view")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'c <C-\><C-O>:call sqlcomplete#Map("column")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'l <C-\><C-O>:call sqlcomplete#Map("column_csv")<CR><C-X><C-O>'
|
||||
" The next 3 maps are only to be used while the completion window is
|
||||
" active due to the <CR> at the beginning of the map
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'L <C-Y><C-\><C-O>:call sqlcomplete#Map("column_csv")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'L <C-Y><C-\><C-O>:call sqlcomplete#Map("column_csv")<CR><C-X><C-O>'
|
||||
" <C-Right> is not recognized on most Unix systems, so only create
|
||||
" these additional maps on the Windows platform.
|
||||
" If you would like to use these maps, choose a different key and make
|
||||
" the same map in your vimrc.
|
||||
" if has('win32')
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key_right.' <C-R>=sqlcomplete#DrillIntoTable()<CR>'
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key_left.' <C-R>=sqlcomplete#DrillOutOfColumns()<CR>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key_right.' <C-R>=sqlcomplete#DrillIntoTable()<CR>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key_left.' <C-R>=sqlcomplete#DrillOutOfColumns()<CR>'
|
||||
" endif
|
||||
" Remove any cached items useful for schema changes
|
||||
exec 'imap <buffer> '.g:ftplugin_sql_omni_key.'R <C-\><C-O>:call sqlcomplete#Map("resetCache")<CR><C-X><C-O>'
|
||||
exec 'inoremap <buffer> '.g:ftplugin_sql_omni_key.'R <C-\><C-O>:call sqlcomplete#Map("resetCache")<CR><C-X><C-O>'
|
||||
endif
|
||||
|
||||
if b:sql_compl_savefunc != ""
|
||||
@@ -493,4 +522,3 @@ let &cpo = s:save_cpo
|
||||
unlet s:save_cpo
|
||||
|
||||
" vim:sw=4:
|
||||
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: XS (Perl extension interface language)
|
||||
" Maintainer: Andy Lester <andy@petdance.com>
|
||||
" URL: http://github.com/petdance/vim-perl
|
||||
" Last Change: 2009-08-14
|
||||
" Language: XS (Perl extension interface language)
|
||||
" Maintainer: vim-perl <vim-perl@googlegroups.com>
|
||||
" Homepage: http://github.com/vim-perl/vim-perl
|
||||
" Bugs/requests: http://github.com/vim-perl/vim-perl/issues
|
||||
" Last Change: 2009-08-14
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim filetype plugin file
|
||||
" Language: Zimbu
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2012 May 18
|
||||
" Last Change: 2012 Sep 08
|
||||
|
||||
" Only do this when not done yet for this buffer
|
||||
if exists("b:did_ftplugin")
|
||||
@@ -34,7 +34,7 @@ setlocal errorformat^=%f\ line\ %l\ col\ %c:\ %m,ERROR:\ %m
|
||||
|
||||
" When the matchit plugin is loaded, this makes the % command skip parens and
|
||||
" braces in comments.
|
||||
let b:match_words = '\(^\s*\)\@<=\(MODULE\|CLASS\|INTERFACE\|BITS\|ENUM\|SHARED\|FUNC\|REPLACE\|DEFINE\|PROC\|EQUAL\|MAIN\|IF\|GENERATE_IF\|WHILE\|REPEAT\|WITH\|DO\|FOR\|SWITCH\|TRY\)\>\|{\s*$:\(^\s*\)\@<=\(ELSE\|ELSEIF\|GENERATE_ELSE\|GENERATE_ELSEIF\|CATCH\|FINALLY\)\>:\(^\s*\)\@<=}\|\<UNTIL\>'
|
||||
let b:match_words = '\(^\s*\)\@<=\(MODULE\|CLASS\|INTERFACE\|BITS\|ENUM\|SHARED\|FUNC\|REPLACE\|DEFINE\|PROC\|EQUAL\|MAIN\|IF\|GENERATE_IF\|WHILE\|REPEAT\|WITH\|DO\|FOR\|SWITCH\|TRY\)\>\|{\s*$:\(^\s*\)\@<=\(ELSE\|ELSEIF\|GENERATE_ELSE\|GENERATE_ELSEIF\|CATCH\|FINALLY\)\>:\(^\s*\)\@<=\(}\|\<UNTIL\>\)'
|
||||
|
||||
let b:match_skip = 's:comment\|string\|zimbuchar'
|
||||
|
||||
@@ -43,12 +43,36 @@ setlocal et sts=2 sw=2
|
||||
|
||||
" Does replace when a dot, space or closing brace is typed.
|
||||
func! GCUpperDot(what)
|
||||
let col = col(".") - strlen(a:what)
|
||||
if v:char != ' ' && v:char != "\r" && v:char != "\x1b" && v:char != '.' && v:char != ')' && v:char != '}'
|
||||
if v:char != ' ' && v:char != "\r" && v:char != "\x1b" && v:char != '.' && v:char != ')' && v:char != '}' && v:char != ','
|
||||
" no space or dot after the typed text
|
||||
let g:got_char = v:char
|
||||
return a:what
|
||||
endif
|
||||
return GCUpperCommon(a:what)
|
||||
endfunc
|
||||
|
||||
" Does not replace when a dot is typed.
|
||||
func! GCUpper(what)
|
||||
if v:char != ' ' && v:char != "\r" && v:char != "\x1b" && v:char != ')' && v:char != ','
|
||||
" no space or other "terminating" character after the typed text
|
||||
let g:got_char = v:char
|
||||
return a:what
|
||||
endif
|
||||
return GCUpperCommon(a:what)
|
||||
endfunc
|
||||
|
||||
" Only replaces when a space is typed.
|
||||
func! GCUpperSpace(what)
|
||||
if v:char != ' '
|
||||
" no space after the typed text
|
||||
let g:got_char = v:char
|
||||
return a:what
|
||||
endif
|
||||
return GCUpperCommon(a:what)
|
||||
endfunc
|
||||
|
||||
func! GCUpperCommon(what)
|
||||
let col = col(".") - strlen(a:what)
|
||||
if col > 1 && getline('.')[col - 2] != ' '
|
||||
" no space before the typed text
|
||||
let g:got_char = 999
|
||||
@@ -64,34 +88,15 @@ func! GCUpperDot(what)
|
||||
return toupper(a:what)
|
||||
endfunc
|
||||
|
||||
" Does not replace when a dot is typed.
|
||||
func! GCUpper(what)
|
||||
if v:char != ' ' && v:char != "\r" && v:char != "\x1b" && v:char != ')'
|
||||
" no space after the typed text
|
||||
let g:got_char = v:char
|
||||
return a:what
|
||||
endif
|
||||
return GCUpperDot(a:what)
|
||||
endfunc
|
||||
|
||||
" Only replaces when a space is typed.
|
||||
func! GCUpperSpace(what)
|
||||
if v:char != ' '
|
||||
" no space after the typed text
|
||||
let g:got_char = v:char
|
||||
return a:what
|
||||
endif
|
||||
return GCUpperDot(a:what)
|
||||
endfunc
|
||||
|
||||
iabbr <buffer> <expr> alias GCUpperSpace("alias")
|
||||
iabbr <buffer> <expr> arg GCUpperDot("arg")
|
||||
iabbr <buffer> <expr> bad GCUpper("bad")
|
||||
iabbr <buffer> <expr> break GCUpper("break")
|
||||
iabbr <buffer> <expr> case GCUpperSpace("case")
|
||||
iabbr <buffer> <expr> catch GCUpperSpace("catch")
|
||||
iabbr <buffer> <expr> check GCUpperDot("check")
|
||||
iabbr <buffer> <expr> class GCUpperSpace("class")
|
||||
iabbr <buffer> <expr> interface GCUpperSpace("interface")
|
||||
iabbr <buffer> <expr> implements GCUpperSpace("implements")
|
||||
iabbr <buffer> <expr> shared GCUpperSpace("shared")
|
||||
iabbr <buffer> <expr> continue GCUpper("continue")
|
||||
iabbr <buffer> <expr> default GCUpper("default")
|
||||
|
||||
398
runtime/indent/clojure.vim
Normal file
398
runtime/indent/clojure.vim
Normal file
@@ -0,0 +1,398 @@
|
||||
" Vim indent file
|
||||
" Language: Clojure
|
||||
" Author: Meikel Brandmeyer <mb@kotka.de>
|
||||
" URL: http://kotka.de/projects/clojure/vimclojure.html
|
||||
"
|
||||
" Maintainer: Sung Pae <self@sungpae.com>
|
||||
" URL: https://github.com/guns/vim-clojure-static
|
||||
" License: Same as Vim
|
||||
" Last Change: 30 January 2013
|
||||
|
||||
" Only load this indent file when no other was loaded.
|
||||
if exists("b:did_indent")
|
||||
finish
|
||||
endif
|
||||
let b:did_indent = 1
|
||||
|
||||
let s:save_cpo = &cpo
|
||||
set cpo&vim
|
||||
|
||||
let b:undo_indent = 'setlocal autoindent< smartindent< lispwords< expandtab< softtabstop< shiftwidth< indentexpr< indentkeys<'
|
||||
|
||||
setlocal noautoindent nosmartindent
|
||||
setlocal softtabstop=2 shiftwidth=2 expandtab
|
||||
setlocal indentkeys=!,o,O
|
||||
|
||||
if exists("*searchpairpos")
|
||||
|
||||
if !exists('g:clojure_maxlines')
|
||||
let g:clojure_maxlines = 100
|
||||
endif
|
||||
|
||||
if !exists('g:clojure_fuzzy_indent')
|
||||
let g:clojure_fuzzy_indent = 1
|
||||
endif
|
||||
|
||||
if !exists('g:clojure_fuzzy_indent_patterns')
|
||||
let g:clojure_fuzzy_indent_patterns = ['^with', '^def', '^let']
|
||||
endif
|
||||
|
||||
if !exists('g:clojure_fuzzy_indent_blacklist')
|
||||
let g:clojure_fuzzy_indent_blacklist = ['-fn$', '\v^with-%(meta|out-str|loading-context)$']
|
||||
endif
|
||||
|
||||
if !exists('g:clojure_special_indent_words')
|
||||
let g:clojure_special_indent_words = 'deftype,defrecord,reify,proxy,extend-type,extend-protocol,letfn'
|
||||
endif
|
||||
|
||||
if !exists('g:clojure_align_multiline_strings')
|
||||
let g:clojure_align_multiline_strings = 0
|
||||
endif
|
||||
|
||||
function! s:SynIdName()
|
||||
return synIDattr(synID(line("."), col("."), 0), "name")
|
||||
endfunction
|
||||
|
||||
function! s:CurrentChar()
|
||||
return getline('.')[col('.')-1]
|
||||
endfunction
|
||||
|
||||
function! s:CurrentWord()
|
||||
return getline('.')[col('.')-1 : searchpos('\v>', 'n', line('.'))[1]-2]
|
||||
endfunction
|
||||
|
||||
function! s:IsParen()
|
||||
return s:CurrentChar() =~ '\v[\(\)\[\]\{\}]' &&
|
||||
\ s:SynIdName() !~? '\vstring|comment'
|
||||
endfunction
|
||||
|
||||
" Returns 1 if string matches a pattern in 'patterns', which may be a
|
||||
" list of patterns, or a comma-delimited string of implicitly anchored
|
||||
" patterns.
|
||||
function! s:MatchesOne(patterns, string)
|
||||
let list = type(a:patterns) == type([])
|
||||
\ ? a:patterns
|
||||
\ : map(split(a:patterns, ','), '"^" . v:val . "$"')
|
||||
for pat in list
|
||||
if a:string =~ pat | return 1 | endif
|
||||
endfor
|
||||
endfunction
|
||||
|
||||
function! s:SavePosition()
|
||||
let [ _b, l, c, _o ] = getpos(".")
|
||||
let b = bufnr("%")
|
||||
return [b, l, c]
|
||||
endfunction
|
||||
|
||||
function! s:RestorePosition(value)
|
||||
let [b, l, c] = a:value
|
||||
if bufnr("%") != b
|
||||
execute b "buffer!"
|
||||
endif
|
||||
call setpos(".", [0, l, c, 0])
|
||||
endfunction
|
||||
|
||||
function! s:MatchPairs(open, close, stopat)
|
||||
" Stop only on vector and map [ resp. {. Ignore the ones in strings and
|
||||
" comments.
|
||||
if a:stopat == 0
|
||||
let stopat = max([line(".") - g:clojure_maxlines, 0])
|
||||
else
|
||||
let stopat = a:stopat
|
||||
endif
|
||||
|
||||
let pos = searchpairpos(a:open, '', a:close, 'bWn', "!s:IsParen()", stopat)
|
||||
return [pos[0], virtcol(pos)]
|
||||
endfunction
|
||||
|
||||
function! s:ClojureCheckForStringWorker()
|
||||
" Check whether there is the last character of the previous line is
|
||||
" highlighted as a string. If so, we check whether it's a ". In this
|
||||
" case we have to check also the previous character. The " might be the
|
||||
" closing one. In case the we are still in the string, we search for the
|
||||
" opening ". If this is not found we take the indent of the line.
|
||||
let nb = prevnonblank(v:lnum - 1)
|
||||
|
||||
if nb == 0
|
||||
return -1
|
||||
endif
|
||||
|
||||
call cursor(nb, 0)
|
||||
call cursor(0, col("$") - 1)
|
||||
if s:SynIdName() !~? "string"
|
||||
return -1
|
||||
endif
|
||||
|
||||
" This will not work for a " in the first column...
|
||||
if s:CurrentChar() == '"'
|
||||
call cursor(0, col("$") - 2)
|
||||
if s:SynIdName() !~? "string"
|
||||
return -1
|
||||
endif
|
||||
if s:CurrentChar() != '\\'
|
||||
return -1
|
||||
endif
|
||||
call cursor(0, col("$") - 1)
|
||||
endif
|
||||
|
||||
let p = searchpos('\(^\|[^\\]\)\zs"', 'bW')
|
||||
|
||||
if p != [0, 0]
|
||||
return p[1] - 1
|
||||
endif
|
||||
|
||||
return indent(".")
|
||||
endfunction
|
||||
|
||||
function! s:CheckForString()
|
||||
let pos = s:SavePosition()
|
||||
try
|
||||
let val = s:ClojureCheckForStringWorker()
|
||||
finally
|
||||
call s:RestorePosition(pos)
|
||||
endtry
|
||||
return val
|
||||
endfunction
|
||||
|
||||
function! s:ClojureIsMethodSpecialCaseWorker(position)
|
||||
" Find the next enclosing form.
|
||||
call search('\S', 'Wb')
|
||||
|
||||
" Special case: we are at a '(('.
|
||||
if s:CurrentChar() == '('
|
||||
return 0
|
||||
endif
|
||||
call cursor(a:position)
|
||||
|
||||
let nextParen = s:MatchPairs('(', ')', 0)
|
||||
|
||||
" Special case: we are now at toplevel.
|
||||
if nextParen == [0, 0]
|
||||
return 0
|
||||
endif
|
||||
call cursor(nextParen)
|
||||
|
||||
call search('\S', 'W')
|
||||
if g:clojure_special_indent_words =~ '\<' . s:CurrentWord() . '\>'
|
||||
return 1
|
||||
endif
|
||||
|
||||
return 0
|
||||
endfunction
|
||||
|
||||
function! s:IsMethodSpecialCase(position)
|
||||
let pos = s:SavePosition()
|
||||
try
|
||||
let val = s:ClojureIsMethodSpecialCaseWorker(a:position)
|
||||
finally
|
||||
call s:RestorePosition(pos)
|
||||
endtry
|
||||
return val
|
||||
endfunction
|
||||
|
||||
function! GetClojureIndent()
|
||||
" Get rid of special case.
|
||||
if line(".") == 1
|
||||
return 0
|
||||
endif
|
||||
|
||||
" We have to apply some heuristics here to figure out, whether to use
|
||||
" normal lisp indenting or not.
|
||||
let i = s:CheckForString()
|
||||
if i > -1
|
||||
return i + !!g:clojure_align_multiline_strings
|
||||
endif
|
||||
|
||||
call cursor(0, 1)
|
||||
|
||||
" Find the next enclosing [ or {. We can limit the second search
|
||||
" to the line, where the [ was found. If no [ was there this is
|
||||
" zero and we search for an enclosing {.
|
||||
let paren = s:MatchPairs('(', ')', 0)
|
||||
let bracket = s:MatchPairs('\[', '\]', paren[0])
|
||||
let curly = s:MatchPairs('{', '}', bracket[0])
|
||||
|
||||
" In case the curly brace is on a line later then the [ or - in
|
||||
" case they are on the same line - in a higher column, we take the
|
||||
" curly indent.
|
||||
if curly[0] > bracket[0] || curly[1] > bracket[1]
|
||||
if curly[0] > paren[0] || curly[1] > paren[1]
|
||||
return curly[1]
|
||||
endif
|
||||
endif
|
||||
|
||||
" If the curly was not chosen, we take the bracket indent - if
|
||||
" there was one.
|
||||
if bracket[0] > paren[0] || bracket[1] > paren[1]
|
||||
return bracket[1]
|
||||
endif
|
||||
|
||||
" There are neither { nor [ nor (, ie. we are at the toplevel.
|
||||
if paren == [0, 0]
|
||||
return 0
|
||||
endif
|
||||
|
||||
" Now we have to reimplement lispindent. This is surprisingly easy, as
|
||||
" soon as one has access to syntax items.
|
||||
"
|
||||
" - Check whether we are in a special position after a word in
|
||||
" g:clojure_special_indent_words. These are special cases.
|
||||
" - Get the next keyword after the (.
|
||||
" - If its first character is also a (, we have another sexp and align
|
||||
" one column to the right of the unmatched (.
|
||||
" - In case it is in lispwords, we indent the next line to the column of
|
||||
" the ( + sw.
|
||||
" - If not, we check whether it is last word in the line. In that case
|
||||
" we again use ( + sw for indent.
|
||||
" - In any other case we use the column of the end of the word + 2.
|
||||
call cursor(paren)
|
||||
|
||||
if s:IsMethodSpecialCase(paren)
|
||||
return paren[1] + &shiftwidth - 1
|
||||
endif
|
||||
|
||||
" In case we are at the last character, we use the paren position.
|
||||
if col("$") - 1 == paren[1]
|
||||
return paren[1]
|
||||
endif
|
||||
|
||||
" In case after the paren is a whitespace, we search for the next word.
|
||||
normal! l
|
||||
if s:CurrentChar() == ' '
|
||||
normal! w
|
||||
endif
|
||||
|
||||
" If we moved to another line, there is no word after the (. We
|
||||
" use the ( position for indent.
|
||||
if line(".") > paren[0]
|
||||
return paren[1]
|
||||
endif
|
||||
|
||||
" We still have to check, whether the keyword starts with a (, [ or {.
|
||||
" In that case we use the ( position for indent.
|
||||
let w = s:CurrentWord()
|
||||
if stridx('([{', w[0]) > -1
|
||||
return paren[1]
|
||||
endif
|
||||
|
||||
" Test words without namespace qualifiers and leading reader macro
|
||||
" metacharacters.
|
||||
"
|
||||
" e.g. clojure.core/defn and #'defn should both indent like defn.
|
||||
let ww = substitute(w, "\\v%(.*/|[#'`~@^,]*)(.*)", '\1', '')
|
||||
|
||||
if &lispwords =~ '\V\<' . ww . '\>'
|
||||
return paren[1] + &shiftwidth - 1
|
||||
endif
|
||||
|
||||
if g:clojure_fuzzy_indent
|
||||
\ && !s:MatchesOne(g:clojure_fuzzy_indent_blacklist, ww)
|
||||
\ && s:MatchesOne(g:clojure_fuzzy_indent_patterns, ww)
|
||||
return paren[1] + &shiftwidth - 1
|
||||
endif
|
||||
|
||||
normal! W
|
||||
if paren[0] < line(".")
|
||||
return paren[1] + &shiftwidth - 1
|
||||
endif
|
||||
|
||||
normal! ge
|
||||
return virtcol(".") + 1
|
||||
endfunction
|
||||
|
||||
setlocal indentexpr=GetClojureIndent()
|
||||
|
||||
else
|
||||
|
||||
" In case we have searchpairpos not available we fall back to
|
||||
" normal lisp indenting.
|
||||
setlocal indentexpr=
|
||||
setlocal lisp
|
||||
let b:undo_indent .= '| setlocal lisp<'
|
||||
|
||||
endif
|
||||
|
||||
" Specially indented symbols from clojure.core and clojure.test.
|
||||
"
|
||||
" Clojure symbols are indented in the defn style when they:
|
||||
"
|
||||
" * Define vars and anonymous functions
|
||||
" * Create new lexical scopes or scopes with altered environments
|
||||
" * Create conditional branches from a predicate function or value
|
||||
"
|
||||
" The arglists for these functions are generally in the form of [x & body];
|
||||
" Functions that accept a flat list of forms do not treat the first argument
|
||||
" specially and hence are not indented specially.
|
||||
|
||||
" Definitions
|
||||
setlocal lispwords=
|
||||
setlocal lispwords+=bound-fn
|
||||
setlocal lispwords+=def
|
||||
setlocal lispwords+=definline
|
||||
setlocal lispwords+=definterface
|
||||
setlocal lispwords+=defmacro
|
||||
setlocal lispwords+=defmethod
|
||||
setlocal lispwords+=defmulti
|
||||
setlocal lispwords+=defn
|
||||
setlocal lispwords+=defn-
|
||||
setlocal lispwords+=defonce
|
||||
setlocal lispwords+=defprotocol
|
||||
setlocal lispwords+=defrecord
|
||||
setlocal lispwords+=defstruct
|
||||
setlocal lispwords+=deftest " clojure.test
|
||||
setlocal lispwords+=deftest- " clojure.test
|
||||
setlocal lispwords+=deftype
|
||||
setlocal lispwords+=extend
|
||||
setlocal lispwords+=extend-protocol
|
||||
setlocal lispwords+=extend-type
|
||||
setlocal lispwords+=fn
|
||||
setlocal lispwords+=ns
|
||||
setlocal lispwords+=proxy
|
||||
setlocal lispwords+=reify
|
||||
setlocal lispwords+=set-test " clojure.test
|
||||
|
||||
" Binding forms
|
||||
setlocal lispwords+=as->
|
||||
setlocal lispwords+=binding
|
||||
setlocal lispwords+=doall
|
||||
setlocal lispwords+=dorun
|
||||
setlocal lispwords+=doseq
|
||||
setlocal lispwords+=dotimes
|
||||
setlocal lispwords+=doto
|
||||
setlocal lispwords+=for
|
||||
setlocal lispwords+=if-let
|
||||
setlocal lispwords+=let
|
||||
setlocal lispwords+=letfn
|
||||
setlocal lispwords+=locking
|
||||
setlocal lispwords+=loop
|
||||
setlocal lispwords+=testing " clojure.test
|
||||
setlocal lispwords+=when-first
|
||||
setlocal lispwords+=when-let
|
||||
setlocal lispwords+=with-bindings
|
||||
setlocal lispwords+=with-in-str
|
||||
setlocal lispwords+=with-local-vars
|
||||
setlocal lispwords+=with-open
|
||||
setlocal lispwords+=with-precision
|
||||
setlocal lispwords+=with-redefs
|
||||
setlocal lispwords+=with-redefs-fn
|
||||
setlocal lispwords+=with-test " clojure.test
|
||||
|
||||
" Conditional branching
|
||||
setlocal lispwords+=case
|
||||
setlocal lispwords+=cond->
|
||||
setlocal lispwords+=cond->>
|
||||
setlocal lispwords+=condp
|
||||
setlocal lispwords+=if
|
||||
setlocal lispwords+=if-not
|
||||
setlocal lispwords+=when
|
||||
setlocal lispwords+=when-not
|
||||
setlocal lispwords+=while
|
||||
|
||||
" Exception handling
|
||||
setlocal lispwords+=catch
|
||||
setlocal lispwords+=try " For aesthetics when enclosing single line
|
||||
|
||||
let &cpo = s:save_cpo
|
||||
unlet! s:save_cpo
|
||||
|
||||
" vim:sts=4 sw=4 et:
|
||||
@@ -1,7 +1,7 @@
|
||||
" Vim indent file
|
||||
" Language: Cucumber
|
||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
||||
" Last Change: 2010 May 21
|
||||
" Last Change: 2013 May 30
|
||||
|
||||
if exists("b:did_indent")
|
||||
finish
|
||||
@@ -12,6 +12,8 @@ setlocal autoindent
|
||||
setlocal indentexpr=GetCucumberIndent()
|
||||
setlocal indentkeys=o,O,*<Return>,<:>,0<Bar>,0#,=,!^F
|
||||
|
||||
let b:undo_indent = 'setl ai< inde< indk<'
|
||||
|
||||
" Only define the function once.
|
||||
if exists("*GetCucumberIndent")
|
||||
finish
|
||||
@@ -24,35 +26,47 @@ endfunction
|
||||
function! GetCucumberIndent()
|
||||
let line = getline(prevnonblank(v:lnum-1))
|
||||
let cline = getline(v:lnum)
|
||||
let nline = getline(nextnonblank(v:lnum+1))
|
||||
let syn = s:syn(prevnonblank(v:lnum-1))
|
||||
let csyn = s:syn(v:lnum)
|
||||
let nsyn = s:syn(nextnonblank(v:lnum+1))
|
||||
if csyn ==# 'cucumberFeature' || cline =~# '^\s*Feature:'
|
||||
" feature heading
|
||||
return 0
|
||||
elseif csyn ==# 'cucumberExamples' || cline =~# '^\s*\%(Examples\|Scenarios\):'
|
||||
" examples heading
|
||||
return 2 * &sw
|
||||
elseif csyn =~# '^cucumber\%(Background\|Scenario\|ScenarioOutline\)$' || cline =~# '^\s*\%(Background\|Scenario\|Scenario Outline\):'
|
||||
" background, scenario or outline heading
|
||||
return &sw
|
||||
elseif syn ==# 'cucumberFeature' || line =~# '^\s*Feature:'
|
||||
" line after feature heading
|
||||
return &sw
|
||||
elseif syn ==# 'cucumberExamples' || line =~# '^\s*\%(Examples\|Scenarios\):'
|
||||
" line after examples heading
|
||||
return 3 * &sw
|
||||
elseif syn =~# '^cucumber\%(Background\|Scenario\|ScenarioOutline\)$' || line =~# '^\s*\%(Background\|Scenario\|Scenario Outline\):'
|
||||
" line after background, scenario or outline heading
|
||||
return 2 * &sw
|
||||
elseif cline =~# '^\s*@' && (s:syn(nextnonblank(v:lnum+1)) == 'cucumberFeature' || getline(nextnonblank(v:lnum+1)) =~# '^\s*Feature:' || indent(prevnonblank(v:lnum-1)) <= 0)
|
||||
elseif cline =~# '^\s*[@#]' && (nsyn == 'cucumberFeature' || nline =~# '^\s*Feature:' || indent(prevnonblank(v:lnum-1)) <= 0)
|
||||
" tag or comment before a feature heading
|
||||
return 0
|
||||
elseif line =~# '^\s*@'
|
||||
elseif cline =~# '^\s*@'
|
||||
" other tags
|
||||
return &sw
|
||||
elseif cline =~# '^\s*|' && line =~# '^\s*|'
|
||||
elseif cline =~# '^\s*[#|]' && line =~# '^\s*|'
|
||||
" mid-table
|
||||
" preserve indent
|
||||
return indent(prevnonblank(v:lnum-1))
|
||||
elseif cline =~# '^\s*|' && line =~# '^\s*[^|#]'
|
||||
elseif cline =~# '^\s*|' && line =~# '^\s*[^|]'
|
||||
" first line of a table, relative indent
|
||||
return indent(prevnonblank(v:lnum-1)) + &sw
|
||||
elseif cline =~# '^\s*[^|# \t]' && line =~# '^\s*|'
|
||||
elseif cline =~# '^\s*[^|]' && line =~# '^\s*|'
|
||||
" line after a table, relative unindent
|
||||
return indent(prevnonblank(v:lnum-1)) - &sw
|
||||
elseif cline =~# '^\s*$' && line =~# '^\s*|'
|
||||
let in = indent(prevnonblank(v:lnum-1))
|
||||
return in == indent(v:lnum) ? in : in - &sw
|
||||
elseif cline =~# '^\s*#' && getline(v:lnum-1) =~ '^\s*$' && getline(v:lnum+1) =~# '\S'
|
||||
return indent(getline(v:lnum+1))
|
||||
elseif cline =~# '^\s*#' && getline(v:lnum-1) =~ '^\s*$' && (nsyn =~# '^cucumber\%(Background\|Scenario\|ScenarioOutline\)$' || nline =~# '^\s*\%(Background\|Scenario\|Scenario Outline\):')
|
||||
" comments on scenarios
|
||||
return &sw
|
||||
endif
|
||||
return indent(prevnonblank(v:lnum-1))
|
||||
endfunction
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -5,7 +5,6 @@
|
||||
" Credits: Thanks to the ruby.vim authors, I borrow a lot!
|
||||
" Previous Maintainer: Brent A. Fulgham <bfulgham@debian.org>
|
||||
" -----------------------------------------------------------
|
||||
" GetLatestVimScripts: 2752 1 :AutoInstall: falcon.vim
|
||||
|
||||
"======================================
|
||||
" SETUP
|
||||
@@ -132,7 +131,7 @@ function FalconGetIndent()
|
||||
" If previous line ends in a semi-colon reset indent to previous
|
||||
" lines setting
|
||||
if prevline =~? ';\s*$' && prevnonblank(prevline) =~? ',\s*$'
|
||||
return chg = chg - (2 * &sw)
|
||||
let chg = chg - (2 * &sw)
|
||||
endif
|
||||
|
||||
" If previous line ended in a comma, indent again
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user