]> git.pld-linux.org Git - packages/vim.git/blob - 7.1.322
- recognize update_mime_database
[packages/vim.git] / 7.1.322
1 To: vim-dev@vim.org
2 Subject: Patch 7.1.322
3 Fcc: outbox
4 From: Bram Moolenaar <Bram@moolenaar.net>
5 Mime-Version: 1.0
6 Content-Type: text/plain; charset=ISO-8859-1
7 Content-Transfer-Encoding: 8bit
8 ------------
9
10 Patch 7.1.322
11 Problem:    Can't get start of Visual area in an <expr> mapping.
12 Solution:   Add the 'v' argument to getpos().
13 Files:      runtime/doc/eval.txt, src/eval.c
14
15
16 *** ../vim-7.1.321/runtime/doc/eval.txt Wed May 28 16:48:00 2008
17 --- runtime/doc/eval.txt        Thu Jun 19 22:46:23 2008
18 ***************
19 *** 3515,3520 ****
20 --- 3635,3644 ----
21                             returned)
22                     w0      first line visible in current window
23                     w$      last line visible in current window
24 +                   v       In Visual mode: the start of the Visual area (the
25 +                           cursor is the end).  When not in Visual mode
26 +                           returns the cursor position.  Differs from |'<| in
27 +                           that it's updated right away.
28                 Note that a mark in another file can be used.  The line number
29                 then applies to another buffer.
30                 To get the column number use |col()|.  To get both use
31 *** ../vim-7.1.321/src/eval.c   Thu May 29 21:46:10 2008
32 --- src/eval.c  Fri Jun 20 17:20:52 2008
33 ***************
34 *** 16907,16915 ****
35       name = get_tv_string_chk(varp);
36       if (name == NULL)
37         return NULL;
38 !     if (name[0] == '.')               /* cursor */
39         return &curwin->w_cursor;
40 !     if (name[0] == '\'')      /* mark */
41       {
42         pp = getmark_fnum(name[1], FALSE, fnum);
43         if (pp == NULL || pp == (pos_T *)-1 || pp->lnum <= 0)
44 --- 17478,17494 ----
45       name = get_tv_string_chk(varp);
46       if (name == NULL)
47         return NULL;
48 !     if (name[0] == '.')                               /* cursor */
49         return &curwin->w_cursor;
50 ! #ifdef FEAT_VISUAL
51 !     if (name[0] == 'v' && name[1] == NUL)     /* Visual start */
52 !     {
53 !       if (VIsual_active)
54 !           return &VIsual;
55 !       return &curwin->w_cursor;
56 !     }
57 ! #endif
58 !     if (name[0] == '\'')                      /* mark */
59       {
60         pp = getmark_fnum(name[1], FALSE, fnum);
61         if (pp == NULL || pp == (pos_T *)-1 || pp->lnum <= 0)
62 *** ../vim-7.1.321/src/version.c        Fri Jun 20 16:51:54 2008
63 --- src/version.c       Fri Jun 20 17:27:30 2008
64 ***************
65 *** 668,669 ****
66 --- 673,676 ----
67   {   /* Add new patch number below this line */
68 + /**/
69 +     322,
70   /**/
71
72 -- 
73 hundred-and-one symptoms of being an internet addict:
74 52. You ask a plumber how much it would cost to replace the chair in front of
75     your computer with a toilet.
76
77  /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
78 ///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
79 \\\        download, build and distribute -- http://www.A-A-P.org        ///
80  \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///
This page took 0.027319 seconds and 3 git commands to generate.