Hi all,

On Tue, Aug 11, 2015 at 2:27 PM, Bram Moolenaar <[email protected]> wrote:
>
> Patch 7.4.813
> Problem:    It is not possible to save and restore character search state.
> Solution:   Add getcharsearch() and setcharsearch().  (James McCoy)
> Files:      runtime/doc/eval.txt, src/eval.c, src/proto/search.pro,
>             src/search.c, src/testdir/test_charsearch.in,
>             src/testdir/test_charsearch.ok, src/testdir/Makefile,
>             src/testdir/Make_amiga.mak, src/testdir/Make_dos.mak,
>             src/testdir/Make_ming.mak, src/testdir/Make_os2.mak,
>             src/testdir/Make_vms.mms
>
>
> *** ../vim-7.4.812/runtime/doc/eval.txt 2015-07-21 15:48:13.581518028 +0200
> --- runtime/doc/eval.txt        2015-08-11 13:32:31.643435417 +0200
> ***************
> *** 1820,1828 ****
>                                 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
>   getcmdpos()                   Number  return cursor position in command-line
> ! getcmdtype()                  String  return the current command-line type
>   getcurpos()                   List    position of the cursor
>   getcwd()                      String  the current working directory
>   getfontname( [{name}])                String  name of font being used
> --- 1822,1832 ----
>                                 any     variable {varname} in buffer {expr}
>   getchar( [expr])              Number  get one character from the user
>   getcharmod( )                 Number  modifiers for the last typed character
> + getcharsearch()                       Dict    last character search
>   getcmdline()                  String  return the current command-line
>   getcmdpos()                   Number  return cursor position in command-line
> ! getcmdtype()                  String  return current command-line type
> ! getcmdwintype()                       String  return current command-line 
> window type
>   getcurpos()                   List    position of the cursor
>   getcwd()                      String  the current working directory
>   getfontname( [{name}])                String  name of font being used
> ***************

Presumably, getcmdwintype() was added in a previous patch, since it
doesn't occur in this one?

> --- src/testdir/test_charsearch.in      2015-08-11 14:12:34.048131520 +0200
> ***************
> *** 0 ****
> --- 1,25 ----
> + Test for character searches
> +
> + STARTTEST
> + :so small.vim
> + :" check that "fe" and ";" work
> + /^X
> + ylfep;;p,,p:
> + :" check that save/restore works
> + /^Y
> + ylfep:let csave = getcharsearch()
> + fip:call setcharsearch(csave)
> + ;p;p:
> + :" check that setcharsearch() changes the settins.


Silly typo-fix from me, presumably that should have been "settings"

Christ van Willegen
-- 
09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui