summaryrefslogtreecommitdiff
path: root/src/w32proc.c
diff options
context:
space:
mode:
authorRichard M. Stallman <rms@gnu.org>1996-08-31 20:13:29 +0000
committerRichard M. Stallman <rms@gnu.org>1996-08-31 20:13:29 +0000
commitf57b111a04873d9e0842adceedfa499a1e441d23 (patch)
treec8d1ca1ca9b896e30e62e3c93213f059eb76210a /src/w32proc.c
parentb4cd9201ce6c680f35975787b7508997a62ed1df (diff)
downloademacs-f57b111a04873d9e0842adceedfa499a1e441d23.tar.gz
(Vwin32_start_process_show_window): New variable.
(create_child): Conditionally force subprocess to hide window. (syms_of_ntproc): DEFVAR it.
Diffstat (limited to 'src/w32proc.c')
-rw-r--r--src/w32proc.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/src/w32proc.c b/src/w32proc.c
index 01ffd33bebb..71aa2b41a31 100644
--- a/src/w32proc.c
+++ b/src/w32proc.c
@@ -51,6 +51,10 @@ Boston, MA 02111-1307, USA.
conditional (off by default). */
Lisp_Object Vwin32_quote_process_args;
+/* Control whether create_child causes the process' window to be
+ hidden. The default is nil. */
+Lisp_Object Vwin32_start_process_show_window;
+
/* Time to sleep before reading from a subprocess output pipe - this
avoids the inefficiency of frequently reading small amounts of data.
This is primarily necessary for handling DOS processes on Windows 95,
@@ -284,7 +288,10 @@ create_child (char *exe, char *cmdline, char *env,
start.cb = sizeof (start);
#ifdef HAVE_NTGUI
- start.dwFlags = STARTF_USESTDHANDLES | STARTF_USESHOWWINDOW;
+ if (NILP (Vwin32_start_process_show_window))
+ start.dwFlags = STARTF_USESTDHANDLES | STARTF_USESHOWWINDOW;
+ else
+ start.dwFlags = STARTF_USESTDHANDLES;
start.wShowWindow = SW_HIDE;
start.hStdInput = GetStdHandle (STD_INPUT_HANDLE);
@@ -1244,6 +1251,12 @@ constructed (or arguments have already been quoted), so enabling this\n\
option may cause unexpected behavior.");
Vwin32_quote_process_args = Qnil;
+ DEFVAR_LISP ("win32-start-process-show-window",
+ &Vwin32_start_process_show_window,
+ "When nil, processes started via start-process hide their windows.\n\
+When non-nil, they show their window in the method of their choice.");
+ Vwin32_start_process_show_window = Qnil;
+
DEFVAR_INT ("win32-pipe-read-delay", &Vwin32_pipe_read_delay,
"Forced delay before reading subprocess output.\n\
This is done to improve the buffering of subprocess output, by\n\