diff -u -r1.390 startup.el --- lisp/startup.el 22 Nov 2005 03:32:50 -0000 1.390 +++ lisp/startup.el 26 Dec 2005 19:48:55 -0000 @@ -149,7 +149,8 @@ ("--vertical-scroll-bars" 0 x-handle-switch vertical-scroll-bars t) ("--line-spacing" 1 x-handle-numeric-switch line-spacing) ("--border-color" 1 x-handle-switch border-color) - ("--smid" 1 x-handle-smid)) + ("--smid" 1 x-handle-smid) + ("--parent-id" 1 x-handle-parent-id)) "Alist of X Windows options. Each element has the form (NAME NUMARGS HANDLER FRAME-PARAM VALUE) diff -u -r1.184 x-win.el --- lisp/term/x-win.el 2 Nov 2005 21:43:21 -0000 1.184 +++ lisp/term/x-win.el 26 Dec 2005 19:48:59 -0000 @@ -181,6 +181,15 @@ (setq initial-frame-alist (cons (cons 'name x-resource-name) initial-frame-alist))) +;; Handle the --parent-id option. +(defun x-handle-parent-id (switch) + (or (consp x-invocation-args) + (error "%s: missing argument to `%s' option" (invocation-name) switch)) + (setq parent-id (string-to-number (car x-invocation-args)) + x-invocation-args (cdr x-invocation-args)) + (setq initial-frame-alist (cons (cons 'parent-id parent-id) + initial-frame-alist))) + (defvar x-display-name nil "The X display name specifying server and X frame.") diff -u -r1.380 emacs.c --- src/emacs.c 23 Nov 2005 07:19:03 -0000 1.380 +++ src/emacs.c 26 Dec 2005 19:49:03 -0000 @@ -322,6 +322,7 @@ --title, -T TITLE title for initial Emacs frame\n\ --vertical-scroll-bars, -vb enable vertical scroll bars\n\ --xrm XRESOURCES set additional X resources\n\ +--parent-id XID set parent window\n\ --help display this help and exit\n\ --version output version information and exit\n\ \n" @@ -1859,6 +1860,7 @@ { "-title", 0, 10, 1 }, { "-name", "--name", 10, 1 }, { "-xrm", "--xrm", 10, 1 }, + { "-parent-id", "--parent-id", 10, 1 }, { "-r", "--reverse-video", 5, 0 }, { "-rv", 0, 5, 0 }, { "-reverse", 0, 5, 0 },