]> git.pld-linux.org Git - packages/vim.git/blob - 7.3.031
- new: 7.3.260
[packages/vim.git] / 7.3.031
1 To: vim-dev@vim.org
2 Subject: Patch 7.3.031
3 Fcc: outbox
4 From: Bram Moolenaar <Bram@moolenaar.net>
5 Mime-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8 ------------
9
10 Patch 7.3.031
11 Problem:    Can't pass the X window ID to another application.
12 Solution:   Add v:windowid. (Christian J. Robinson, Lech Lorens)
13 Files:      runtime/doc/eval.txt, src/eval.c, src/gui.c, src/vim.h,
14             src/os_unix.c
15
16
17 *** ../vim-7.3.030/runtime/doc/eval.txt 2010-08-15 21:57:15.000000000 +0200
18 --- runtime/doc/eval.txt        2010-10-20 19:11:03.000000000 +0200
19 ***************
20 *** 1657,1662 ****
21 --- 1657,1667 ----
22                                         *v:warningmsg* *warningmsg-variable*
23   v:warningmsg  Last given warning message.  It's allowed to set this variable.
24   
25 +                                       *v:windowid* *windowid-variable*
26 + v:windowid    When any X11 based GUI is running or when running in a
27 +               terminal and Vim connects to the X server (|-X|) this will be
28 +               set to the window ID.  Otherwise the value is zero.
29
30   ==============================================================================
31   4. Builtin Functions                                  *functions*
32   
33 *** ../vim-7.3.030/src/eval.c   2010-10-20 17:44:01.000000000 +0200
34 --- src/eval.c  2010-10-20 18:48:40.000000000 +0200
35 ***************
36 *** 362,367 ****
37 --- 362,368 ----
38       {VV_NAME("operator",       VAR_STRING), VV_RO},
39       {VV_NAME("searchforward",  VAR_NUMBER), 0},
40       {VV_NAME("oldfiles",       VAR_LIST), 0},
41 +     {VV_NAME("windowid",       VAR_NUMBER), VV_RO},
42   };
43   
44   /* shorthand */
45 *** ../vim-7.3.030/src/gui.c    2010-09-29 17:26:57.000000000 +0200
46 --- src/gui.c   2010-10-20 19:15:56.000000000 +0200
47 ***************
48 *** 105,112 ****
49 --- 105,122 ----
50   
51   #if defined(FEAT_GUI_GTK) || defined(FEAT_GUI_X11)
52       if (gui.in_use)
53 +     {
54 + # ifdef FEAT_EVAL
55 +       Window  x11_window;
56 +       Display *x11_display;
57
58 +       if (gui_get_x11_windis(&x11_window, &x11_display) == OK)
59 +           set_vim_var_nr(VV_WINDOWID, (long)x11_window);
60 + # endif
61
62         /* Display error messages in a dialog now. */
63         display_errors();
64 +     }
65   #endif
66   
67   #if defined(MAY_FORK) && !defined(__QNXNTO__)
68 *** ../vim-7.3.030/src/vim.h    2010-10-10 17:08:28.000000000 +0200
69 --- src/vim.h   2010-10-20 18:48:40.000000000 +0200
70 ***************
71 *** 1842,1848 ****
72   #define VV_OP         52
73   #define VV_SEARCHFORWARD 53
74   #define VV_OLDFILES   54
75 ! #define VV_LEN                55      /* number of v: vars */
76   
77   #ifdef FEAT_CLIPBOARD
78   
79 --- 1842,1849 ----
80   #define VV_OP         52
81   #define VV_SEARCHFORWARD 53
82   #define VV_OLDFILES   54
83 ! #define VV_WINDOWID   55
84 ! #define VV_LEN                56      /* number of v: vars */
85   
86   #ifdef FEAT_CLIPBOARD
87   
88 *** ../vim-7.3.030/src/os_unix.c        2010-10-13 16:22:05.000000000 +0200
89 --- src/os_unix.c       2010-10-20 19:15:46.000000000 +0200
90 ***************
91 *** 1738,1743 ****
92 --- 1738,1748 ----
93       }
94       if (x11_window == 0 || x11_display == NULL)
95         return (result = FAIL);
96
97 + # ifdef FEAT_EVAL
98 +     set_vim_var_nr(VV_WINDOWID, (long)x11_window);
99 + # endif
100
101       return (result = OK);
102   }
103   
104 *** ../vim-7.3.030/src/version.c        2010-10-20 17:44:01.000000000 +0200
105 --- src/version.c       2010-10-20 19:11:31.000000000 +0200
106 ***************
107 *** 716,717 ****
108 --- 716,719 ----
109   {   /* Add new patch number below this line */
110 + /**/
111 +     31,
112   /**/
113
114 -- 
115 What the word 'politics' means: 'Poli' in Latin meaning 'many' and 'tics'
116 meaning 'bloodsucking creatures'.
117
118  /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
119 ///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
120 \\\        download, build and distribute -- http://www.A-A-P.org        ///
121  \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///
This page took 0.029491 seconds and 3 git commands to generate.