Mercurial > vim
annotate src/version.c @ 3050:22550986c713 v7.3.297
updated for version 7.3.297
Problem: Can't load Perl 5.14 dynamically.
Solution: Add code in #ifdefs. (Charles Cooper)
author | Bram Moolenaar <bram@vim.org> |
---|---|
date | Wed, 07 Sep 2011 18:47:23 +0200 |
parents | c19c15a9e9bf |
children | 43b1d031e302 |
rev | line source |
---|---|
7 | 1 /* vi:set ts=8 sts=4 sw=4: |
2 * | |
3 * VIM - Vi IMproved by Bram Moolenaar | |
4 * | |
5 * Do ":help uganda" in Vim to read copying and usage conditions. | |
6 * Do ":help credits" in Vim to see a list of people who contributed. | |
7 * See README.txt for an overview of the Vim source code. | |
8 */ | |
9 | |
10 #include "vim.h" | |
11 | |
12 #ifdef AMIGA | |
13 # include <time.h> /* for time() */ | |
14 #endif | |
15 | |
16 /* | |
17 * Vim originated from Stevie version 3.6 (Fish disk 217) by GRWalter (Fred) | |
18 * It has been changed beyond recognition since then. | |
19 * | |
26 | 20 * Differences between version 6.x and 7.x can be found with ":help version7". |
7 | 21 * Differences between version 5.x and 6.x can be found with ":help version6". |
22 * Differences between version 4.x and 5.x can be found with ":help version5". | |
23 * Differences between version 3.0 and 4.x can be found with ":help version4". | |
24 * All the remarks about older versions have been removed, they are not very | |
25 * interesting. | |
26 */ | |
27 | |
28 #include "version.h" | |
29 | |
378 | 30 char *Version = VIM_VERSION_SHORT; |
31 static char *mediumVersion = VIM_VERSION_MEDIUM; | |
7 | 32 |
33 #if defined(HAVE_DATE_TIME) || defined(PROTO) | |
34 # if (defined(VMS) && defined(VAXC)) || defined(PROTO) | |
35 char longVersion[sizeof(VIM_VERSION_LONG_DATE) + sizeof(__DATE__) | |
36 + sizeof(__TIME__) + 3]; | |
37 void | |
38 make_version() | |
39 { | |
40 /* | |
41 * Construct the long version string. Necessary because | |
42 * VAX C can't catenate strings in the preprocessor. | |
43 */ | |
44 strcpy(longVersion, VIM_VERSION_LONG_DATE); | |
45 strcat(longVersion, __DATE__); | |
46 strcat(longVersion, " "); | |
47 strcat(longVersion, __TIME__); | |
48 strcat(longVersion, ")"); | |
49 } | |
50 # else | |
51 char *longVersion = VIM_VERSION_LONG_DATE __DATE__ " " __TIME__ ")"; | |
52 # endif | |
53 #else | |
54 char *longVersion = VIM_VERSION_LONG; | |
55 #endif | |
56 | |
57 static void version_msg __ARGS((char *s)); | |
58 | |
59 static char *(features[]) = | |
60 { | |
61 #ifdef AMIGA /* only for Amiga systems */ | |
62 # ifdef FEAT_ARP | |
63 "+ARP", | |
64 # else | |
65 "-ARP", | |
66 # endif | |
67 #endif | |
68 #ifdef FEAT_ARABIC | |
69 "+arabic", | |
70 #else | |
71 "-arabic", | |
72 #endif | |
73 #ifdef FEAT_AUTOCMD | |
74 "+autocmd", | |
75 #else | |
76 "-autocmd", | |
77 #endif | |
78 #ifdef FEAT_BEVAL | |
79 "+balloon_eval", | |
80 #else | |
81 "-balloon_eval", | |
82 #endif | |
83 #ifdef FEAT_BROWSE | |
84 "+browse", | |
85 #else | |
86 "-browse", | |
87 #endif | |
88 #ifdef NO_BUILTIN_TCAPS | |
89 "-builtin_terms", | |
90 #endif | |
91 #ifdef SOME_BUILTIN_TCAPS | |
92 "+builtin_terms", | |
93 #endif | |
94 #ifdef ALL_BUILTIN_TCAPS | |
95 "++builtin_terms", | |
96 #endif | |
97 #ifdef FEAT_BYTEOFF | |
98 "+byte_offset", | |
99 #else | |
100 "-byte_offset", | |
101 #endif | |
102 #ifdef FEAT_CINDENT | |
103 "+cindent", | |
104 #else | |
105 "-cindent", | |
106 #endif | |
107 #ifdef FEAT_CLIENTSERVER | |
108 "+clientserver", | |
109 #else | |
110 "-clientserver", | |
111 #endif | |
112 #ifdef FEAT_CLIPBOARD | |
113 "+clipboard", | |
114 #else | |
115 "-clipboard", | |
116 #endif | |
117 #ifdef FEAT_CMDL_COMPL | |
118 "+cmdline_compl", | |
119 #else | |
120 "-cmdline_compl", | |
121 #endif | |
122 #ifdef FEAT_CMDHIST | |
123 "+cmdline_hist", | |
124 #else | |
125 "-cmdline_hist", | |
126 #endif | |
127 #ifdef FEAT_CMDL_INFO | |
128 "+cmdline_info", | |
129 #else | |
130 "-cmdline_info", | |
131 #endif | |
132 #ifdef FEAT_COMMENTS | |
133 "+comments", | |
134 #else | |
135 "-comments", | |
136 #endif | |
2250
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
137 #ifdef FEAT_CONCEAL |
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
138 "+conceal", |
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
139 #else |
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
140 "-conceal", |
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
141 #endif |
7 | 142 #ifdef FEAT_CRYPT |
143 "+cryptv", | |
144 #else | |
145 "-cryptv", | |
146 #endif | |
147 #ifdef FEAT_CSCOPE | |
148 "+cscope", | |
149 #else | |
150 "-cscope", | |
151 #endif | |
2250
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
152 #ifdef FEAT_CURSORBIND |
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
153 "+cursorbind", |
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
154 #else |
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
155 "-cursorbind", |
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
156 #endif |
647 | 157 #ifdef CURSOR_SHAPE |
158 "+cursorshape", | |
159 #else | |
160 "-cursorshape", | |
161 #endif | |
7 | 162 #if defined(FEAT_CON_DIALOG) && defined(FEAT_GUI_DIALOG) |
163 "+dialog_con_gui", | |
164 #else | |
165 # if defined(FEAT_CON_DIALOG) | |
166 "+dialog_con", | |
167 # else | |
168 # if defined(FEAT_GUI_DIALOG) | |
169 "+dialog_gui", | |
170 # else | |
171 "-dialog", | |
172 # endif | |
173 # endif | |
174 #endif | |
175 #ifdef FEAT_DIFF | |
176 "+diff", | |
177 #else | |
178 "-diff", | |
179 #endif | |
180 #ifdef FEAT_DIGRAPHS | |
181 "+digraphs", | |
182 #else | |
183 "-digraphs", | |
184 #endif | |
185 #ifdef FEAT_DND | |
186 "+dnd", | |
187 #else | |
188 "-dnd", | |
189 #endif | |
190 #ifdef EBCDIC | |
191 "+ebcdic", | |
192 #else | |
193 "-ebcdic", | |
194 #endif | |
195 #ifdef FEAT_EMACS_TAGS | |
196 "+emacs_tags", | |
197 #else | |
198 "-emacs_tags", | |
199 #endif | |
200 #ifdef FEAT_EVAL | |
201 "+eval", | |
202 #else | |
203 "-eval", | |
204 #endif | |
205 #ifdef FEAT_EX_EXTRA | |
206 "+ex_extra", | |
207 #else | |
208 "-ex_extra", | |
209 #endif | |
210 #ifdef FEAT_SEARCH_EXTRA | |
211 "+extra_search", | |
212 #else | |
213 "-extra_search", | |
214 #endif | |
215 #ifdef FEAT_FKMAP | |
216 "+farsi", | |
217 #else | |
218 "-farsi", | |
219 #endif | |
220 #ifdef FEAT_SEARCHPATH | |
221 "+file_in_path", | |
222 #else | |
223 "-file_in_path", | |
224 #endif | |
225 #ifdef FEAT_FIND_ID | |
226 "+find_in_path", | |
227 #else | |
228 "-find_in_path", | |
229 #endif | |
1621 | 230 #ifdef FEAT_FLOAT |
231 "+float", | |
232 #else | |
233 "-float", | |
234 #endif | |
7 | 235 #ifdef FEAT_FOLDING |
236 "+folding", | |
237 #else | |
238 "-folding", | |
239 #endif | |
240 #ifdef FEAT_FOOTER | |
241 "+footer", | |
242 #else | |
243 "-footer", | |
244 #endif | |
245 /* only interesting on Unix systems */ | |
246 #if !defined(USE_SYSTEM) && defined(UNIX) | |
247 "+fork()", | |
248 #endif | |
249 #ifdef FEAT_GETTEXT | |
250 # ifdef DYNAMIC_GETTEXT | |
251 "+gettext/dyn", | |
252 # else | |
253 "+gettext", | |
254 # endif | |
255 #else | |
256 "-gettext", | |
257 #endif | |
258 #ifdef FEAT_HANGULIN | |
259 "+hangul_input", | |
260 #else | |
261 "-hangul_input", | |
262 #endif | |
263 #if (defined(HAVE_ICONV_H) && defined(USE_ICONV)) || defined(DYNAMIC_ICONV) | |
264 # ifdef DYNAMIC_ICONV | |
265 "+iconv/dyn", | |
266 # else | |
267 "+iconv", | |
268 # endif | |
269 #else | |
270 "-iconv", | |
271 #endif | |
272 #ifdef FEAT_INS_EXPAND | |
273 "+insert_expand", | |
274 #else | |
275 "-insert_expand", | |
276 #endif | |
277 #ifdef FEAT_JUMPLIST | |
278 "+jumplist", | |
279 #else | |
280 "-jumplist", | |
281 #endif | |
282 #ifdef FEAT_KEYMAP | |
283 "+keymap", | |
284 #else | |
285 "-keymap", | |
286 #endif | |
287 #ifdef FEAT_LANGMAP | |
288 "+langmap", | |
289 #else | |
290 "-langmap", | |
291 #endif | |
292 #ifdef FEAT_LIBCALL | |
293 "+libcall", | |
294 #else | |
295 "-libcall", | |
296 #endif | |
297 #ifdef FEAT_LINEBREAK | |
298 "+linebreak", | |
299 #else | |
300 "-linebreak", | |
301 #endif | |
302 #ifdef FEAT_LISP | |
303 "+lispindent", | |
304 #else | |
305 "-lispindent", | |
306 #endif | |
307 #ifdef FEAT_LISTCMDS | |
308 "+listcmds", | |
309 #else | |
310 "-listcmds", | |
311 #endif | |
312 #ifdef FEAT_LOCALMAP | |
313 "+localmap", | |
314 #else | |
315 "-localmap", | |
316 #endif | |
2320
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
317 #ifdef FEAT_LUA |
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
318 # ifdef DYNAMIC_LUA |
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
319 "+lua/dyn", |
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
320 # else |
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
321 "+lua", |
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
322 # endif |
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
323 #else |
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
324 "-lua", |
966a5609669e
Added Lua interfae. (Luis Carvalho)
Bram Moolenaar <bram@vim.org>
parents:
2275
diff
changeset
|
325 #endif |
7 | 326 #ifdef FEAT_MENU |
327 "+menu", | |
328 #else | |
329 "-menu", | |
330 #endif | |
331 #ifdef FEAT_SESSION | |
332 "+mksession", | |
333 #else | |
334 "-mksession", | |
335 #endif | |
336 #ifdef FEAT_MODIFY_FNAME | |
337 "+modify_fname", | |
338 #else | |
339 "-modify_fname", | |
340 #endif | |
341 #ifdef FEAT_MOUSE | |
342 "+mouse", | |
343 # ifdef FEAT_MOUSESHAPE | |
344 "+mouseshape", | |
345 # else | |
346 "-mouseshape", | |
347 # endif | |
348 # else | |
349 "-mouse", | |
350 #endif | |
351 #if defined(UNIX) || defined(VMS) | |
352 # ifdef FEAT_MOUSE_DEC | |
353 "+mouse_dec", | |
354 # else | |
355 "-mouse_dec", | |
356 # endif | |
357 # ifdef FEAT_MOUSE_GPM | |
358 "+mouse_gpm", | |
359 # else | |
360 "-mouse_gpm", | |
361 # endif | |
362 # ifdef FEAT_MOUSE_JSB | |
363 "+mouse_jsbterm", | |
364 # else | |
365 "-mouse_jsbterm", | |
366 # endif | |
367 # ifdef FEAT_MOUSE_NET | |
368 "+mouse_netterm", | |
369 # else | |
370 "-mouse_netterm", | |
371 # endif | |
1621 | 372 # ifdef FEAT_SYSMOUSE |
373 "+mouse_sysmouse", | |
374 # else | |
375 "-mouse_sysmouse", | |
376 # endif | |
7 | 377 # ifdef FEAT_MOUSE_XTERM |
378 "+mouse_xterm", | |
379 # else | |
380 "-mouse_xterm", | |
381 # endif | |
382 #endif | |
383 #ifdef __QNX__ | |
384 # ifdef FEAT_MOUSE_PTERM | |
385 "+mouse_pterm", | |
386 # else | |
387 "-mouse_pterm", | |
388 # endif | |
389 #endif | |
390 #ifdef FEAT_MBYTE_IME | |
391 # ifdef DYNAMIC_IME | |
392 "+multi_byte_ime/dyn", | |
393 # else | |
394 "+multi_byte_ime", | |
395 # endif | |
396 #else | |
397 # ifdef FEAT_MBYTE | |
398 "+multi_byte", | |
399 # else | |
400 "-multi_byte", | |
401 # endif | |
402 #endif | |
403 #ifdef FEAT_MULTI_LANG | |
404 "+multi_lang", | |
405 #else | |
406 "-multi_lang", | |
407 #endif | |
14 | 408 #ifdef FEAT_MZSCHEME |
132 | 409 # ifdef DYNAMIC_MZSCHEME |
410 "+mzscheme/dyn", | |
411 # else | |
14 | 412 "+mzscheme", |
132 | 413 # endif |
14 | 414 #else |
415 "-mzscheme", | |
416 #endif | |
7 | 417 #ifdef FEAT_NETBEANS_INTG |
418 "+netbeans_intg", | |
419 #else | |
420 "-netbeans_intg", | |
421 #endif | |
422 #ifdef FEAT_GUI_W32 | |
423 # ifdef FEAT_OLE | |
424 "+ole", | |
425 # else | |
426 "-ole", | |
427 # endif | |
428 #endif | |
429 #ifdef FEAT_PATH_EXTRA | |
430 "+path_extra", | |
431 #else | |
432 "-path_extra", | |
433 #endif | |
434 #ifdef FEAT_PERL | |
435 # ifdef DYNAMIC_PERL | |
436 "+perl/dyn", | |
437 # else | |
438 "+perl", | |
439 # endif | |
440 #else | |
441 "-perl", | |
442 #endif | |
2214
f8222d1f9a73
Included patch for persistent undo. Lots of changes and added test.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
443 #ifdef FEAT_PERSISTENT_UNDO |
f8222d1f9a73
Included patch for persistent undo. Lots of changes and added test.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
444 "+persistent_undo", |
f8222d1f9a73
Included patch for persistent undo. Lots of changes and added test.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
445 #else |
f8222d1f9a73
Included patch for persistent undo. Lots of changes and added test.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
446 "-persistent_undo", |
f8222d1f9a73
Included patch for persistent undo. Lots of changes and added test.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
447 #endif |
7 | 448 #ifdef FEAT_PRINTER |
449 # ifdef FEAT_POSTSCRIPT | |
450 "+postscript", | |
451 # else | |
452 "-postscript", | |
453 # endif | |
454 "+printer", | |
455 #else | |
456 "-printer", | |
457 #endif | |
170 | 458 #ifdef FEAT_PROFILE |
459 "+profile", | |
460 #else | |
461 "-profile", | |
462 #endif | |
7 | 463 #ifdef FEAT_PYTHON |
464 # ifdef DYNAMIC_PYTHON | |
465 "+python/dyn", | |
466 # else | |
467 "+python", | |
468 # endif | |
469 #else | |
470 "-python", | |
471 #endif | |
2329
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
472 #ifdef FEAT_PYTHON3 |
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
473 # ifdef DYNAMIC_PYTHON3 |
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
474 "+python3/dyn", |
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
475 # else |
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
476 "+python3", |
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
477 # endif |
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
478 #else |
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
479 "-python3", |
ad2889f48843
Added support for Python 3. (Roland Puntaier)
Bram Moolenaar <bram@vim.org>
parents:
2320
diff
changeset
|
480 #endif |
7 | 481 #ifdef FEAT_QUICKFIX |
482 "+quickfix", | |
483 #else | |
484 "-quickfix", | |
485 #endif | |
857 | 486 #ifdef FEAT_RELTIME |
487 "+reltime", | |
488 #else | |
489 "-reltime", | |
490 #endif | |
7 | 491 #ifdef FEAT_RIGHTLEFT |
492 "+rightleft", | |
493 #else | |
494 "-rightleft", | |
495 #endif | |
496 #ifdef FEAT_RUBY | |
497 # ifdef DYNAMIC_RUBY | |
498 "+ruby/dyn", | |
499 # else | |
500 "+ruby", | |
501 # endif | |
502 #else | |
503 "-ruby", | |
504 #endif | |
505 #ifdef FEAT_SCROLLBIND | |
506 "+scrollbind", | |
507 #else | |
508 "-scrollbind", | |
509 #endif | |
510 #ifdef FEAT_SIGNS | |
511 "+signs", | |
512 #else | |
513 "-signs", | |
514 #endif | |
515 #ifdef FEAT_SMARTINDENT | |
516 "+smartindent", | |
517 #else | |
518 "-smartindent", | |
519 #endif | |
520 #ifdef FEAT_SNIFF | |
521 "+sniff", | |
522 #else | |
523 "-sniff", | |
524 #endif | |
1989 | 525 #ifdef STARTUPTIME |
526 "+startuptime", | |
527 #else | |
528 "-startuptime", | |
529 #endif | |
7 | 530 #ifdef FEAT_STL_OPT |
531 "+statusline", | |
532 #else | |
533 "-statusline", | |
534 #endif | |
535 #ifdef FEAT_SUN_WORKSHOP | |
536 "+sun_workshop", | |
537 #else | |
538 "-sun_workshop", | |
539 #endif | |
540 #ifdef FEAT_SYN_HL | |
541 "+syntax", | |
542 #else | |
543 "-syntax", | |
544 #endif | |
545 /* only interesting on Unix systems */ | |
546 #if defined(USE_SYSTEM) && (defined(UNIX) || defined(__EMX__)) | |
547 "+system()", | |
548 #endif | |
549 #ifdef FEAT_TAG_BINS | |
550 "+tag_binary", | |
551 #else | |
552 "-tag_binary", | |
553 #endif | |
554 #ifdef FEAT_TAG_OLDSTATIC | |
555 "+tag_old_static", | |
556 #else | |
557 "-tag_old_static", | |
558 #endif | |
559 #ifdef FEAT_TAG_ANYWHITE | |
560 "+tag_any_white", | |
561 #else | |
562 "-tag_any_white", | |
563 #endif | |
564 #ifdef FEAT_TCL | |
565 # ifdef DYNAMIC_TCL | |
566 "+tcl/dyn", | |
567 # else | |
568 "+tcl", | |
569 # endif | |
570 #else | |
571 "-tcl", | |
572 #endif | |
573 #if defined(UNIX) || defined(__EMX__) | |
574 /* only Unix (or OS/2 with EMX!) can have terminfo instead of termcap */ | |
575 # ifdef TERMINFO | |
576 "+terminfo", | |
577 # else | |
578 "-terminfo", | |
579 # endif | |
580 #else /* unix always includes termcap support */ | |
581 # ifdef HAVE_TGETENT | |
582 "+tgetent", | |
583 # else | |
584 "-tgetent", | |
585 # endif | |
586 #endif | |
587 #ifdef FEAT_TERMRESPONSE | |
588 "+termresponse", | |
589 #else | |
590 "-termresponse", | |
591 #endif | |
592 #ifdef FEAT_TEXTOBJ | |
593 "+textobjects", | |
594 #else | |
595 "-textobjects", | |
596 #endif | |
597 #ifdef FEAT_TITLE | |
598 "+title", | |
599 #else | |
600 "-title", | |
601 #endif | |
602 #ifdef FEAT_TOOLBAR | |
603 "+toolbar", | |
604 #else | |
605 "-toolbar", | |
606 #endif | |
607 #ifdef FEAT_USR_CMDS | |
608 "+user_commands", | |
609 #else | |
610 "-user_commands", | |
611 #endif | |
612 #ifdef FEAT_VERTSPLIT | |
613 "+vertsplit", | |
614 #else | |
615 "-vertsplit", | |
616 #endif | |
617 #ifdef FEAT_VIRTUALEDIT | |
618 "+virtualedit", | |
619 #else | |
620 "-virtualedit", | |
621 #endif | |
622 #ifdef FEAT_VISUAL | |
623 "+visual", | |
624 # ifdef FEAT_VISUALEXTRA | |
625 "+visualextra", | |
626 # else | |
627 "-visualextra", | |
628 # endif | |
629 #else | |
630 "-visual", | |
631 #endif | |
632 #ifdef FEAT_VIMINFO | |
633 "+viminfo", | |
634 #else | |
635 "-viminfo", | |
636 #endif | |
637 #ifdef FEAT_VREPLACE | |
638 "+vreplace", | |
639 #else | |
640 "-vreplace", | |
641 #endif | |
642 #ifdef FEAT_WILDIGN | |
643 "+wildignore", | |
644 #else | |
645 "-wildignore", | |
646 #endif | |
647 #ifdef FEAT_WILDMENU | |
648 "+wildmenu", | |
649 #else | |
650 "-wildmenu", | |
651 #endif | |
652 #ifdef FEAT_WINDOWS | |
653 "+windows", | |
654 #else | |
655 "-windows", | |
656 #endif | |
657 #ifdef FEAT_WRITEBACKUP | |
658 "+writebackup", | |
659 #else | |
660 "-writebackup", | |
661 #endif | |
662 #if defined(UNIX) || defined(VMS) | |
663 # ifdef FEAT_X11 | |
664 "+X11", | |
665 # else | |
666 "-X11", | |
667 # endif | |
668 #endif | |
669 #ifdef FEAT_XFONTSET | |
670 "+xfontset", | |
671 #else | |
672 "-xfontset", | |
673 #endif | |
674 #ifdef FEAT_XIM | |
675 "+xim", | |
676 #else | |
677 "-xim", | |
678 #endif | |
679 #if defined(UNIX) || defined(VMS) | |
680 # ifdef USE_XSMP_INTERACT | |
681 "+xsmp_interact", | |
682 # else | |
683 # ifdef USE_XSMP | |
684 "+xsmp", | |
685 # else | |
686 "-xsmp", | |
687 # endif | |
688 # endif | |
689 # ifdef FEAT_XCLIPBOARD | |
690 "+xterm_clipboard", | |
691 # else | |
692 "-xterm_clipboard", | |
693 # endif | |
694 #endif | |
695 #ifdef FEAT_XTERM_SAVE | |
696 "+xterm_save", | |
697 #else | |
698 "-xterm_save", | |
699 #endif | |
700 #ifdef WIN3264 | |
701 # ifdef FEAT_XPM_W32 | |
702 "+xpm_w32", | |
703 # else | |
704 "-xpm_w32", | |
705 # endif | |
706 #endif | |
707 NULL | |
708 }; | |
709 | |
710 static int included_patches[] = | |
711 { /* Add new patch number below this line */ | |
712 /**/ | |
3050 | 713 297, |
714 /**/ | |
3048 | 715 296, |
716 /**/ | |
3046 | 717 295, |
718 /**/ | |
3044 | 719 294, |
720 /**/ | |
3042 | 721 293, |
722 /**/ | |
3040 | 723 292, |
724 /**/ | |
3038 | 725 291, |
726 /**/ | |
3036 | 727 290, |
728 /**/ | |
3034 | 729 289, |
730 /**/ | |
3032 | 731 288, |
732 /**/ | |
3030 | 733 287, |
734 /**/ | |
3028 | 735 286, |
736 /**/ | |
3026 | 737 285, |
738 /**/ | |
3024 | 739 284, |
740 /**/ | |
3022 | 741 283, |
742 /**/ | |
3020 | 743 282, |
744 /**/ | |
3018 | 745 281, |
746 /**/ | |
3016 | 747 280, |
748 /**/ | |
3014 | 749 279, |
750 /**/ | |
3012 | 751 278, |
752 /**/ | |
3010 | 753 277, |
754 /**/ | |
3008 | 755 276, |
756 /**/ | |
3006 | 757 275, |
758 /**/ | |
3004 | 759 274, |
760 /**/ | |
3002 | 761 273, |
762 /**/ | |
3000 | 763 272, |
764 /**/ | |
2998 | 765 271, |
766 /**/ | |
2996 | 767 270, |
768 /**/ | |
2994 | 769 269, |
770 /**/ | |
2992 | 771 268, |
772 /**/ | |
2990 | 773 267, |
774 /**/ | |
2988 | 775 266, |
776 /**/ | |
2986 | 777 265, |
778 /**/ | |
2984 | 779 264, |
780 /**/ | |
2982 | 781 263, |
782 /**/ | |
2980 | 783 262, |
784 /**/ | |
2978 | 785 261, |
786 /**/ | |
2976 | 787 260, |
788 /**/ | |
2974 | 789 259, |
790 /**/ | |
2972 | 791 258, |
792 /**/ | |
2970 | 793 257, |
794 /**/ | |
2968 | 795 256, |
796 /**/ | |
2966 | 797 255, |
798 /**/ | |
2963 | 799 254, |
800 /**/ | |
2961 | 801 253, |
802 /**/ | |
2959 | 803 252, |
804 /**/ | |
2957 | 805 251, |
806 /**/ | |
2955 | 807 250, |
808 /**/ | |
2953 | 809 249, |
810 /**/ | |
2951 | 811 248, |
812 /**/ | |
2949 | 813 247, |
814 /**/ | |
2947 | 815 246, |
816 /**/ | |
2945 | 817 245, |
818 /**/ | |
2943 | 819 244, |
820 /**/ | |
2941 | 821 243, |
822 /**/ | |
2939 | 823 242, |
824 /**/ | |
2937 | 825 241, |
826 /**/ | |
2935 | 827 240, |
828 /**/ | |
2933 | 829 239, |
830 /**/ | |
2931 | 831 238, |
832 /**/ | |
2929 | 833 237, |
834 /**/ | |
2927 | 835 236, |
836 /**/ | |
2925 | 837 235, |
838 /**/ | |
2923 | 839 234, |
840 /**/ | |
2921 | 841 233, |
842 /**/ | |
2919 | 843 232, |
844 /**/ | |
2917 | 845 231, |
846 /**/ | |
2915 | 847 230, |
848 /**/ | |
2913 | 849 229, |
850 /**/ | |
2911 | 851 228, |
852 /**/ | |
2909 | 853 227, |
854 /**/ | |
2906 | 855 226, |
856 /**/ | |
2904 | 857 225, |
858 /**/ | |
2902 | 859 224, |
860 /**/ | |
2900 | 861 223, |
862 /**/ | |
2898 | 863 222, |
864 /**/ | |
2896 | 865 221, |
866 /**/ | |
2894 | 867 220, |
868 /**/ | |
2891 | 869 219, |
870 /**/ | |
2889 | 871 218, |
872 /**/ | |
2887 | 873 217, |
874 /**/ | |
2885 | 875 216, |
876 /**/ | |
2883 | 877 215, |
878 /**/ | |
2881 | 879 214, |
880 /**/ | |
2879 | 881 213, |
882 /**/ | |
2877 | 883 212, |
884 /**/ | |
2875 | 885 211, |
886 /**/ | |
2873 | 887 210, |
888 /**/ | |
2871 | 889 209, |
890 /**/ | |
2869 | 891 208, |
892 /**/ | |
2867 | 893 207, |
894 /**/ | |
2865 | 895 206, |
896 /**/ | |
2863 | 897 205, |
898 /**/ | |
2861 | 899 204, |
900 /**/ | |
2859 | 901 203, |
902 /**/ | |
2857 | 903 202, |
904 /**/ | |
2855 | 905 201, |
906 /**/ | |
2853 | 907 200, |
908 /**/ | |
2851 | 909 199, |
910 /**/ | |
2849 | 911 198, |
912 /**/ | |
2847 | 913 197, |
914 /**/ | |
2845 | 915 196, |
916 /**/ | |
2843 | 917 195, |
918 /**/ | |
2841 | 919 194, |
920 /**/ | |
2839 | 921 193, |
922 /**/ | |
2837 | 923 192, |
924 /**/ | |
2834 | 925 191, |
926 /**/ | |
2831 | 927 190, |
928 /**/ | |
2829 | 929 189, |
930 /**/ | |
2827 | 931 188, |
932 /**/ | |
2823 | 933 187, |
934 /**/ | |
2821 | 935 186, |
936 /**/ | |
2819 | 937 185, |
938 /**/ | |
2817 | 939 184, |
940 /**/ | |
2815 | 941 183, |
942 /**/ | |
2813 | 943 182, |
944 /**/ | |
2811 | 945 181, |
946 /**/ | |
2809 | 947 180, |
948 /**/ | |
2807 | 949 179, |
950 /**/ | |
2805 | 951 178, |
952 /**/ | |
2803 | 953 177, |
954 /**/ | |
2801 | 955 176, |
956 /**/ | |
2799 | 957 175, |
958 /**/ | |
2797 | 959 174, |
960 /**/ | |
2795 | 961 173, |
962 /**/ | |
2793 | 963 172, |
964 /**/ | |
2791 | 965 171, |
966 /**/ | |
2789 | 967 170, |
968 /**/ | |
2786 | 969 169, |
970 /**/ | |
2784 | 971 168, |
972 /**/ | |
2782 | 973 167, |
974 /**/ | |
2780 | 975 166, |
976 /**/ | |
2778 | 977 165, |
978 /**/ | |
2776 | 979 164, |
980 /**/ | |
2774 | 981 163, |
982 /**/ | |
2772 | 983 162, |
984 /**/ | |
2770 | 985 161, |
986 /**/ | |
2768 | 987 160, |
988 /**/ | |
2766 | 989 159, |
990 /**/ | |
2764 | 991 158, |
992 /**/ | |
2762 | 993 157, |
994 /**/ | |
2760 | 995 156, |
996 /**/ | |
2758 | 997 155, |
998 /**/ | |
2756 | 999 154, |
1000 /**/ | |
2754 | 1001 153, |
1002 /**/ | |
2752 | 1003 152, |
1004 /**/ | |
2749 | 1005 151, |
1006 /**/ | |
2747 | 1007 150, |
1008 /**/ | |
2745 | 1009 149, |
1010 /**/ | |
2743 | 1011 148, |
1012 /**/ | |
2741 | 1013 147, |
1014 /**/ | |
2739 | 1015 146, |
1016 /**/ | |
2737 | 1017 145, |
1018 /**/ | |
2735 | 1019 144, |
1020 /**/ | |
2730 | 1021 143, |
1022 /**/ | |
2727 | 1023 142, |
1024 /**/ | |
2726 | 1025 141, |
1026 /**/ | |
2724 | 1027 140, |
1028 /**/ | |
2723 | 1029 139, |
1030 /**/ | |
2722 | 1031 138, |
1032 /**/ | |
2721 | 1033 137, |
1034 /**/ | |
2720 | 1035 136, |
1036 /**/ | |
2719 | 1037 135, |
1038 /**/ | |
2718 | 1039 134, |
1040 /**/ | |
2717 | 1041 133, |
1042 /**/ | |
2716 | 1043 132, |
1044 /**/ | |
2715 | 1045 131, |
1046 /**/ | |
2714 | 1047 130, |
1048 /**/ | |
2713 | 1049 129, |
1050 /**/ | |
2712 | 1051 128, |
1052 /**/ | |
2711 | 1053 127, |
1054 /**/ | |
2710 | 1055 126, |
1056 /**/ | |
2708 | 1057 125, |
1058 /**/ | |
2707 | 1059 124, |
1060 /**/ | |
2706 | 1061 123, |
1062 /**/ | |
2705 | 1063 122, |
1064 /**/ | |
2704 | 1065 121, |
1066 /**/ | |
2703 | 1067 120, |
1068 /**/ | |
2702 | 1069 119, |
1070 /**/ | |
2701 | 1071 118, |
1072 /**/ | |
2700 | 1073 117, |
1074 /**/ | |
2699 | 1075 116, |
1076 /**/ | |
2697 | 1077 115, |
1078 /**/ | |
2696 | 1079 114, |
1080 /**/ | |
2695 | 1081 113, |
1082 /**/ | |
2694 | 1083 112, |
1084 /**/ | |
2693 | 1085 111, |
1086 /**/ | |
2692 | 1087 110, |
1088 /**/ | |
2691 | 1089 109, |
1090 /**/ | |
2690 | 1091 108, |
1092 /**/ | |
2689 | 1093 107, |
1094 /**/ | |
2688 | 1095 106, |
1096 /**/ | |
2687 | 1097 105, |
1098 /**/ | |
2686 | 1099 104, |
1100 /**/ | |
2685 | 1101 103, |
1102 /**/ | |
2684 | 1103 102, |
1104 /**/ | |
2683 | 1105 101, |
1106 /**/ | |
2682 | 1107 100, |
1108 /**/ | |
2680 | 1109 99, |
1110 /**/ | |
2679 | 1111 98, |
1112 /**/ | |
2678 | 1113 97, |
1114 /**/ | |
2677 | 1115 96, |
1116 /**/ | |
2676 | 1117 95, |
1118 /**/ | |
2675 | 1119 94, |
1120 /**/ | |
2674 | 1121 93, |
1122 /**/ | |
2673 | 1123 92, |
1124 /**/ | |
2672 | 1125 91, |
1126 /**/ | |
2671 | 1127 90, |
1128 /**/ | |
2670 | 1129 89, |
1130 /**/ | |
2669 | 1131 88, |
1132 /**/ | |
2668 | 1133 87, |
1134 /**/ | |
2667 | 1135 86, |
1136 /**/ | |
2666 | 1137 85, |
1138 /**/ | |
2665 | 1139 84, |
1140 /**/ | |
2664 | 1141 83, |
1142 /**/ | |
2663 | 1143 82, |
1144 /**/ | |
2661 | 1145 81, |
1146 /**/ | |
2660 | 1147 80, |
1148 /**/ | |
2659 | 1149 79, |
1150 /**/ | |
2658 | 1151 78, |
1152 /**/ | |
2657 | 1153 77, |
1154 /**/ | |
2656 | 1155 76, |
1156 /**/ | |
2655 | 1157 75, |
1158 /**/ | |
2654 | 1159 74, |
1160 /**/ | |
2653 | 1161 73, |
1162 /**/ | |
2652 | 1163 72, |
1164 /**/ | |
2651 | 1165 71, |
1166 /**/ | |
2650 | 1167 70, |
1168 /**/ | |
2649 | 1169 69, |
1170 /**/ | |
2648 | 1171 68, |
1172 /**/ | |
2647 | 1173 67, |
1174 /**/ | |
2646 | 1175 66, |
1176 /**/ | |
2645 | 1177 65, |
1178 /**/ | |
2644 | 1179 64, |
1180 /**/ | |
2643 | 1181 63, |
1182 /**/ | |
2641 | 1183 62, |
1184 /**/ | |
2640 | 1185 61, |
1186 /**/ | |
2639 | 1187 60, |
1188 /**/ | |
2638 | 1189 59, |
1190 /**/ | |
2637 | 1191 58, |
1192 /**/ | |
2636 | 1193 57, |
1194 /**/ | |
2635 | 1195 56, |
1196 /**/ | |
2634 | 1197 55, |
1198 /**/ | |
2633 | 1199 54, |
1200 /**/ | |
2632 | 1201 53, |
1202 /**/ | |
2631 | 1203 52, |
1204 /**/ | |
2630 | 1205 51, |
1206 /**/ | |
2629 | 1207 50, |
1208 /**/ | |
2628 | 1209 49, |
1210 /**/ | |
2627 | 1211 48, |
1212 /**/ | |
2626 | 1213 47, |
1214 /**/ | |
2624 | 1215 46, |
1216 /**/ | |
2623 | 1217 45, |
1218 /**/ | |
2622 | 1219 44, |
1220 /**/ | |
2621 | 1221 43, |
1222 /**/ | |
2620 | 1223 42, |
1224 /**/ | |
2619 | 1225 41, |
1226 /**/ | |
2618 | 1227 40, |
1228 /**/ | |
2617 | 1229 39, |
1230 /**/ | |
2616 | 1231 38, |
1232 /**/ | |
2615 | 1233 37, |
1234 /**/ | |
2614 | 1235 36, |
1236 /**/ | |
2613 | 1237 35, |
1238 /**/ | |
2612 | 1239 34, |
1240 /**/ | |
2611 | 1241 33, |
1242 /**/ | |
2610 | 1243 32, |
1244 /**/ | |
2609 | 1245 31, |
1246 /**/ | |
2607 | 1247 30, |
1248 /**/ | |
2606 | 1249 29, |
1250 /**/ | |
2605 | 1251 28, |
1252 /**/ | |
2604 | 1253 27, |
1254 /**/ | |
2603 | 1255 26, |
1256 /**/ | |
2602 | 1257 25, |
1258 /**/ | |
2601 | 1259 24, |
1260 /**/ | |
2600 | 1261 23, |
1262 /**/ | |
2599 | 1263 22, |
1264 /**/ | |
2598 | 1265 21, |
1266 /**/ | |
2597 | 1267 20, |
1268 /**/ | |
2595 | 1269 19, |
1270 /**/ | |
2594 | 1271 18, |
1272 /**/ | |
2593 | 1273 17, |
1274 /**/ | |
2592 | 1275 16, |
1276 /**/ | |
2591 | 1277 15, |
1278 /**/ | |
2590 | 1279 14, |
1280 /**/ | |
2589 | 1281 13, |
1282 /**/ | |
2588 | 1283 12, |
1284 /**/ | |
2586 | 1285 11, |
1286 /**/ | |
2585 | 1287 10, |
1288 /**/ | |
2584 | 1289 9, |
1290 /**/ | |
2583 | 1291 8, |
1292 /**/ | |
2582 | 1293 7, |
1294 /**/ | |
2580 | 1295 6, |
1296 /**/ | |
2579 | 1297 5, |
1298 /**/ | |
2578 | 1299 4, |
1300 /**/ | |
2165
733f0dc510c3
Undo changes that are meant for the Vim 7.3 branch.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
1301 3, |
733f0dc510c3
Undo changes that are meant for the Vim 7.3 branch.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
1302 /**/ |
733f0dc510c3
Undo changes that are meant for the Vim 7.3 branch.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
1303 2, |
733f0dc510c3
Undo changes that are meant for the Vim 7.3 branch.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
1304 /**/ |
733f0dc510c3
Undo changes that are meant for the Vim 7.3 branch.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
1305 1, |
733f0dc510c3
Undo changes that are meant for the Vim 7.3 branch.
Bram Moolenaar <bram@vim.org>
parents:
2154
diff
changeset
|
1306 /**/ |
7 | 1307 0 |
1308 }; | |
1309 | |
1760 | 1310 /* |
1311 * Place to put a short description when adding a feature with a patch. | |
1312 * Keep it short, e.g.,: "relative numbers", "persistent undo". | |
1313 * Also add a comment marker to separate the lines. | |
1314 * See the official Vim patches for the diff format: It must use a context of | |
1777 | 1315 * one line only. Create it by hand or use "diff -C2" and edit the patch. |
1760 | 1316 */ |
1317 static char *(extra_patches[]) = | |
1318 { /* Add your patch description below this line */ | |
1319 /**/ | |
1320 NULL | |
1321 }; | |
1322 | |
7 | 1323 int |
1324 highest_patch() | |
1325 { | |
1326 int i; | |
1327 int h = 0; | |
1328 | |
1329 for (i = 0; included_patches[i] != 0; ++i) | |
1330 if (included_patches[i] > h) | |
1331 h = included_patches[i]; | |
1332 return h; | |
1333 } | |
1334 | |
1335 #if defined(FEAT_EVAL) || defined(PROTO) | |
1336 /* | |
1337 * Return TRUE if patch "n" has been included. | |
1338 */ | |
1339 int | |
1340 has_patch(n) | |
1341 int n; | |
1342 { | |
1343 int i; | |
1344 | |
1345 for (i = 0; included_patches[i] != 0; ++i) | |
1346 if (included_patches[i] == n) | |
1347 return TRUE; | |
1348 return FALSE; | |
1349 } | |
1350 #endif | |
1351 | |
1352 void | |
1353 ex_version(eap) | |
1354 exarg_T *eap; | |
1355 { | |
1356 /* | |
1357 * Ignore a ":version 9.99" command. | |
1358 */ | |
1359 if (*eap->arg == NUL) | |
1360 { | |
1361 msg_putchar('\n'); | |
1362 list_version(); | |
1363 } | |
1364 } | |
1365 | |
1366 void | |
1367 list_version() | |
1368 { | |
1369 int i; | |
1370 int first; | |
1371 char *s = ""; | |
1372 | |
1373 /* | |
1374 * When adding features here, don't forget to update the list of | |
1375 * internal variables in eval.c! | |
1376 */ | |
1377 MSG(longVersion); | |
1378 #ifdef WIN3264 | |
1379 # ifdef FEAT_GUI_W32 | |
1380 # if defined(_MSC_VER) && (_MSC_VER <= 1010) | |
1381 /* Only MS VC 4.1 and earlier can do Win32s */ | |
1607 | 1382 MSG_PUTS(_("\nMS-Windows 16/32-bit GUI version")); |
7 | 1383 # else |
990 | 1384 # ifdef _WIN64 |
1607 | 1385 MSG_PUTS(_("\nMS-Windows 64-bit GUI version")); |
990 | 1386 # else |
1607 | 1387 MSG_PUTS(_("\nMS-Windows 32-bit GUI version")); |
990 | 1388 # endif |
7 | 1389 # endif |
1390 if (gui_is_win32s()) | |
1391 MSG_PUTS(_(" in Win32s mode")); | |
1392 # ifdef FEAT_OLE | |
1393 MSG_PUTS(_(" with OLE support")); | |
1394 # endif | |
1395 # else | |
1607 | 1396 # ifdef _WIN64 |
1397 MSG_PUTS(_("\nMS-Windows 64-bit console version")); | |
1398 # else | |
1399 MSG_PUTS(_("\nMS-Windows 32-bit console version")); | |
1400 # endif | |
7 | 1401 # endif |
1402 #endif | |
1403 #ifdef WIN16 | |
1607 | 1404 MSG_PUTS(_("\nMS-Windows 16-bit version")); |
7 | 1405 #endif |
1406 #ifdef MSDOS | |
1407 # ifdef DJGPP | |
1607 | 1408 MSG_PUTS(_("\n32-bit MS-DOS version")); |
7 | 1409 # else |
1607 | 1410 MSG_PUTS(_("\n16-bit MS-DOS version")); |
7 | 1411 # endif |
1412 #endif | |
1413 #ifdef MACOS | |
1414 # ifdef MACOS_X | |
1415 # ifdef MACOS_X_UNIX | |
1416 MSG_PUTS(_("\nMacOS X (unix) version")); | |
1417 # else | |
1418 MSG_PUTS(_("\nMacOS X version")); | |
1419 # endif | |
1420 #else | |
1421 MSG_PUTS(_("\nMacOS version")); | |
1422 # endif | |
1423 #endif | |
1424 | |
1425 #ifdef VMS | |
1705 | 1426 MSG_PUTS(_("\nOpenVMS version")); |
1045 | 1427 # ifdef HAVE_PATHDEF |
1428 if (*compiled_arch != NUL) | |
1429 { | |
1430 MSG_PUTS(" - "); | |
1431 MSG_PUTS(compiled_arch); | |
1432 } | |
1433 # endif | |
1434 | |
7 | 1435 #endif |
1436 | |
1437 /* Print the list of patch numbers if there is at least one. */ | |
1438 /* Print a range when patches are consecutive: "1-10, 12, 15-40, 42-45" */ | |
1439 if (included_patches[0] != 0) | |
1440 { | |
1441 MSG_PUTS(_("\nIncluded patches: ")); | |
1442 first = -1; | |
1443 /* find last one */ | |
1444 for (i = 0; included_patches[i] != 0; ++i) | |
1445 ; | |
1446 while (--i >= 0) | |
1447 { | |
1448 if (first < 0) | |
1449 first = included_patches[i]; | |
1450 if (i == 0 || included_patches[i - 1] != included_patches[i] + 1) | |
1451 { | |
1452 MSG_PUTS(s); | |
1453 s = ", "; | |
1454 msg_outnum((long)first); | |
1455 if (first != included_patches[i]) | |
1456 { | |
1457 MSG_PUTS("-"); | |
1458 msg_outnum((long)included_patches[i]); | |
1459 } | |
1460 first = -1; | |
1461 } | |
1462 } | |
1463 } | |
1464 | |
1760 | 1465 /* Print the list of extra patch descriptions if there is at least one. */ |
1466 if (extra_patches[0] != NULL) | |
1467 { | |
1468 MSG_PUTS(_("\nExtra patches: ")); | |
1469 s = ""; | |
1470 for (i = 0; extra_patches[i] != NULL; ++i) | |
1471 { | |
1472 MSG_PUTS(s); | |
1473 s = ", "; | |
1474 MSG_PUTS(extra_patches[i]); | |
1475 } | |
1476 } | |
1477 | |
7 | 1478 #ifdef MODIFIED_BY |
1479 MSG_PUTS("\n"); | |
1480 MSG_PUTS(_("Modified by ")); | |
1481 MSG_PUTS(MODIFIED_BY); | |
1482 #endif | |
1483 | |
1484 #ifdef HAVE_PATHDEF | |
1485 if (*compiled_user != NUL || *compiled_sys != NUL) | |
1486 { | |
1487 MSG_PUTS(_("\nCompiled ")); | |
1488 if (*compiled_user != NUL) | |
1489 { | |
1490 MSG_PUTS(_("by ")); | |
1491 MSG_PUTS(compiled_user); | |
1492 } | |
1493 if (*compiled_sys != NUL) | |
1494 { | |
1495 MSG_PUTS("@"); | |
1496 MSG_PUTS(compiled_sys); | |
1497 } | |
1498 } | |
1499 #endif | |
1500 | |
1501 #ifdef FEAT_HUGE | |
1502 MSG_PUTS(_("\nHuge version ")); | |
1503 #else | |
1504 # ifdef FEAT_BIG | |
1505 MSG_PUTS(_("\nBig version ")); | |
1506 # else | |
1507 # ifdef FEAT_NORMAL | |
1508 MSG_PUTS(_("\nNormal version ")); | |
1509 # else | |
1510 # ifdef FEAT_SMALL | |
1511 MSG_PUTS(_("\nSmall version ")); | |
1512 # else | |
1513 MSG_PUTS(_("\nTiny version ")); | |
1514 # endif | |
1515 # endif | |
1516 # endif | |
1517 #endif | |
1518 #ifndef FEAT_GUI | |
1519 MSG_PUTS(_("without GUI.")); | |
1520 #else | |
1521 # ifdef FEAT_GUI_GTK | |
1522 # ifdef FEAT_GUI_GNOME | |
1523 MSG_PUTS(_("with GTK2-GNOME GUI.")); | |
1524 # else | |
1525 MSG_PUTS(_("with GTK2 GUI.")); | |
1526 # endif | |
1527 # else | |
1528 # ifdef FEAT_GUI_MOTIF | |
1529 MSG_PUTS(_("with X11-Motif GUI.")); | |
1530 # else | |
1531 # ifdef FEAT_GUI_ATHENA | |
1532 # ifdef FEAT_GUI_NEXTAW | |
1533 MSG_PUTS(_("with X11-neXtaw GUI.")); | |
1534 # else | |
1535 MSG_PUTS(_("with X11-Athena GUI.")); | |
1536 # endif | |
1537 # else | |
1538 # ifdef FEAT_GUI_PHOTON | |
1539 MSG_PUTS(_("with Photon GUI.")); | |
1540 # else | |
1541 # if defined(MSWIN) | |
1542 MSG_PUTS(_("with GUI.")); | |
1543 # else | |
2250
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
1544 # if defined(TARGET_API_MAC_CARBON) && TARGET_API_MAC_CARBON |
7 | 1545 MSG_PUTS(_("with Carbon GUI.")); |
1546 # else | |
2250
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
1547 # if defined(TARGET_API_MAC_OSX) && TARGET_API_MAC_OSX |
7 | 1548 MSG_PUTS(_("with Cocoa GUI.")); |
1549 # else | |
2250
1bac28a53fae
Add the conceal patch from Vince Negri.
Bram Moolenaar <bram@vim.org>
parents:
2214
diff
changeset
|
1550 # if defined(MACOS) |
7 | 1551 MSG_PUTS(_("with (classic) GUI.")); |
1552 # endif | |
1553 # endif | |
1554 # endif | |
1555 # endif | |
1556 # endif | |
1557 # endif | |
1558 # endif | |
1559 # endif | |
1560 #endif | |
1561 version_msg(_(" Features included (+) or not (-):\n")); | |
1562 | |
1563 /* print all the features */ | |
1564 for (i = 0; features[i] != NULL; ++i) | |
1565 { | |
1566 version_msg(features[i]); | |
1567 if (msg_col > 0) | |
1568 version_msg(" "); | |
1569 } | |
1570 | |
1571 version_msg("\n"); | |
1572 #ifdef SYS_VIMRC_FILE | |
1573 version_msg(_(" system vimrc file: \"")); | |
1574 version_msg(SYS_VIMRC_FILE); | |
1575 version_msg("\"\n"); | |
1576 #endif | |
1577 #ifdef USR_VIMRC_FILE | |
1578 version_msg(_(" user vimrc file: \"")); | |
1579 version_msg(USR_VIMRC_FILE); | |
1580 version_msg("\"\n"); | |
1581 #endif | |
1582 #ifdef USR_VIMRC_FILE2 | |
1583 version_msg(_(" 2nd user vimrc file: \"")); | |
1584 version_msg(USR_VIMRC_FILE2); | |
1585 version_msg("\"\n"); | |
1586 #endif | |
1587 #ifdef USR_VIMRC_FILE3 | |
1588 version_msg(_(" 3rd user vimrc file: \"")); | |
1589 version_msg(USR_VIMRC_FILE3); | |
1590 version_msg("\"\n"); | |
1591 #endif | |
1592 #ifdef USR_EXRC_FILE | |
1593 version_msg(_(" user exrc file: \"")); | |
1594 version_msg(USR_EXRC_FILE); | |
1595 version_msg("\"\n"); | |
1596 #endif | |
1597 #ifdef USR_EXRC_FILE2 | |
1598 version_msg(_(" 2nd user exrc file: \"")); | |
1599 version_msg(USR_EXRC_FILE2); | |
1600 version_msg("\"\n"); | |
1601 #endif | |
1602 #ifdef FEAT_GUI | |
1603 # ifdef SYS_GVIMRC_FILE | |
1604 version_msg(_(" system gvimrc file: \"")); | |
1605 version_msg(SYS_GVIMRC_FILE); | |
1606 version_msg("\"\n"); | |
1607 # endif | |
1608 version_msg(_(" user gvimrc file: \"")); | |
1609 version_msg(USR_GVIMRC_FILE); | |
1610 version_msg("\"\n"); | |
1611 # ifdef USR_GVIMRC_FILE2 | |
1612 version_msg(_("2nd user gvimrc file: \"")); | |
1613 version_msg(USR_GVIMRC_FILE2); | |
1614 version_msg("\"\n"); | |
1615 # endif | |
1616 # ifdef USR_GVIMRC_FILE3 | |
1617 version_msg(_("3rd user gvimrc file: \"")); | |
1618 version_msg(USR_GVIMRC_FILE3); | |
1619 version_msg("\"\n"); | |
1620 # endif | |
1621 #endif | |
1622 #ifdef FEAT_GUI | |
1623 # ifdef SYS_MENU_FILE | |
1624 version_msg(_(" system menu file: \"")); | |
1625 version_msg(SYS_MENU_FILE); | |
1626 version_msg("\"\n"); | |
1627 # endif | |
1628 #endif | |
1629 #ifdef HAVE_PATHDEF | |
1630 if (*default_vim_dir != NUL) | |
1631 { | |
1632 version_msg(_(" fall-back for $VIM: \"")); | |
1633 version_msg((char *)default_vim_dir); | |
1634 version_msg("\"\n"); | |
1635 } | |
1636 if (*default_vimruntime_dir != NUL) | |
1637 { | |
1638 version_msg(_(" f-b for $VIMRUNTIME: \"")); | |
1639 version_msg((char *)default_vimruntime_dir); | |
1640 version_msg("\"\n"); | |
1641 } | |
1642 version_msg(_("Compilation: ")); | |
1643 version_msg((char *)all_cflags); | |
1644 version_msg("\n"); | |
1645 #ifdef VMS | |
1646 if (*compiler_version != NUL) | |
1647 { | |
1648 version_msg(_("Compiler: ")); | |
1649 version_msg((char *)compiler_version); | |
1650 version_msg("\n"); | |
1651 } | |
1652 #endif | |
1653 version_msg(_("Linking: ")); | |
1654 version_msg((char *)all_lflags); | |
1655 #endif | |
1656 #ifdef DEBUG | |
1657 version_msg("\n"); | |
1658 version_msg(_(" DEBUG BUILD")); | |
1659 #endif | |
1660 } | |
1661 | |
1662 /* | |
1663 * Output a string for the version message. If it's going to wrap, output a | |
1664 * newline, unless the message is too long to fit on the screen anyway. | |
1665 */ | |
1666 static void | |
1667 version_msg(s) | |
1668 char *s; | |
1669 { | |
1670 int len = (int)STRLEN(s); | |
1671 | |
1672 if (!got_int && len < (int)Columns && msg_col + len >= (int)Columns | |
1673 && *s != '\n') | |
1674 msg_putchar('\n'); | |
1675 if (!got_int) | |
1676 MSG_PUTS(s); | |
1677 } | |
1678 | |
1679 static void do_intro_line __ARGS((int row, char_u *mesg, int add_version, int attr)); | |
1680 | |
1681 /* | |
1682 * Give an introductory message about Vim. | |
1683 * Only used when starting Vim on an empty file, without a file name. | |
1684 * Or with the ":intro" command (for Sven :-). | |
1685 */ | |
1686 void | |
1687 intro_message(colon) | |
1688 int colon; /* TRUE for ":intro" */ | |
1689 { | |
1690 int i; | |
1691 int row; | |
1692 int blanklines; | |
1693 int sponsor; | |
1694 char *p; | |
1695 static char *(lines[]) = | |
1696 { | |
1697 N_("VIM - Vi IMproved"), | |
1698 "", | |
1699 N_("version "), | |
1700 N_("by Bram Moolenaar et al."), | |
1701 #ifdef MODIFIED_BY | |
1702 " ", | |
1703 #endif | |
1704 N_("Vim is open source and freely distributable"), | |
1705 "", | |
1706 N_("Help poor children in Uganda!"), | |
1707 N_("type :help iccf<Enter> for information "), | |
1708 "", | |
1709 N_("type :q<Enter> to exit "), | |
1710 N_("type :help<Enter> or <F1> for on-line help"), | |
26 | 1711 N_("type :help version7<Enter> for version info"), |
7 | 1712 NULL, |
1713 "", | |
1714 N_("Running in Vi compatible mode"), | |
1715 N_("type :set nocp<Enter> for Vim defaults"), | |
1716 N_("type :help cp-default<Enter> for info on this"), | |
1717 }; | |
1718 #ifdef FEAT_GUI | |
1719 static char *(gui_lines[]) = | |
1720 { | |
1721 NULL, | |
1722 NULL, | |
1723 NULL, | |
1724 NULL, | |
1725 #ifdef MODIFIED_BY | |
1726 NULL, | |
1727 #endif | |
1728 NULL, | |
1729 NULL, | |
1730 NULL, | |
1731 N_("menu Help->Orphans for information "), | |
1732 NULL, | |
1733 N_("Running modeless, typed text is inserted"), | |
1734 N_("menu Edit->Global Settings->Toggle Insert Mode "), | |
1735 N_(" for two modes "), | |
1736 NULL, | |
1737 NULL, | |
1738 NULL, | |
1739 N_("menu Edit->Global Settings->Toggle Vi Compatible"), | |
1740 N_(" for Vim defaults "), | |
1741 }; | |
1742 #endif | |
1743 | |
1744 /* blanklines = screen height - # message lines */ | |
1745 blanklines = (int)Rows - ((sizeof(lines) / sizeof(char *)) - 1); | |
1746 if (!p_cp) | |
1747 blanklines += 4; /* add 4 for not showing "Vi compatible" message */ | |
1748 #if defined(WIN3264) && !defined(FEAT_GUI_W32) | |
1749 if (mch_windows95()) | |
1750 blanklines -= 3; /* subtract 3 for showing "Windows 95" message */ | |
1751 #endif | |
1752 | |
1753 #ifdef FEAT_WINDOWS | |
1754 /* Don't overwrite a statusline. Depends on 'cmdheight'. */ | |
1755 if (p_ls > 1) | |
1756 blanklines -= Rows - topframe->fr_height; | |
1757 #endif | |
1758 if (blanklines < 0) | |
1759 blanklines = 0; | |
1760 | |
1761 /* Show the sponsor and register message one out of four times, the Uganda | |
1762 * message two out of four times. */ | |
615 | 1763 sponsor = (int)time(NULL); |
7 | 1764 sponsor = ((sponsor & 2) == 0) - ((sponsor & 4) == 0); |
1765 | |
1766 /* start displaying the message lines after half of the blank lines */ | |
1767 row = blanklines / 2; | |
1768 if ((row >= 2 && Columns >= 50) || colon) | |
1769 { | |
1770 for (i = 0; i < (int)(sizeof(lines) / sizeof(char *)); ++i) | |
1771 { | |
1772 p = lines[i]; | |
1773 #ifdef FEAT_GUI | |
1774 if (p_im && gui.in_use && gui_lines[i] != NULL) | |
1775 p = gui_lines[i]; | |
1776 #endif | |
1777 if (p == NULL) | |
1778 { | |
1779 if (!p_cp) | |
1780 break; | |
1781 continue; | |
1782 } | |
1783 if (sponsor != 0) | |
1784 { | |
1785 if (strstr(p, "children") != NULL) | |
1786 p = sponsor < 0 | |
1787 ? N_("Sponsor Vim development!") | |
1788 : N_("Become a registered Vim user!"); | |
1789 else if (strstr(p, "iccf") != NULL) | |
1790 p = sponsor < 0 | |
1791 ? N_("type :help sponsor<Enter> for information ") | |
1792 : N_("type :help register<Enter> for information "); | |
1793 else if (strstr(p, "Orphans") != NULL) | |
1794 p = N_("menu Help->Sponsor/Register for information "); | |
1795 } | |
1796 if (*p != NUL) | |
1797 do_intro_line(row, (char_u *)_(p), i == 2, 0); | |
1798 ++row; | |
1799 } | |
1800 #if defined(WIN3264) && !defined(FEAT_GUI_W32) | |
1801 if (mch_windows95()) | |
1802 { | |
1803 do_intro_line(++row, | |
1804 (char_u *)_("WARNING: Windows 95/98/ME detected"), | |
1805 FALSE, hl_attr(HLF_E)); | |
1806 do_intro_line(++row, | |
1807 (char_u *)_("type :help windows95<Enter> for info on this"), | |
1808 FALSE, 0); | |
1809 } | |
1810 #endif | |
1811 } | |
1812 | |
1813 /* Make the wait-return message appear just below the text. */ | |
1814 if (colon) | |
1815 msg_row = row; | |
1816 } | |
1817 | |
1818 static void | |
1819 do_intro_line(row, mesg, add_version, attr) | |
1820 int row; | |
1821 char_u *mesg; | |
1822 int add_version; | |
1823 int attr; | |
1824 { | |
1825 char_u vers[20]; | |
1826 int col; | |
1827 char_u *p; | |
1828 int l; | |
1829 int clen; | |
1830 #ifdef MODIFIED_BY | |
1831 # define MODBY_LEN 150 | |
1832 char_u modby[MODBY_LEN]; | |
1833 | |
1834 if (*mesg == ' ') | |
1835 { | |
1491 | 1836 vim_strncpy(modby, (char_u *)_("Modified by "), MODBY_LEN - 1); |
7 | 1837 l = STRLEN(modby); |
1491 | 1838 vim_strncpy(modby + l, (char_u *)MODIFIED_BY, MODBY_LEN - l - 1); |
7 | 1839 mesg = modby; |
1840 } | |
1841 #endif | |
1842 | |
1843 /* Center the message horizontally. */ | |
1844 col = vim_strsize(mesg); | |
1845 if (add_version) | |
1846 { | |
1847 STRCPY(vers, mediumVersion); | |
1848 if (highest_patch()) | |
1849 { | |
1850 /* Check for 9.9x or 9.9xx, alpha/beta version */ | |
2619 | 1851 if (isalpha((int)vers[3])) |
7 | 1852 { |
2619 | 1853 if (isalpha((int)vers[4])) |
7 | 1854 sprintf((char *)vers + 5, ".%d%s", highest_patch(), |
1855 mediumVersion + 5); | |
1856 else | |
1857 sprintf((char *)vers + 4, ".%d%s", highest_patch(), | |
1858 mediumVersion + 4); | |
1859 } | |
1860 else | |
1861 sprintf((char *)vers + 3, ".%d", highest_patch()); | |
1862 } | |
1863 col += (int)STRLEN(vers); | |
1864 } | |
1865 col = (Columns - col) / 2; | |
1866 if (col < 0) | |
1867 col = 0; | |
1868 | |
1869 /* Split up in parts to highlight <> items differently. */ | |
1870 for (p = mesg; *p != NUL; p += l) | |
1871 { | |
1872 clen = 0; | |
1873 for (l = 0; p[l] != NUL | |
1874 && (l == 0 || (p[l] != '<' && p[l - 1] != '>')); ++l) | |
1875 { | |
1876 #ifdef FEAT_MBYTE | |
1877 if (has_mbyte) | |
1878 { | |
1879 clen += ptr2cells(p + l); | |
474 | 1880 l += (*mb_ptr2len)(p + l) - 1; |
7 | 1881 } |
1882 else | |
1883 #endif | |
1884 clen += byte2cells(p[l]); | |
1885 } | |
1886 screen_puts_len(p, l, row, col, *p == '<' ? hl_attr(HLF_8) : attr); | |
1887 col += clen; | |
1888 } | |
1889 | |
1890 /* Add the version number to the version line. */ | |
1891 if (add_version) | |
1892 screen_puts(vers, row, col, 0); | |
1893 } | |
1894 | |
1895 /* | |
1896 * ":intro": clear screen, display intro screen and wait for return. | |
1897 */ | |
1898 void | |
1899 ex_intro(eap) | |
1876 | 1900 exarg_T *eap UNUSED; |
7 | 1901 { |
1902 screenclear(); | |
1903 intro_message(TRUE); | |
1904 wait_return(TRUE); | |
1905 } |