updated for version 7.0112
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
*autocmd.txt* For Vim version 7.0aa. Last change: 2005 Mar 04
|
||||
*autocmd.txt* For Vim version 7.0aa. Last change: 2005 Jul 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -542,6 +542,18 @@ QuickFixCmdPre *QuickFixCmdPre*
|
||||
QuickFixCmdPost *QuickFixCmdPost*
|
||||
like QuickFixCmdPre, but after a quickfix
|
||||
command is run.
|
||||
*MenuPopup*
|
||||
MenuPopup Just before showing the popup menu (under the
|
||||
right mouse button). Useful for adjusting the
|
||||
menu for what is under the cursor or mouse
|
||||
pointer.
|
||||
The pattern is matched against a single
|
||||
character representing the mode:
|
||||
n Normal
|
||||
v Visual
|
||||
o Operator-pending
|
||||
i Insert
|
||||
c Commmand line
|
||||
*UserGettingBored*
|
||||
UserGettingBored When the user hits CTRL-C. Just kidding! :-)
|
||||
*User*
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
*eval.txt* For Vim version 7.0aa. Last change: 2005 Jul 18
|
||||
*eval.txt* For Vim version 7.0aa. Last change: 2005 Jul 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -1511,6 +1511,8 @@ foreground( ) Number bring the Vim window to the foreground
|
||||
function( {name}) Funcref reference to function {name}
|
||||
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}
|
||||
getchar( [expr]) Number get one character from the user
|
||||
getcharmod( ) Number modifiers for the last typed character
|
||||
getbufvar( {expr}, {varname}) variable {varname} in buffer {expr}
|
||||
@ -2409,6 +2411,35 @@ get({dict}, {key} [, {default}])
|
||||
item is not available return {default}. Return zero when
|
||||
{default} is omitted.
|
||||
|
||||
*getbufline()*
|
||||
getbufline({expr}, {lnum} [, {end}])
|
||||
Return the lines starting from {lnum} to {end} in the buffer
|
||||
{expr} as a List. If {end} is omitted, only the line {lnum}
|
||||
is returned.
|
||||
|
||||
For the use of {expr}, see |bufname()| above.
|
||||
|
||||
When {lnum} is a String that doesn't start with a
|
||||
digit, line() is called to translate the String into a Number.
|
||||
|
||||
{end} is used in the same way as {lnum}.
|
||||
|
||||
When {lnum} is smaller than 1 or bigger than the number of
|
||||
lines in the buffer, an empty List is returned.
|
||||
|
||||
When {end} is greater than the number of lines in the buffer,
|
||||
it is treated as {end} is set to the number of lines in the
|
||||
buffer.
|
||||
|
||||
When non-existing line ranges are specified, an empty List is
|
||||
returned. When {end} is before {lnum} an empty List is
|
||||
returned.
|
||||
|
||||
This function works only for loaded buffers. For unloaded and
|
||||
non-existing buffers, an empty List is returned.
|
||||
|
||||
Example: >
|
||||
:let lines = getbufline(bufnr("myfile"), 1, "$")
|
||||
|
||||
getbufvar({expr}, {varname}) *getbufvar()*
|
||||
The result is the value of option or local buffer variable
|
||||
@ -2572,7 +2603,7 @@ getline({lnum} [, {end}])
|
||||
including line {end}.
|
||||
{end} is used in the same way as {lnum}.
|
||||
Non-existing lines are silently omitted.
|
||||
When {end} is before {lnum} an error is given.
|
||||
When {end} is before {lnum} an empty List is returned.
|
||||
Example: >
|
||||
:let start = line('.')
|
||||
:let end = search("^$") - 1
|
||||
@ -4290,6 +4321,7 @@ arabic Compiled with Arabic support |Arabic|.
|
||||
arp Compiled with ARP support (Amiga).
|
||||
autocmd Compiled with autocommands support.
|
||||
balloon_eval Compiled with |balloon-eval| support.
|
||||
balloon_multiline GUI supports multiline balloons.
|
||||
beos BeOS version of Vim.
|
||||
browse Compiled with |:browse| support, and browse() will
|
||||
work.
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
*options.txt* For Vim version 7.0aa. Last change: 2005 Jul 18
|
||||
*options.txt* For Vim version 7.0aa. Last change: 2005 Jul 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -1013,7 +1013,7 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
The evaluation of the expression must not have side effects!
|
||||
Example: >
|
||||
function! MyBalloonExpr()
|
||||
return 'Cursor is at line ' . v:beval_lnum .
|
||||
return 'Cursor is at line ' . v:beval_lnum .
|
||||
\', column ' . v:beval_col .
|
||||
\ ' of file ' . bufname(v:beval_bufnr) .
|
||||
\ ' on word "' . v:beval_text . '"'
|
||||
@ -1026,6 +1026,9 @@ A jump table for the options with a short description can be found at |Q_op|.
|
||||
Vim does not try to send a message to an external debugger (Netbeans
|
||||
or Sun Workshop).
|
||||
|
||||
To check wether line breaks in the balloon text work use this check: >
|
||||
if has("balloon_multiline")
|
||||
<
|
||||
*'binary'* *'bin'* *'nobinary'* *'nobin'*
|
||||
'binary' 'bin' boolean (default off)
|
||||
local to buffer
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
*spell.txt* For Vim version 7.0aa. Last change: 2005 Jul 05
|
||||
*spell.txt* For Vim version 7.0aa. Last change: 2005 Jul 21
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@ -33,6 +33,11 @@ The words that are not recognized are highlighted with one of these:
|
||||
|
||||
Vim only checks words for spelling, there is no grammar check.
|
||||
|
||||
If the 'mousemodel' option is set to "popup" and the cursor is on a badly
|
||||
spelled word or it is "popup_setpos" and the mouse pointer is on a badly
|
||||
spelled word, then the popup menu will contain an submenu to replace the bad
|
||||
word. Note: this slows down the appearance of the popup menu.
|
||||
|
||||
To search for the next misspelled word:
|
||||
|
||||
*]s* *E756*
|
||||
|
||||
@ -3827,6 +3827,7 @@ Mac-format editing.txt /*Mac-format*
|
||||
Mac-format-write editing.txt /*Mac-format-write*
|
||||
Macintosh os_mac.txt /*Macintosh*
|
||||
Mark motion.txt /*Mark*
|
||||
MenuPopup autocmd.txt /*MenuPopup*
|
||||
MiNT os_mint.txt /*MiNT*
|
||||
Moolenaar intro.txt /*Moolenaar*
|
||||
MorphOS os_amiga.txt /*MorphOS*
|
||||
@ -5014,6 +5015,7 @@ garbagecollect() eval.txt /*garbagecollect()*
|
||||
gd pattern.txt /*gd*
|
||||
ge motion.txt /*ge*
|
||||
get() eval.txt /*get()*
|
||||
getbufline() eval.txt /*getbufline()*
|
||||
getbufvar() eval.txt /*getbufvar()*
|
||||
getchar() eval.txt /*getchar()*
|
||||
getcharmod() eval.txt /*getcharmod()*
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
" You can also use this as a start for your own set of menus.
|
||||
"
|
||||
" Maintainer: Bram Moolenaar <Bram@vim.org>
|
||||
" Last Change: 2005 Jul 08
|
||||
" Last Change: 2005 Jul 21
|
||||
|
||||
" Note that ":an" (short for ":anoremenu") is often used to make a menu work
|
||||
" in all modes and avoid side effects from mappings defined by the user.
|
||||
@ -873,6 +873,61 @@ noremenu <script> <silent> 1.100 PopUp.Select\ &All :<C-U>call <SID>SelectAll()
|
||||
inoremenu <script> <silent> 1.100 PopUp.Select\ &All <C-O>:call <SID>SelectAll()<CR>
|
||||
cnoremenu <script> <silent> 1.100 PopUp.Select\ &All <C-U>call <SID>SelectAll()<CR>
|
||||
|
||||
if has("spell")
|
||||
" Spell suggestions in the popup menu. Note that this will slow down the
|
||||
" appearance of the menu!
|
||||
func! <SID>SpellPopup()
|
||||
if exists("s:changeitem") && s:changeitem != ''
|
||||
call <SID>SpellDel()
|
||||
endif
|
||||
|
||||
let curcol = col('.')
|
||||
let w = spellbadword()
|
||||
if col('.') > curcol " don't use word after the cursor
|
||||
let w = ''
|
||||
call cursor(0, curcol) " put the cursor back where it was
|
||||
endif
|
||||
if w != ''
|
||||
let s:suglist = spellsuggest(w, 10)
|
||||
if len(s:suglist) <= 0
|
||||
call cursor(0, curcol) " put the cursor back where it was
|
||||
else
|
||||
let s:changeitem = 'change\ "' . escape(w, ' .'). '"\ to'
|
||||
let s:fromword = w
|
||||
let pri = 1
|
||||
for sug in s:suglist
|
||||
exe 'amenu 1.5.' . pri . ' PopUp.' . s:changeitem . '.' . escape(sug, ' .')
|
||||
\ . ' :call <SID>SpellReplace(' . pri . ')<CR>'
|
||||
let pri += 1
|
||||
endfor
|
||||
|
||||
let s:additem = 'add\ "' . escape(w, ' .') . '"\ to\ word\ list'
|
||||
exe 'amenu 1.6 PopUp.' . s:additem . ' :spellgood ' . w . '<CR>'
|
||||
|
||||
let s:ignoreitem = 'ignore\ "' . escape(w, ' .') . '"'
|
||||
exe 'amenu 1.7 PopUp.' . s:ignoreitem . ' :spellgood! ' . w . '<CR>'
|
||||
|
||||
amenu 1.8 PopUp.-SpellSep- :
|
||||
endif
|
||||
endif
|
||||
endfunc
|
||||
|
||||
func! <SID>SpellReplace(n)
|
||||
let l = getline('.')
|
||||
call setline('.', strpart(l, 0, col('.') - 1) . s:suglist[a:n - 1]
|
||||
\ . strpart(l, col('.') + len(s:fromword) - 1))
|
||||
endfunc
|
||||
|
||||
func! <SID>SpellDel()
|
||||
exe "aunmenu PopUp." . s:changeitem
|
||||
exe "aunmenu PopUp." . s:additem
|
||||
exe "aunmenu PopUp." . s:ignoreitem
|
||||
aunmenu PopUp.-SpellSep-
|
||||
let s:changeitem = ''
|
||||
endfun
|
||||
|
||||
au! MenuPopup * call <SID>SpellPopup()
|
||||
endif
|
||||
|
||||
" The GUI toolbar (for MS-Windows and GTK)
|
||||
if has("toolbar")
|
||||
|
||||
Reference in New Issue
Block a user