mirror of
https://github.com/vim/vim.git
synced 2025-07-26 11:04:33 -04:00
updated for version 7.0214
This commit is contained in:
parent
87b5ca5172
commit
768b8c4dbc
@ -1,4 +1,4 @@
|
|||||||
*todo.txt* For Vim version 7.0aa. Last change: 2006 Mar 03
|
*todo.txt* For Vim version 7.0aa. Last change: 2006 Mar 04
|
||||||
|
|
||||||
|
|
||||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||||
@ -30,55 +30,41 @@ be worked on, but only if you sponsor Vim development. See |sponsor|.
|
|||||||
*known-bugs*
|
*known-bugs*
|
||||||
-------------------- Known bugs and current work -----------------------
|
-------------------- Known bugs and current work -----------------------
|
||||||
|
|
||||||
Function to get and restore window position? Including topline, column
|
Add options to optwin.vim:
|
||||||
offset, etc. Use dictionary to store the info?
|
tabpagemax
|
||||||
|
tabline
|
||||||
|
showtabline
|
||||||
|
guitablabel
|
||||||
|
formatexpr
|
||||||
|
|
||||||
Crash with X command server (Ciaran McCreesh).
|
Add options to quickref.txt:
|
||||||
|
guitablabel
|
||||||
Ctags still hasn't included the patch. Darren is looking for someone to do
|
showtabline
|
||||||
maintanance. Is there another solution?
|
tabline
|
||||||
|
tabpagemax
|
||||||
|
|
||||||
spelling:
|
spelling:
|
||||||
- Also use the spelling dictionary for dictionary completion.
|
|
||||||
-> proper case compare against pattern, also for multi-byte
|
|
||||||
- Using KEEPCASE flag still allows all-upper word, docs say it doesn't.
|
|
||||||
Don't allow it, because there is no other way to do this.
|
|
||||||
- Use runtime/cleanadd script to cleanup .add files. When to invoke it?
|
|
||||||
After deleting a word with "zw" and some timestamp difference perhaps?
|
|
||||||
Store it as spell/cleanadd.vim.
|
|
||||||
- Have "zg" and "zw" report the file that was modified. (Marvin Renich)
|
|
||||||
- Add a command like "zg" that selects one of the files in 'spellfile'.
|
|
||||||
- Add a "zug" command that undoes "zg"? Deletes the good word instead of
|
|
||||||
adding a bad word like "zw" would. Use "zuw" to undo "zw"? (Antonio
|
|
||||||
Colombo)
|
|
||||||
|
|
||||||
- Rename COMPOUNDFLAGS to COMPOUNDPATTERN or COMPOUNDRULE?
|
- Rename COMPOUNDFLAGS to COMPOUNDPATTERN or COMPOUNDRULE?
|
||||||
Hunspell now uses COMPOUND with a count.
|
Hunspell now uses COMPOUND with a count.
|
||||||
- Check out Hunspell 1.1.3.
|
- Check out Hunspell 1.1.3.
|
||||||
|
Try to make the newly added features compatible.
|
||||||
what does MAXNGRAMSUGS do?
|
what does MAXNGRAMSUGS do?
|
||||||
See announcement (Nemeth, 5 jan)
|
See announcement (Nemeth, 5 jan)
|
||||||
is COMPLEXPREFIXES necessary now that we have flags for affixes?
|
is COMPLEXPREFIXES necessary now that we have flags for affixes?
|
||||||
- Look into hungarian dictionary:
|
- Look into Hungarian dictionary:
|
||||||
http://magyarispell.sourceforge.net/hu_HU-1.0.tar.gz
|
http://magyarispell.sourceforge.net/hu_HU-1.0.tar.gz
|
||||||
- Support flags on a suffix. Used for second level affixes, rare and
|
|
||||||
nocomp. The flags may also be used for compounding. Default is an OR
|
|
||||||
mechanism with the flags of the word. Adding "compset" on the affixes
|
|
||||||
means the compound flags of the word are not used.
|
|
||||||
Instead of "SFX a 0 add/FLAGS ." we could use "SFX a 0 add . /FLAGS" (or
|
|
||||||
support both).
|
|
||||||
- When compounding Hunspell doesn't allow affixes inside the compound word,
|
- When compounding Hunspell doesn't allow affixes inside the compound word,
|
||||||
only before and after it. COMPOUNDPERMITFLAG can be used to allow it.
|
only before and after it. COMPOUNDPERMITFLAG can be used to allow it.
|
||||||
Check Myspell and Aspell if they also work this way.
|
Check Myspell and Aspell if they also work this way.
|
||||||
Thus a word + suffix needs a flag that it can't be used with a following
|
Thus a word + suffix needs a flag that it can't be used with a following
|
||||||
compound, and word + prefix can't be after another word in a compound.
|
compound, and word + prefix can't be after another word in a compound.
|
||||||
- Implement COMPOUNDFORBIDFLAG .
|
- Implement COMPOUNDFORBIDFLAG .
|
||||||
- Support breakpoint character · 0xb7 and ignore it? Makes it possible to use
|
|
||||||
same wordlist for hyphenation.
|
|
||||||
|
|
||||||
Is it possible to keep the command-line window open? Would actually work like
|
|
||||||
closing it, executing the command and re-opening it (at the same position).
|
|
||||||
|
|
||||||
Mac unicode patch (Da Woon Jung):
|
Mac unicode patch (Da Woon Jung):
|
||||||
|
- Mac: Unicode input and display (Eckehard Berns, 2004 June 27)
|
||||||
|
Other patch from Da Woon Jung, 2005 Jan 16.
|
||||||
|
8 Add patch from Muraoka Taro (Mar 16) to support input method on Mac?
|
||||||
|
New patch 2004 Jun 16
|
||||||
- configuration option for platform: i386, ppc or both.
|
- configuration option for platform: i386, ppc or both.
|
||||||
Use __LITTLE_ENDIAN__ to test for current platform.
|
Use __LITTLE_ENDIAN__ to test for current platform.
|
||||||
- selecting proportional font breaks display
|
- selecting proportional font breaks display
|
||||||
@ -89,18 +75,25 @@ Mac unicode patch (Da Woon Jung):
|
|||||||
- With 'nopaste' pasting is wrong, with 'paste' Command-V doesn't work.
|
- With 'nopaste' pasting is wrong, with 'paste' Command-V doesn't work.
|
||||||
(Alan Schmitt)
|
(Alan Schmitt)
|
||||||
|
|
||||||
Patch to add a few flags to search(). (Benji Fisher, Nov 29, doc update Dec 1)
|
8 Support four composing/combining characters, needed for Hebrew. (Ron Aaron)
|
||||||
|
Add the 'maxcombining' option to set the nr. of composing characters.
|
||||||
|
At the same time support 32 bit Unicode characters?
|
||||||
|
8 "ga" should show all composing characters, also if there are more than 2.
|
||||||
|
8 Searching for a composing character by itself should work. Perhaps "."
|
||||||
|
with a composing char should work too.
|
||||||
|
|
||||||
Win32: Use the free downloadable compiler 7.1 (2003). Figure out how to do
|
Win32: Use the free downloadable compiler 7.1 (2003). Figure out how to do
|
||||||
debugging (with Agide?) and describe it. (George Reilly)
|
debugging (with Agide?) and describe it. (George Reilly)
|
||||||
Try out using the free MS compiler and debugger, using Make_mvc.mak.
|
Try out using the free MS compiler and debugger, using Make_mvc.mak.
|
||||||
Try using Visual C++ Express 2005. (Ilya Bobir Dec 20)
|
Also generate the .pdb file that can be used to generate a useful crash report
|
||||||
Disadvantage: Annoying warning messages, requires ..._NO_DEPRECATE, this
|
on MS-Windows. (George Reilly)
|
||||||
is not a standard compiler.
|
|
||||||
|
|
||||||
Win32: Check that installer puts menu items in "all users" dir when possible,
|
Win32: Check that installer puts menu items in "all users" dir when possible,
|
||||||
not administrator dir.
|
not administrator dir.
|
||||||
|
|
||||||
|
When "= evaluation results in a List, use it as a sequence of lines.
|
||||||
|
As if join(list, "\n") was used.
|
||||||
|
|
||||||
Autoload:
|
Autoload:
|
||||||
- Add a Vim script in $VIMRUNTIME/tools that takes a file with a list of
|
- Add a Vim script in $VIMRUNTIME/tools that takes a file with a list of
|
||||||
script names and a help file and produces a script that can be sourced to
|
script names and a help file and produces a script that can be sourced to
|
||||||
@ -112,22 +105,12 @@ Autoload:
|
|||||||
helpfile doc/myscript.txt
|
helpfile doc/myscript.txt
|
||||||
For the "helpfile" item ":helptags" is run.
|
For the "helpfile" item ":helptags" is run.
|
||||||
|
|
||||||
Add ":smap", Select mode mapping? Otherwise: ":sunmap", so that Visual mode
|
|
||||||
mappings for normal keys can be removed from Select mode.
|
|
||||||
|
|
||||||
When expanding on the command line, recognize shell commands, such as ":!cmd".
|
When expanding on the command line, recognize shell commands, such as ":!cmd".
|
||||||
Complete command names by searching in $PATH. When completing file names
|
Complete command names by searching in $PATH. When completing file names
|
||||||
escape special characters ";&<>(){}". (Adri Verhoef)
|
escape special characters ";&<>(){}". (Adri Verhoef)
|
||||||
|
|
||||||
Are there more commands where v:swapcommand can be set to something useful?
|
Are there more commands where v:swapcommand can be set to something useful?
|
||||||
|
|
||||||
Put autocommand event names in a hashtable for faster lookup?
|
|
||||||
|
|
||||||
Awaiting response:
|
|
||||||
- Win32: tearoff menu window should have a scrollbar when it's taller than
|
|
||||||
the screen.
|
|
||||||
- mblen(NULL, 0) also in Vim 6.3?
|
|
||||||
|
|
||||||
|
|
||||||
CONSIDERED FOR VERSION 7.0:
|
CONSIDERED FOR VERSION 7.0:
|
||||||
|
|
||||||
@ -148,8 +131,8 @@ Omni completion:
|
|||||||
characters/strings. (Martin Stubenschrott)
|
characters/strings. (Martin Stubenschrott)
|
||||||
And/or: Provide a function to popup the menu, so that an insert mode
|
And/or: Provide a function to popup the menu, so that an insert mode
|
||||||
mapping can start it (with a specific selection).
|
mapping can start it (with a specific selection).
|
||||||
- GUI implementation of the popup menu.
|
- Show "info" from a match in preview window (with an option or by opening
|
||||||
- Show "info" from a match in preview window.
|
a preview window with a specific name).
|
||||||
Or use one window for matches, another for context/info (Doug Kearns,
|
Or use one window for matches, another for context/info (Doug Kearns,
|
||||||
2005 Sep 13)
|
2005 Sep 13)
|
||||||
- Ideas on: http://www.wholetomato.com/
|
- Ideas on: http://www.wholetomato.com/
|
||||||
@ -199,46 +182,11 @@ Omni completion:
|
|||||||
Show the list of changes in a window to be able to select a version?
|
Show the list of changes in a window to be able to select a version?
|
||||||
Also: See ":e" as a change operation, find the changes and add them to the
|
Also: See ":e" as a change operation, find the changes and add them to the
|
||||||
undo info. Needed for when an external tool changes the file.
|
undo info. Needed for when an external tool changes the file.
|
||||||
- PERSISTENT UNDO: store undo in a file.
|
|
||||||
Use timestamps, so that a version a certain time ago can be found and info
|
|
||||||
before some time/date can be flushed. 'undopersist' gives maximum time to
|
|
||||||
keep undo: "3h", "1d", "2w", "1y", etc. For the file use dot and
|
|
||||||
extension: ".filename.un~" (like swapfile but "un~" instead of "swp").
|
|
||||||
- EMBEDDING: Make it possible to run Vim inside a window of another program.
|
- EMBEDDING: Make it possible to run Vim inside a window of another program.
|
||||||
For Xwindows this can be done with XReparentWindow().
|
For Xwindows this can be done with XReparentWindow().
|
||||||
For GTK Neil Bird has a patch to use Vim like a widget.
|
For GTK Neil Bird has a patch to use Vim like a widget.
|
||||||
- Add COLUMN NUMBERS to ":" commands ":line1,line2[col1,col2]cmd". Block
|
|
||||||
can be selected with CTRL-V. Allow '$' (end of line) for col2.
|
|
||||||
- Add DEBUGGER INTERFACE. Implementation for gdb by Xavier de Gaye.
|
|
||||||
Should work like an IDE. Try to keep it generic. Now found here:
|
|
||||||
http://clewn.sf.net.
|
|
||||||
And the idevim plugin/script.
|
|
||||||
To be able to start the debugger from inside Vim: For GUI run a program
|
|
||||||
with a netbeans connection; for console: start a program that splits the
|
|
||||||
terminal, runs the debugger in one window and reconnect Vim I/O to the
|
|
||||||
other window.
|
|
||||||
Wishes for NetBeans commands:
|
|
||||||
- make it possible to have 'defineAnnoType' also handle terminal colors.
|
|
||||||
- send 'balloonText' events for the cursor position (using CursorHold ?)
|
|
||||||
in terminal mode.
|
|
||||||
- ECLIPSE plugin. Problem is: the interface is very complicated. Need to
|
|
||||||
implement part in Java and then connect to Vim. Some hints from Alexandru
|
|
||||||
Roman, 2004 Dec 15. Should then also work with Oracle Jdeveloper, see JSR
|
|
||||||
198 standard http://www.jcp.org/en/jsr/detail?id=198.
|
|
||||||
Eclim does it: http://eclim.sourceforge.net/ (Eric Van Dewoestine)
|
|
||||||
Plugin that uses a terminal emulator: http://vimplugin.sf.net
|
|
||||||
- STICKY CURSOR: Add a way of scrolling that leaves the cursor where it is.
|
|
||||||
Especially when using the scrollbar. Typing a cursor-movement command
|
|
||||||
scrolls back to where the cursor is.
|
|
||||||
- Execute a function with standard option values. No need to save and
|
|
||||||
restore option values. Especially useful for new options. Problem: how
|
|
||||||
to avoid a performance penalty (esp. for string options)?
|
|
||||||
8 Support four composing/combining characters, needed for Hebrew. (Ron Aaron)
|
|
||||||
Add the 'maxcombining' option to set the nr. of composing characters.
|
|
||||||
At the same time support 32 bit Unicode characters?
|
|
||||||
8 "ga" should show all composing characters, also if there are more than 2.
|
|
||||||
8 Searching for a composing character by itself should work. Perhaps "."
|
|
||||||
with a composing char should work too.
|
|
||||||
- Add a few more things to 'diffopt': "horizontal", "vertical",
|
- Add a few more things to 'diffopt': "horizontal", "vertical",
|
||||||
"foldcolumn". (Benji Fisher, 2004 Jun 21)
|
"foldcolumn". (Benji Fisher, 2004 Jun 21)
|
||||||
- FileChangedShellPost autocommand event: after (not) reloading a changed
|
- FileChangedShellPost autocommand event: after (not) reloading a changed
|
||||||
@ -248,15 +196,6 @@ Omni completion:
|
|||||||
It's not clear that this doesn't cause problems when the executed
|
It's not clear that this doesn't cause problems when the executed
|
||||||
commands do something like changing 'lines'. Esp. because the
|
commands do something like changing 'lines'. Esp. because the
|
||||||
screen has not yet been allocated with the new size.
|
screen has not yet been allocated with the new size.
|
||||||
- Running a shell command from the GUI still has limitations. Look into how
|
|
||||||
the Vim shell project can help: http://vimshell.wana.at
|
|
||||||
- Displaying size of Visual area: use 24-33 column display.
|
|
||||||
When selecting multiple lines, up to about a screenful, also count the
|
|
||||||
characters.
|
|
||||||
- Mac: Unicode input and display (Eckehard Berns, 2004 June 27)
|
|
||||||
Other patch from Da Woon Jung, 2005 Jan 16.
|
|
||||||
8 Add patch from Muraoka Taro (Mar 16) to support input method on Mac?
|
|
||||||
New patch 2004 Jun 16
|
|
||||||
9 Add cursor-column highlighting. Enable it with 'cursorcolumn' option,
|
9 Add cursor-column highlighting. Enable it with 'cursorcolumn' option,
|
||||||
set highlighting with "CursorColumn" group. Useful for aligning text.
|
set highlighting with "CursorColumn" group. Useful for aligning text.
|
||||||
Also cursor-row highlighting. Patch from Yasuhiro Matsumoto for
|
Also cursor-row highlighting. Patch from Yasuhiro Matsumoto for
|
||||||
@ -269,78 +208,43 @@ Omni completion:
|
|||||||
- When using 'incsearch" CTRL-R CTRL-W gets the word under the cursor, but
|
- When using 'incsearch" CTRL-R CTRL-W gets the word under the cursor, but
|
||||||
the part that already matched is doubled then. Remove the part of the
|
the part that already matched is doubled then. Remove the part of the
|
||||||
word that would be doubled. Make it work line CTRL-N in Insert mode.
|
word that would be doubled. Make it work line CTRL-N in Insert mode.
|
||||||
- Add Lua interface? (Wolfgang Oertl)
|
|
||||||
- "onemore" flag in 'virtualedit': move cursor past end of line. Patch by
|
- "onemore" flag in 'virtualedit': move cursor past end of line. Patch by
|
||||||
Mattias Flodin (2004 Jul 30)
|
Mattias Flodin (2004 Jul 30)
|
||||||
- In a :s command multi-byte characters should also be upper/lower cased
|
- In a :s command multi-byte characters should also be upper/lower cased
|
||||||
with \u, \U, etc.
|
with \u, \U, etc.
|
||||||
8 Add a command to jump to a certain kind of tag. Allow the user to specify
|
|
||||||
values for the optional fields. E.g., ":tag size type=m".
|
|
||||||
Also allow specifying the file and command, so that the result of
|
|
||||||
taglist() can be used.
|
|
||||||
|
|
||||||
Adjust src/main.aap for installing manpages like in Makefile.
|
- Adjust src/main.aap for installing manpages like in Makefile.
|
||||||
And for generating Vim.app for the Mac.
|
And for generating Vim.app for the Mac.
|
||||||
Install spell files with src/main.aap.
|
Install spell files with src/main.aap.
|
||||||
|
|
||||||
When editing a file with both utf-8 and latin1 text Vim always falls back to
|
- Add command to search for illegal utf-8 byte sequence.
|
||||||
latin1. Add a command to convert the latin1 characters to utf-8?
|
|
||||||
:unmix utf-8,latin1 filename
|
|
||||||
Would only work when 'encoding' is utf-8.
|
|
||||||
Also: command to search for illegal utf-8 byte sequence?
|
|
||||||
|
|
||||||
Also generate the .pdb file that can be used to generate a useful crash report
|
|
||||||
on MS-Windows. (George Reilly)
|
|
||||||
|
|
||||||
Add strtol() to avoid the problems with leading zero causing octal conversion.
|
Add strtol() to avoid the problems with leading zero causing octal conversion.
|
||||||
|
|
||||||
Try new POSIX tests, made after my comments. (Geoff Clare, 2005 April 7)
|
|
||||||
Version 1.5 is in ~/src/posix/1.5. (Lynne Canal)
|
|
||||||
|
|
||||||
Add a 'tool' window: behaves like a preview window but there can be several.
|
Add a 'tool' window: behaves like a preview window but there can be several.
|
||||||
Don't count it in only_one_window(). (Alexei Alexandrov)
|
Don't count it in only_one_window(). (Alexei Alexandrov)
|
||||||
|
|
||||||
Win32: Patch for Korean IME. (Yusung, 2005 March 21)
|
Win32: Patch for Korean IME. (Yusung, 2005 March 21)
|
||||||
|
|
||||||
When "= evaluation results in a List, use it as a sequence of lines.
|
|
||||||
|
|
||||||
Support ":set syntax=cpp.doxygen"? Suggested patch by Michael Geddes (9 Aug
|
Support ":set syntax=cpp.doxygen"? Suggested patch by Michael Geddes (9 Aug
|
||||||
2004). Should also work for 'filetype'.
|
2004). Should also work for 'filetype'.
|
||||||
|
|
||||||
For manipulating buffers without opening a new window, support Virtual
|
|
||||||
windows. Example:
|
|
||||||
:virtwin let l = GetBufLine(4, 10)
|
|
||||||
:fun GetBufLine(bufnr, lnum)
|
|
||||||
: exe "buffer " . a:bufnr
|
|
||||||
: return getline(lnum)
|
|
||||||
:endfun
|
|
||||||
The getline() and setline() functions could work for other buffers, using a
|
|
||||||
Virtual window.
|
|
||||||
A Virtual window only exists for one command. There can be several (for
|
|
||||||
nested commands). The window works as if it comes after the last window, size
|
|
||||||
is the Vim window size, but it's never displayed.
|
|
||||||
|
|
||||||
Win32: In the generated batch files, use $VIMRUNTIME if it's set. Examples by
|
Win32: In the generated batch files, use $VIMRUNTIME if it's set. Examples by
|
||||||
Mathias Michaelis (2004 Sep 6)
|
Mathias Michaelis (2004 Sep 6)
|
||||||
Also place vimtutor.bat in %windir%?
|
Also place vimtutor.bat in %windir%?
|
||||||
|
|
||||||
Add gui_mch_browsedir() for Motif, Mac OS/X.
|
Ctags still hasn't included the patch. Darren is looking for someone to do
|
||||||
|
maintanance. Is there another solution?
|
||||||
|
|
||||||
HTML indenting can be slow, find out why. Any way to do some kind of
|
HTML indenting can be slow, find out why.
|
||||||
profiling for Vim script? At least add a function to get the current time in
|
Add a function to get the current time in usec. reltime([start, [end]])
|
||||||
usec. reltime([start, [end]])
|
|
||||||
reltime().sec == seconds, reltime().usec = microseconds
|
reltime().sec == seconds, reltime().usec = microseconds
|
||||||
reltime(start) current time relative to [start]
|
reltime(start) current time relative to [start]
|
||||||
echo timestring(reltime(start), 3) (3 is nr of digits after dot)
|
echo timestring(reltime(start), 3) (3 is nr of digits after dot)
|
||||||
reltime(start, end) difference between start and end
|
reltime(start, end) difference between start and end
|
||||||
Real Profiling:
|
Profiling:
|
||||||
- :profile start /tmp/somefile (append if exists)
|
|
||||||
- :profile pause
|
- :profile pause
|
||||||
- :profile resume
|
- :profile resume
|
||||||
- :profile stop
|
|
||||||
- per function line
|
|
||||||
- self, Vim and total time (incl system time)
|
|
||||||
- dump results in file on exit or when stopped.
|
|
||||||
|
|
||||||
Add more tests for all new functionality in Vim 7. Especially new functions.
|
Add more tests for all new functionality in Vim 7. Especially new functions.
|
||||||
|
|
||||||
@ -351,22 +255,20 @@ Jan 6)
|
|||||||
Add a flag to check for a match with the next item first? Helps for
|
Add a flag to check for a match with the next item first? Helps for
|
||||||
continuation lines that may contain just about anything.
|
continuation lines that may contain just about anything.
|
||||||
|
|
||||||
|
Add ":smap", Select mode mapping? Otherwise: ":sunmap", so that Visual mode
|
||||||
|
mappings for normal keys can be removed from Select mode.
|
||||||
|
|
||||||
|
Check if file explorer can handle directory names and links with a single
|
||||||
|
quote. (Nieko Maatjes, 2005 Jan 4)
|
||||||
|
|
||||||
|
|
||||||
Awaiting updated patches:
|
Awaiting updated patches:
|
||||||
--- awaiting updated patch ---
|
|
||||||
8 Add ":n" to fnamemodify(): normalize path, remove "../" when possible.
|
8 Add ":n" to fnamemodify(): normalize path, remove "../" when possible.
|
||||||
Aric Blumer has a patch for this.
|
Aric Blumer has a patch for this.
|
||||||
He will update the patch for 6.3.
|
He will update the patch for 6.3.
|
||||||
Autocommands:
|
|
||||||
7 Completion of network shares, patch by Yasuhiro Matsumoto.
|
7 Completion of network shares, patch by Yasuhiro Matsumoto.
|
||||||
Update 2004 Sep 6.
|
Update 2004 Sep 6.
|
||||||
How does this work? Missing comments.
|
How does this work? Missing comments.
|
||||||
- gettext() Translate a message. (Patch from Yasuhiro Matsumoto)
|
|
||||||
Update 2004 Sep 10
|
|
||||||
Another patch from Edward L. Fox (2005 Nov 24)
|
|
||||||
Search in 'runtimepath'?
|
|
||||||
More docs about how to use this.
|
|
||||||
How to get the messages into the .po files?
|
|
||||||
--- did not respond (yet) --
|
|
||||||
- Patch for 'breakindent' option: repeat indent for wrapped line. (Vaclav
|
- Patch for 'breakindent' option: repeat indent for wrapped line. (Vaclav
|
||||||
Smilauer, 2004 Sep 13, fix Oct 31)
|
Smilauer, 2004 Sep 13, fix Oct 31)
|
||||||
Asked for improvements 2004 Dec 20.
|
Asked for improvements 2004 Dec 20.
|
||||||
@ -392,6 +294,12 @@ Awaiting updated patches:
|
|||||||
line in between columns (e.g., for 'textwidth').
|
line in between columns (e.g., for 'textwidth').
|
||||||
Patch to add 'hlcolumn' from Vit Stradal, 2004 May 20.
|
Patch to add 'hlcolumn' from Vit Stradal, 2004 May 20.
|
||||||
8 Add functions:
|
8 Add functions:
|
||||||
|
gettext() Translate a message. (Patch from Yasuhiro Matsumoto)
|
||||||
|
Update 2004 Sep 10
|
||||||
|
Another patch from Edward L. Fox (2005 Nov 24)
|
||||||
|
Search in 'runtimepath'?
|
||||||
|
More docs about how to use this.
|
||||||
|
How to get the messages into the .po files?
|
||||||
confirm() add "flags" argument, with 'v' for vertical
|
confirm() add "flags" argument, with 'v' for vertical
|
||||||
layout and 'c' for console dialog. (Haegg)
|
layout and 'c' for console dialog. (Haegg)
|
||||||
Flemming Madsen has a patch for the 'c' flag
|
Flemming Madsen has a patch for the 'c' flag
|
||||||
@ -431,14 +339,12 @@ Awaiting updated patches:
|
|||||||
Win32: the text to replace with isn't remembered.
|
Win32: the text to replace with isn't remembered.
|
||||||
- For GUI Find/Replace dialog support using a regexp. Patch for Motif
|
- For GUI Find/Replace dialog support using a regexp. Patch for Motif
|
||||||
and GTK by degreneir (nov 10 and nov 18).
|
and GTK by degreneir (nov 10 and nov 18).
|
||||||
|
- Patch for "paranoid mode" by Kevin Collins, March 7. Needs much more work.
|
||||||
Patch for "paranoid mode" by Kevin Collins, March 7. Needs much more work.
|
|
||||||
|
|
||||||
Check if file explorer can handle directory names and links with a single
|
|
||||||
quote. (Nieko Maatjes, 2005 Jan 4)
|
|
||||||
|
|
||||||
|
|
||||||
Vi incompatibility:
|
Vi incompatibility:
|
||||||
|
- Try new POSIX tests, made after my comments. (Geoff Clare, 2005 April 7)
|
||||||
|
Version 1.5 is in ~/src/posix/1.5. (Lynne Canal)
|
||||||
8 With undo/redo only marks in the changed lines should be changed. Other
|
8 With undo/redo only marks in the changed lines should be changed. Other
|
||||||
marks should be kept. Vi keeps each mark at the same text, even when it
|
marks should be kept. Vi keeps each mark at the same text, even when it
|
||||||
is deleted or restored. (Webb)
|
is deleted or restored. (Webb)
|
||||||
@ -515,6 +421,7 @@ GTK+ 1 (OK in GTK 2):
|
|||||||
appending "bold" when there are not 14 dashes.
|
appending "bold" when there are not 14 dashes.
|
||||||
|
|
||||||
GTK+ GUI known bugs:
|
GTK+ GUI known bugs:
|
||||||
|
9 Crash with X command server over ssh. (Ciaran McCreesh, 2006 Feb 6)
|
||||||
8 GTK 2: Combining UTF-8 characters not displayed properly in menus (Mikolaj
|
8 GTK 2: Combining UTF-8 characters not displayed properly in menus (Mikolaj
|
||||||
Machowski) They are displayed as separate characters. Problem in
|
Machowski) They are displayed as separate characters. Problem in
|
||||||
creating a label?
|
creating a label?
|
||||||
@ -527,6 +434,8 @@ GTK+ GUI known bugs:
|
|||||||
It starts working after GTK gvim loses the selection and gains it again.
|
It starts working after GTK gvim loses the selection and gains it again.
|
||||||
|
|
||||||
Win32 GUI known bugs:
|
Win32 GUI known bugs:
|
||||||
|
- Win32: tearoff menu window should have a scrollbar when it's taller than
|
||||||
|
the screen.
|
||||||
8 On Windows 98 the unicows library is needed to support functions with UCS2
|
8 On Windows 98 the unicows library is needed to support functions with UCS2
|
||||||
file names. Can we load unicows.dll dynamically?
|
file names. Can we load unicows.dll dynamically?
|
||||||
8 The -P argument doesn't work very well with many MDI applications.
|
8 The -P argument doesn't work very well with many MDI applications.
|
||||||
@ -662,6 +571,7 @@ Athena GUI:
|
|||||||
|
|
||||||
|
|
||||||
Motif GUI:
|
Motif GUI:
|
||||||
|
- gui_mch_browsedir() is missing.
|
||||||
7 Use XmStringCreateLocalized() instead of XmStringCreateSimple()?
|
7 Use XmStringCreateLocalized() instead of XmStringCreateSimple()?
|
||||||
David Harrison says it's OK (it exists in Motif 1.2).
|
David Harrison says it's OK (it exists in Motif 1.2).
|
||||||
8 Lesstif: When deleting a menu that's torn off, the torn off menu becomes
|
8 Lesstif: When deleting a menu that's torn off, the torn off menu becomes
|
||||||
@ -866,6 +776,7 @@ Amiga:
|
|||||||
|
|
||||||
|
|
||||||
Macintosh:
|
Macintosh:
|
||||||
|
- GUI: gui_mch_browsedir() is missing.
|
||||||
7 Patch to add 'transparency' option. Disadvantage: it's slow. (Eckehard
|
7 Patch to add 'transparency' option. Disadvantage: it's slow. (Eckehard
|
||||||
Berns, 2004 May 9) http://ecki.to/vim/TransBack-2004-05-09.diff
|
Berns, 2004 May 9) http://ecki.to/vim/TransBack-2004-05-09.diff
|
||||||
Needs more work. Add when someone really wants it.
|
Needs more work. Add when someone really wants it.
|
||||||
@ -1260,6 +1171,40 @@ Problems that will (probably) not be solved:
|
|||||||
--------------------- extensions and improvements ----------------------
|
--------------------- extensions and improvements ----------------------
|
||||||
*extensions-improvements*
|
*extensions-improvements*
|
||||||
|
|
||||||
|
Didn't make it into Vim 7.0:
|
||||||
|
- Add COLUMN NUMBERS to ":" commands ":line1,line2[col1,col2]cmd". Block
|
||||||
|
can be selected with CTRL-V. Allow '$' (end of line) for col2.
|
||||||
|
- Add DEBUGGER INTERFACE. Implementation for gdb by Xavier de Gaye.
|
||||||
|
Should work like an IDE. Try to keep it generic. Now found here:
|
||||||
|
http://clewn.sf.net.
|
||||||
|
And the idevim plugin/script.
|
||||||
|
To be able to start the debugger from inside Vim: For GUI run a program
|
||||||
|
with a netbeans connection; for console: start a program that splits the
|
||||||
|
terminal, runs the debugger in one window and reconnect Vim I/O to the
|
||||||
|
other window.
|
||||||
|
Wishes for NetBeans commands:
|
||||||
|
- make it possible to have 'defineAnnoType' also handle terminal colors.
|
||||||
|
- send 'balloonText' events for the cursor position (using CursorHold ?)
|
||||||
|
in terminal mode.
|
||||||
|
- ECLIPSE plugin. Problem is: the interface is very complicated. Need to
|
||||||
|
implement part in Java and then connect to Vim. Some hints from Alexandru
|
||||||
|
Roman, 2004 Dec 15. Should then also work with Oracle Jdeveloper, see JSR
|
||||||
|
198 standard http://www.jcp.org/en/jsr/detail?id=198.
|
||||||
|
Eclim does it: http://eclim.sourceforge.net/ (Eric Van Dewoestine)
|
||||||
|
Plugin that uses a terminal emulator: http://vimplugin.sf.net
|
||||||
|
- STICKY CURSOR: Add a way of scrolling that leaves the cursor where it is.
|
||||||
|
Especially when using the scrollbar. Typing a cursor-movement command
|
||||||
|
scrolls back to where the cursor is.
|
||||||
|
- Running a shell command from the GUI still has limitations. Look into how
|
||||||
|
the terminal emulator of the Vim shell project can help:
|
||||||
|
http://vimshell.wana.at
|
||||||
|
- Add Lua interface? (Wolfgang Oertl)
|
||||||
|
8 Add a command to jump to a certain kind of tag. Allow the user to specify
|
||||||
|
values for the optional fields. E.g., ":tag size type=m".
|
||||||
|
Also allow specifying the file and command, so that the result of
|
||||||
|
taglist() can be used.
|
||||||
|
|
||||||
|
|
||||||
Documentation:
|
Documentation:
|
||||||
8 The GUI help should explain the Find and Find/Replace dialogs. Add a link
|
8 The GUI help should explain the Find and Find/Replace dialogs. Add a link
|
||||||
to it from ":promptrepl" and ":promptfind".
|
to it from ":promptrepl" and ":promptfind".
|
||||||
@ -1357,6 +1302,14 @@ Tab pages:
|
|||||||
|
|
||||||
Spell checking:
|
Spell checking:
|
||||||
- suggestion for "KG" to "kg" when it's keepcase.
|
- suggestion for "KG" to "kg" when it's keepcase.
|
||||||
|
- Support flags on a suffix. Used for second level affixes, rare and
|
||||||
|
nocomp. The flags may also be used for compounding. Default is an OR
|
||||||
|
mechanism with the flags of the word. Adding "compset" on the affixes
|
||||||
|
means the compound flags of the word are not used.
|
||||||
|
Instead of "SFX a 0 add/FLAGS ." we could use "SFX a 0 add . /FLAGS" (or
|
||||||
|
support both).
|
||||||
|
- Support breakpoint character · 0xb7 and ignore it? Makes it possible to
|
||||||
|
use same wordlist for hyphenation.
|
||||||
- Compound word is accepted if nr of words is <= COMPOUNDMAX OR nr of
|
- Compound word is accepted if nr of words is <= COMPOUNDMAX OR nr of
|
||||||
syllables <= COMPOUNDSYLMAX. Specify using AND in the affix file?
|
syllables <= COMPOUNDSYLMAX. Specify using AND in the affix file?
|
||||||
- COMPOUNDMAX -> COMPOUNDWORDMAX?
|
- COMPOUNDMAX -> COMPOUNDWORDMAX?
|
||||||
@ -1461,6 +1414,10 @@ Folding:
|
|||||||
|
|
||||||
|
|
||||||
Multi-byte characters:
|
Multi-byte characters:
|
||||||
|
- When editing a file with both utf-8 and latin1 text Vim always falls back
|
||||||
|
to latin1. Add a command to convert the latin1 characters to utf-8?
|
||||||
|
:unmix utf-8,latin1 filename
|
||||||
|
Would only work when 'encoding' is utf-8.
|
||||||
9 When the tail byte of a double-byte character is illegal (e.g., a CR), the
|
9 When the tail byte of a double-byte character is illegal (e.g., a CR), the
|
||||||
display is messed up (Yasuhiro Matsumoto). Should check for illegal
|
display is messed up (Yasuhiro Matsumoto). Should check for illegal
|
||||||
double-byte characters and display them differently (display each single
|
double-byte characters and display them differently (display each single
|
||||||
@ -1701,6 +1658,9 @@ Syntax highlighting:
|
|||||||
|
|
||||||
|
|
||||||
Built-in script language:
|
Built-in script language:
|
||||||
|
7 Execute a function with standard option values. No need to save and
|
||||||
|
restore option values. Especially useful for new options. Problem: how
|
||||||
|
to avoid a performance penalty (esp. for string options)?
|
||||||
8 Add referring to key options with "&t_xx". Both for "echo &t_xx" and
|
8 Add referring to key options with "&t_xx". Both for "echo &t_xx" and
|
||||||
":let &t_xx =". Useful for making portable mappings.
|
":let &t_xx =". Useful for making portable mappings.
|
||||||
8 exists("&&option") tests if 'option' is actually implemented. Useful for
|
8 exists("&&option") tests if 'option' is actually implemented. Useful for
|
||||||
@ -2181,6 +2141,7 @@ GUI:
|
|||||||
|
|
||||||
|
|
||||||
Autocommands:
|
Autocommands:
|
||||||
|
- Put autocommand event names in a hashtable for faster lookup?
|
||||||
7 For autocommand events that trigger multiple times per buffer (e.g.,
|
7 For autocommand events that trigger multiple times per buffer (e.g.,
|
||||||
CursorHold), go through the list once and cache the result for a specific
|
CursorHold), go through the list once and cache the result for a specific
|
||||||
buffer. Invalidate the cache when adding/deleting autocommands or
|
buffer. Invalidate the cache when adding/deleting autocommands or
|
||||||
@ -2265,6 +2226,7 @@ Autocommands:
|
|||||||
|
|
||||||
|
|
||||||
Insert mode completion/expansion:
|
Insert mode completion/expansion:
|
||||||
|
- GUI implementation of the popup menu.
|
||||||
8 When there is no word before the cursor but something like "sys." complete
|
8 When there is no word before the cursor but something like "sys." complete
|
||||||
with "sys.". Works well for C and similar languages.
|
with "sys.". Works well for C and similar languages.
|
||||||
9 ^X^L completion doesn't repeat correctly. It uses the first match with
|
9 ^X^L completion doesn't repeat correctly. It uses the first match with
|
||||||
@ -2608,6 +2570,9 @@ Visual mode:
|
|||||||
- When dragging the Visual selection with the mouse and 'scrolloff' is zero,
|
- When dragging the Visual selection with the mouse and 'scrolloff' is zero,
|
||||||
behave like 'scrolloff' is one, so that the text scrolls when the pointer
|
behave like 'scrolloff' is one, so that the text scrolls when the pointer
|
||||||
is in the top line.
|
is in the top line.
|
||||||
|
- Displaying size of Visual area: use 24-33 column display.
|
||||||
|
When selecting multiple lines, up to about a screenful, also count the
|
||||||
|
characters.
|
||||||
8 When using "I" or "A" in Visual block mode, short lines do not get the new
|
8 When using "I" or "A" in Visual block mode, short lines do not get the new
|
||||||
text. Make it possible to add the text to short lines too, with padding
|
text. Make it possible to add the text to short lines too, with padding
|
||||||
where needed.
|
where needed.
|
||||||
@ -2873,6 +2838,11 @@ Searching:
|
|||||||
|
|
||||||
|
|
||||||
Undo:
|
Undo:
|
||||||
|
- Persistent undo: store undo in a file.
|
||||||
|
Use timestamps, so that a version a certain time ago can be found and info
|
||||||
|
before some time/date can be flushed. 'undopersist' gives maximum time to
|
||||||
|
keep undo: "3h", "1d", "2w", "1y", etc. For the file use dot and
|
||||||
|
extension: ".filename.un~" (like swapfile but "un~" instead of "swp").
|
||||||
- Make it possible to undo all the commands from a mapping, including a
|
- Make it possible to undo all the commands from a mapping, including a
|
||||||
trailing unfinished command, e.g. for ":map K iX^[r".
|
trailing unfinished command, e.g. for ":map K iX^[r".
|
||||||
- When accidentally hitting "R" instead of Ctrl-R, further Ctrl-R is not
|
- When accidentally hitting "R" instead of Ctrl-R, further Ctrl-R is not
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
*version7.txt* For Vim version 7.0aa. Last change: 2006 Mar 02
|
*version7.txt* For Vim version 7.0aa. Last change: 2006 Mar 04
|
||||||
|
|
||||||
|
|
||||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||||
@ -608,6 +608,8 @@ New and extended functions: ~
|
|||||||
|taglist()| get list of matching tags (Yegappan Lakshmanan)
|
|taglist()| get list of matching tags (Yegappan Lakshmanan)
|
||||||
|tr()| translate characters (Ron Aaron)
|
|tr()| translate characters (Ron Aaron)
|
||||||
|values()| get List of Dictionary values
|
|values()| get List of Dictionary values
|
||||||
|
|winrestview()| restore the view of the current window
|
||||||
|
|winsaveview()| save the view of the current window
|
||||||
|writefile()| write a list of lines into a file
|
|writefile()| write a list of lines into a file
|
||||||
|
|
||||||
User defined functions can now be loaded automatically from the "autoload"
|
User defined functions can now be loaded automatically from the "autoload"
|
||||||
@ -821,7 +823,14 @@ Added the "count" argument to match(), matchend() and matchstr(). (Ilya Sher)
|
|||||||
winnr() takes an optional "$" and "#" arguments. (Nikolai Weibull, Yegappan
|
winnr() takes an optional "$" and "#" arguments. (Nikolai Weibull, Yegappan
|
||||||
Lakshmanan)
|
Lakshmanan)
|
||||||
|
|
||||||
|
Added 's' flag to search(): set ' mark if cursor moved. (Yegappan Lakshmanan)
|
||||||
Added 'n' flag to search(): don't move the cursor. (Nikolai Weibull)
|
Added 'n' flag to search(): don't move the cursor. (Nikolai Weibull)
|
||||||
|
Added 'c' flag to search(): accept match at the cursor.
|
||||||
|
Added 'e' flag to search(): move to end of the match. (Benji Fisher)
|
||||||
|
Added 'p' flag to search(): return number of sub-pattern. (Benji Fisher)
|
||||||
|
These also apply to searchpos(), searchpair() and searchpairpos().
|
||||||
|
The search() and searchpair() functions have an extra argument to specify
|
||||||
|
where to stop searching. Speeds up searches that should not continue too far.
|
||||||
|
|
||||||
When uncompressing fails in the gzip plugin, give an error message but don't
|
When uncompressing fails in the gzip plugin, give an error message but don't
|
||||||
delete the raw text. Helps if the file has a .gz extension but is not
|
delete the raw text. Helps if the file has a .gz extension but is not
|
||||||
@ -980,12 +989,6 @@ Lakshmanan)
|
|||||||
Win32: Balloons can have multiple lines if common controls supports it.
|
Win32: Balloons can have multiple lines if common controls supports it.
|
||||||
(Sergey Khorev)
|
(Sergey Khorev)
|
||||||
|
|
||||||
The 's' flag is added to the search() and searchpair() function to set the
|
|
||||||
' mark if the cursor is moved. (Yegappan Lakshmanan)
|
|
||||||
|
|
||||||
The search() and searchpair() functions have an extra argument to specify
|
|
||||||
where to stop searching. Speeds up searches that should not continue too far.
|
|
||||||
|
|
||||||
For 'errorformat' it was not possible to have a file name that contains the
|
For 'errorformat' it was not possible to have a file name that contains the
|
||||||
character that follows after "%f". For example, in "%f:%l:%m" the file name
|
character that follows after "%f". For example, in "%f:%l:%m" the file name
|
||||||
could not contain ":". Now include the first ":" where the rest of the
|
could not contain ":". Now include the first ":" where the rest of the
|
||||||
|
129
src/eval.c
129
src/eval.c
@ -645,6 +645,8 @@ static void f_winheight __ARGS((typval_T *argvars, typval_T *rettv));
|
|||||||
static void f_winline __ARGS((typval_T *argvars, typval_T *rettv));
|
static void f_winline __ARGS((typval_T *argvars, typval_T *rettv));
|
||||||
static void f_winnr __ARGS((typval_T *argvars, typval_T *rettv));
|
static void f_winnr __ARGS((typval_T *argvars, typval_T *rettv));
|
||||||
static void f_winrestcmd __ARGS((typval_T *argvars, typval_T *rettv));
|
static void f_winrestcmd __ARGS((typval_T *argvars, typval_T *rettv));
|
||||||
|
static void f_winrestview __ARGS((typval_T *argvars, typval_T *rettv));
|
||||||
|
static void f_winsaveview __ARGS((typval_T *argvars, typval_T *rettv));
|
||||||
static void f_winwidth __ARGS((typval_T *argvars, typval_T *rettv));
|
static void f_winwidth __ARGS((typval_T *argvars, typval_T *rettv));
|
||||||
static void f_writefile __ARGS((typval_T *argvars, typval_T *rettv));
|
static void f_writefile __ARGS((typval_T *argvars, typval_T *rettv));
|
||||||
|
|
||||||
@ -7054,6 +7056,8 @@ static struct fst
|
|||||||
{"winline", 0, 0, f_winline},
|
{"winline", 0, 0, f_winline},
|
||||||
{"winnr", 0, 1, f_winnr},
|
{"winnr", 0, 1, f_winnr},
|
||||||
{"winrestcmd", 0, 0, f_winrestcmd},
|
{"winrestcmd", 0, 0, f_winrestcmd},
|
||||||
|
{"winrestview", 1, 1, f_winrestview},
|
||||||
|
{"winsaveview", 0, 0, f_winsaveview},
|
||||||
{"winwidth", 1, 1, f_winwidth},
|
{"winwidth", 1, 1, f_winwidth},
|
||||||
{"writefile", 2, 3, f_writefile},
|
{"writefile", 2, 3, f_writefile},
|
||||||
};
|
};
|
||||||
@ -13200,11 +13204,13 @@ f_reverse(argvars, rettv)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#define SP_NOMOVE 1 /* don't move cursor */
|
#define SP_NOMOVE 0x01 /* don't move cursor */
|
||||||
#define SP_REPEAT 2 /* repeat to find outer pair */
|
#define SP_REPEAT 0x02 /* repeat to find outer pair */
|
||||||
#define SP_RETCOUNT 4 /* return matchcount */
|
#define SP_RETCOUNT 0x04 /* return matchcount */
|
||||||
#define SP_SETPCMARK 8 /* set previous context mark */
|
#define SP_SETPCMARK 0x08 /* set previous context mark */
|
||||||
#define SP_START 16 /* accept match at start position */
|
#define SP_START 0x10 /* accept match at start position */
|
||||||
|
#define SP_SUBPAT 0x20 /* return nr of matching sub-pattern */
|
||||||
|
#define SP_END 0x40 /* leave cursor at end of match */
|
||||||
|
|
||||||
static int get_search_arg __ARGS((typval_T *varp, int *flagsp));
|
static int get_search_arg __ARGS((typval_T *varp, int *flagsp));
|
||||||
|
|
||||||
@ -13239,11 +13245,13 @@ get_search_arg(varp, flagsp)
|
|||||||
if (flagsp != NULL)
|
if (flagsp != NULL)
|
||||||
switch (*flags)
|
switch (*flags)
|
||||||
{
|
{
|
||||||
case 'n': mask = SP_NOMOVE; break;
|
|
||||||
case 'r': mask = SP_REPEAT; break;
|
|
||||||
case 'm': mask = SP_RETCOUNT; break;
|
|
||||||
case 's': mask = SP_SETPCMARK; break;
|
|
||||||
case 'c': mask = SP_START; break;
|
case 'c': mask = SP_START; break;
|
||||||
|
case 'e': mask = SP_END; break;
|
||||||
|
case 'm': mask = SP_RETCOUNT; break;
|
||||||
|
case 'n': mask = SP_NOMOVE; break;
|
||||||
|
case 'p': mask = SP_SUBPAT; break;
|
||||||
|
case 'r': mask = SP_REPEAT; break;
|
||||||
|
case 's': mask = SP_SETPCMARK; break;
|
||||||
}
|
}
|
||||||
if (mask == 0)
|
if (mask == 0)
|
||||||
{
|
{
|
||||||
@ -13278,6 +13286,7 @@ search_cmn(argvars, match_pos)
|
|||||||
int retval = 0; /* default: FAIL */
|
int retval = 0; /* default: FAIL */
|
||||||
long lnum_stop = 0;
|
long lnum_stop = 0;
|
||||||
int options = SEARCH_KEEP;
|
int options = SEARCH_KEEP;
|
||||||
|
int subpatnum;
|
||||||
|
|
||||||
pat = get_tv_string(&argvars[0]);
|
pat = get_tv_string(&argvars[0]);
|
||||||
dir = get_search_arg(&argvars[1], &flags); /* may set p_ws */
|
dir = get_search_arg(&argvars[1], &flags); /* may set p_ws */
|
||||||
@ -13285,6 +13294,8 @@ search_cmn(argvars, match_pos)
|
|||||||
goto theend;
|
goto theend;
|
||||||
if (flags & SP_START)
|
if (flags & SP_START)
|
||||||
options |= SEARCH_START;
|
options |= SEARCH_START;
|
||||||
|
if (flags & SP_END)
|
||||||
|
options |= SEARCH_END;
|
||||||
|
|
||||||
/* Optional extra argument: line number to stop searching. */
|
/* Optional extra argument: line number to stop searching. */
|
||||||
if (argvars[1].v_type != VAR_UNKNOWN
|
if (argvars[1].v_type != VAR_UNKNOWN
|
||||||
@ -13296,12 +13307,12 @@ search_cmn(argvars, match_pos)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This function accepts only SP_NOMOVE, SP_START and SP_SETPCMARK flags.
|
* This function does not accept SP_REPEAT and SP_RETCOUNT flags.
|
||||||
* Check to make sure only those flags are set.
|
* Check to make sure only those flags are set.
|
||||||
* Also, Only the SP_NOMOVE or the SP_SETPCMARK flag can be set. Both
|
* Also, Only the SP_NOMOVE or the SP_SETPCMARK flag can be set. Both
|
||||||
* flags cannot be set. Check for that condition also.
|
* flags cannot be set. Check for that condition also.
|
||||||
*/
|
*/
|
||||||
if (((flags & ~(SP_NOMOVE | SP_SETPCMARK | SP_START)) != 0)
|
if (((flags & (SP_REPEAT | SP_RETCOUNT)) != 0)
|
||||||
|| ((flags & SP_NOMOVE) && (flags & SP_SETPCMARK)))
|
|| ((flags & SP_NOMOVE) && (flags & SP_SETPCMARK)))
|
||||||
{
|
{
|
||||||
EMSG2(_(e_invarg2), get_tv_string(&argvars[1]));
|
EMSG2(_(e_invarg2), get_tv_string(&argvars[1]));
|
||||||
@ -13309,9 +13320,13 @@ search_cmn(argvars, match_pos)
|
|||||||
}
|
}
|
||||||
|
|
||||||
pos = save_cursor = curwin->w_cursor;
|
pos = save_cursor = curwin->w_cursor;
|
||||||
if (searchit(curwin, curbuf, &pos, dir, pat, 1L,
|
subpatnum = searchit(curwin, curbuf, &pos, dir, pat, 1L,
|
||||||
options, RE_SEARCH, (linenr_T)lnum_stop) != FAIL)
|
options, RE_SEARCH, (linenr_T)lnum_stop);
|
||||||
|
if (subpatnum != FAIL)
|
||||||
{
|
{
|
||||||
|
if (flags & SP_SUBPAT)
|
||||||
|
retval = subpatnum;
|
||||||
|
else
|
||||||
retval = pos.lnum;
|
retval = pos.lnum;
|
||||||
if (flags & SP_SETPCMARK)
|
if (flags & SP_SETPCMARK)
|
||||||
setpcmark();
|
setpcmark();
|
||||||
@ -13404,12 +13419,14 @@ searchpair_cmn(argvars, match_pos)
|
|||||||
dir = get_search_arg(&argvars[3], &flags); /* may set p_ws */
|
dir = get_search_arg(&argvars[3], &flags); /* may set p_ws */
|
||||||
if (dir == 0)
|
if (dir == 0)
|
||||||
goto theend;
|
goto theend;
|
||||||
/*
|
|
||||||
|
/* Don't accept SP_END or SP_SUBPAT.
|
||||||
* Only one of the SP_NOMOVE or SP_SETPCMARK flags can be set.
|
* Only one of the SP_NOMOVE or SP_SETPCMARK flags can be set.
|
||||||
*/
|
*/
|
||||||
if ((flags & SP_NOMOVE) && (flags & SP_SETPCMARK))
|
if ((flags & (SP_END | SP_SUBPAT)) != 0
|
||||||
|
|| ((flags & SP_NOMOVE) && (flags & SP_SETPCMARK)))
|
||||||
{
|
{
|
||||||
EMSG2(_(e_invarg2), get_tv_string(&argvars[1]));
|
EMSG2(_(e_invarg2), get_tv_string(&argvars[3]));
|
||||||
goto theend;
|
goto theend;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -13489,7 +13506,7 @@ do_searchpair(spat, mpat, epat, dir, skip, flags, match_pos, lnum_stop)
|
|||||||
char_u *epat; /* end pattern */
|
char_u *epat; /* end pattern */
|
||||||
int dir; /* BACKWARD or FORWARD */
|
int dir; /* BACKWARD or FORWARD */
|
||||||
char_u *skip; /* skip expression */
|
char_u *skip; /* skip expression */
|
||||||
int flags; /* SP_RETCOUNT, SP_REPEAT, SP_NOMOVE, SP_START */
|
int flags; /* SP_SETPCMARK and other SP_ values */
|
||||||
pos_T *match_pos;
|
pos_T *match_pos;
|
||||||
linenr_T lnum_stop; /* stop at this line if not zero */
|
linenr_T lnum_stop; /* stop at this line if not zero */
|
||||||
{
|
{
|
||||||
@ -15636,6 +15653,84 @@ f_winrestcmd(argvars, rettv)
|
|||||||
rettv->v_type = VAR_STRING;
|
rettv->v_type = VAR_STRING;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* "winrestview()" function
|
||||||
|
*/
|
||||||
|
/* ARGSUSED */
|
||||||
|
static void
|
||||||
|
f_winrestview(argvars, rettv)
|
||||||
|
typval_T *argvars;
|
||||||
|
typval_T *rettv;
|
||||||
|
{
|
||||||
|
dict_T *dict;
|
||||||
|
|
||||||
|
if (argvars[0].v_type != VAR_DICT
|
||||||
|
|| (dict = argvars[0].vval.v_dict) == NULL)
|
||||||
|
EMSG(_(e_invarg));
|
||||||
|
else
|
||||||
|
{
|
||||||
|
curwin->w_cursor.lnum = get_dict_number(dict, (char_u *)"lnum");
|
||||||
|
curwin->w_cursor.col = get_dict_number(dict, (char_u *)"col");
|
||||||
|
#ifdef FEAT_VIRTUALEDIT
|
||||||
|
curwin->w_cursor.coladd = get_dict_number(dict, (char_u *)"coladd");
|
||||||
|
#endif
|
||||||
|
curwin->w_curswant = get_dict_number(dict, (char_u *)"curswant");
|
||||||
|
|
||||||
|
curwin->w_topline = get_dict_number(dict, (char_u *)"topline");
|
||||||
|
#ifdef FEAT_DIFF
|
||||||
|
curwin->w_topfill = get_dict_number(dict, (char_u *)"topfill");
|
||||||
|
#endif
|
||||||
|
curwin->w_leftcol = get_dict_number(dict, (char_u *)"leftcol");
|
||||||
|
curwin->w_skipcol = get_dict_number(dict, (char_u *)"skipcol");
|
||||||
|
|
||||||
|
check_cursor();
|
||||||
|
changed_cline_bef_curs();
|
||||||
|
invalidate_botline();
|
||||||
|
redraw_later(VALID);
|
||||||
|
|
||||||
|
if (curwin->w_topline == 0)
|
||||||
|
curwin->w_topline = 1;
|
||||||
|
if (curwin->w_topline > curbuf->b_ml.ml_line_count)
|
||||||
|
curwin->w_topline = curbuf->b_ml.ml_line_count;
|
||||||
|
#ifdef FEAT_DIFF
|
||||||
|
check_topfill(curwin, TRUE);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* "winsaveview()" function
|
||||||
|
*/
|
||||||
|
/* ARGSUSED */
|
||||||
|
static void
|
||||||
|
f_winsaveview(argvars, rettv)
|
||||||
|
typval_T *argvars;
|
||||||
|
typval_T *rettv;
|
||||||
|
{
|
||||||
|
dict_T *dict;
|
||||||
|
|
||||||
|
dict = dict_alloc();
|
||||||
|
if (dict == NULL)
|
||||||
|
return;
|
||||||
|
rettv->v_type = VAR_DICT;
|
||||||
|
rettv->vval.v_dict = dict;
|
||||||
|
++dict->dv_refcount;
|
||||||
|
|
||||||
|
dict_add_nr_str(dict, "lnum", (long)curwin->w_cursor.lnum, NULL);
|
||||||
|
dict_add_nr_str(dict, "col", (long)curwin->w_cursor.col, NULL);
|
||||||
|
#ifdef FEAT_VIRTUALEDIT
|
||||||
|
dict_add_nr_str(dict, "coladd", (long)curwin->w_cursor.coladd, NULL);
|
||||||
|
#endif
|
||||||
|
dict_add_nr_str(dict, "curswant", (long)curwin->w_curswant, NULL);
|
||||||
|
|
||||||
|
dict_add_nr_str(dict, "topline", (long)curwin->w_topline, NULL);
|
||||||
|
#ifdef FEAT_DIFF
|
||||||
|
dict_add_nr_str(dict, "topfill", (long)curwin->w_topfill, NULL);
|
||||||
|
#endif
|
||||||
|
dict_add_nr_str(dict, "leftcol", (long)curwin->w_leftcol, NULL);
|
||||||
|
dict_add_nr_str(dict, "skipcol", (long)curwin->w_skipcol, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* "winwidth(nr)" function
|
* "winwidth(nr)" function
|
||||||
*/
|
*/
|
||||||
|
@ -837,6 +837,8 @@ EX(CMD_spelldump, "spelldump", ex_spelldump,
|
|||||||
BANG|TRLBAR),
|
BANG|TRLBAR),
|
||||||
EX(CMD_spellrepall, "spellrepall", ex_spellrepall,
|
EX(CMD_spellrepall, "spellrepall", ex_spellrepall,
|
||||||
TRLBAR),
|
TRLBAR),
|
||||||
|
EX(CMD_spellundo, "spellundo", ex_spell,
|
||||||
|
BANG|RANGE|NOTADR|NEEDARG|EXTRA|TRLBAR),
|
||||||
EX(CMD_sprevious, "sprevious", ex_previous,
|
EX(CMD_sprevious, "sprevious", ex_previous,
|
||||||
EXTRA|RANGE|NOTADR|COUNT|BANG|EDITCMD|ARGOPT|TRLBAR),
|
EXTRA|RANGE|NOTADR|COUNT|BANG|EDITCMD|ARGOPT|TRLBAR),
|
||||||
EX(CMD_srewind, "srewind", ex_rewind,
|
EX(CMD_srewind, "srewind", ex_rewind,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user