To:
[email protected]
Subject: Patch 5.6a.020
Fcc: outbox
From: Bram Moolenaar <
[email protected]>
------------
Patch 5.6a.020
Problem: GUI GTK: Could not set display for gvim.
Solution: Add "-display" and "--display" arguments. (Marcin Dalecki)
Files: src/gui_gtk_x11.c, src/main.c, runtime/doc/gui_x11.txt
*** ../vim-5.6a.19/src/gui_gtk_x11.c Sat Jan 8 23:13:04 2000
--- src/gui_gtk_x11.c Tue Jan 11 16:50:07 2000
***************
*** 183,189 ****
{"-italicfont", ".italicFont", XrmoptionSepArg, NULL},
{"+reverse", "*reverseVideo", XrmoptionNoArg, "False"},
{"+rv", "*reverseVideo", XrmoptionNoArg, "False"},
- {"-display", ".display", XrmoptionSepArg, NULL},
{"-iconic", "*iconic", XrmoptionNoArg, "True"},
{"-name", ".name", XrmoptionSepArg, NULL},
{"-bw", ".borderWidth", XrmoptionSepArg, NULL},
--- 183,188 ----
***************
*** 210,215 ****
--- 209,216 ----
"--gtk-no-debug=",
"--g-fatal-warnings",
"--gtk-module=",
+ "-display",
+ "--display",
NULL
};
***************
*** 263,269 ****
mch_memmove(&argv[arg], &argv[arg + 1],
(*argc - arg) * sizeof(char *));
if (cmdline_options[i].argKind != XrmoptionNoArg) {
! /* Move the options argument as well */
gui_argv[gui_argc++] = argv[arg];
if (--*argc > arg)
mch_memmove(&argv[arg], &argv[arg + 1],
--- 264,270 ----
mch_memmove(&argv[arg], &argv[arg + 1],
(*argc - arg) * sizeof(char *));
if (cmdline_options[i].argKind != XrmoptionNoArg) {
! /* Move the option argument as well. */
gui_argv[gui_argc++] = argv[arg];
if (--*argc > arg)
mch_memmove(&argv[arg], &argv[arg + 1],
***************
*** 283,298 ****
{
if (strncmp(argv[arg], *gtk_option, strlen(*gtk_option)) == 0)
{
! gui_argv[gui_argc++] = argv[arg];
if (--*argc > arg)
- mch_memmove(&argv[arg], &argv[arg + 1],
- (*argc - arg) * sizeof(char *));
- if (strncmp(*gtk_option, "--xim", 5) == 0)
{
! gui_argv[gui_argc++] = argv[arg];
! if (--*argc > arg)
! mch_memmove(&argv[arg], &argv[arg + 1],
(*argc - arg) * sizeof(char *));
}
break;
}
--- 284,310 ----
{
if (strncmp(argv[arg], *gtk_option, strlen(*gtk_option)) == 0)
{
! /* Replace the standard X argument "-display" with the GTK
! * argument "--display". */
! if (strncmp(*gtk_option, "-display", 8) == 0)
! gui_argv[gui_argc++] =
! (char *)vim_strsave((char_u *)"--display");
! else
! gui_argv[gui_argc++] = argv[arg];
if (--*argc > arg)
{
! mch_memmove(&argv[arg], &argv[arg + 1],
! (*argc - arg) * sizeof(char *));
! /* Move the option argument as well, if there is one. */
! if (strncmp(*gtk_option, "--xim", 5) == 0
! || strncmp(*gtk_option, "-display", 8) == 0
! || strncmp(*gtk_option, "--display", 9) == 0)
! {
! gui_argv[gui_argc++] = argv[arg];
! if (--*argc > arg)
! mch_memmove(&argv[arg], &argv[arg + 1],
(*argc - arg) * sizeof(char *));
+ }
}
break;
}
*** ../vim-5.6a.19/src/main.c Mon Dec 20 09:59:08 1999
--- src/main.c Tue Jan 11 16:40:22 2000
***************
*** 203,208 ****
--- 203,209 ----
main_msg("-font <font>\t\tUse <font> for normal text (also: -fn)");
main_msg("-geometry <geom>\tUse <geom> for initial geometry (also: -geom)");
main_msg("-reverse\t\tUse reverse video (also: -rv)");
+ main_msg("-display <display>\tRun vim on <display> (also: --display)");
#endif
mch_windexit(1);
}
*** ../vim-5.6a.19/runtime/doc/gui_x11.txt Mon Dec 20 09:59:30 1999
--- runtime/doc/gui_x11.txt Tue Jan 11 16:47:46 2000
***************
*** 1,4 ****
! *gui_x11.txt* For Vim version 5.6a. Last change: 1999 Dec 09
VIM REFERENCE MANUAL by Bram Moolenaar
--- 1,4 ----
! *gui_x11.txt* For Vim version 5.6a. Last change: 2000 Jan 01
VIM REFERENCE MANUAL by Bram Moolenaar
***************
*** 249,254 ****
--- 249,255 ----
-fn or -font .font font name for the text
-geom or -geometry .geometry size of the gvim window
-rv or -reverse *reverseVideo white text on black background
+ -display display to be used
To set the font, see |'guifont'|. For GTK, there's also a menu option that
does this.
***************
*** 265,270 ****
--- 266,272 ----
--gtk-no-debug
--g-fatal-warnings
--gtk-module
+ --display (GTK+ counterpart of -display; works the same way.)
As for colors, vim's color settings (for syntax highlighting) is still
done the traditional vim way. See |:highlight| for more help.
*** ../vim-5.6a.19/src/version.c Mon Jan 10 21:28:45 2000
--- src/version.c Tue Jan 11 16:48:03 2000
***************
*** 420,421 ****
--- 420,423 ----
{ /* Add new patch number below this line */
+ /**/
+ 20,
/**/
--
hundred-and-one symptoms of being an internet addict:
106. When told to "go to your room" you inform your parents that you
can't...because you were kicked out and banned.
--/-/---- Bram Moolenaar ----
[email protected] ----
[email protected] ---\-\--
\ \ www.vim.org/iccf www.moolenaar.net www.vim.org / /