Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!cbatt!ucbvax!ALEXANDER.BBN.COM!jr From: jr@ALEXANDER.BBN.COM.UUCP Newsgroups: comp.emacs Subject: Re: gnumacs and x windows Message-ID: <8702201506.AA15396@ucbvax.Berkeley.EDU> Date: Fri, 20-Feb-87 10:07:14 EST Article-I.D.: ucbvax.8702201506.AA15396 Posted: Fri Feb 20 10:07:14 1987 Date-Received: Sat, 21-Feb-87 06:34:28 EST References: <8702191629.AA02335@tristram.cs.purdue.edu> Sender: daemon@ucbvax.BERKELEY.EDU Organization: The ARPA Internet Lines: 40 >> 1. What are the advantages of using gnumacs in this way? The only >> one I can see is that it enables you to bind mouse clicks to perform >> editing functions. Although this *is* an advantage, there are some >> disadvantages to gnumacs with HAVE_X_WINDOWS defined (2 & 3, below). I think the biggest single advantage is that the server and client may be different machines, and emacs opens the X connection automatically for you. So I can ask for an emacs running on my file server (so I can do some tool maintenance, say), and it pops up a window back on my workstation. Thus, I can have a command alias (or shellscript) of the form: rsh my-server "(setenv TERM xterm; setenv DISPLAY my-works:0; emacs)" Compare this to starting up a new xterm window and then executing the rlogin and then running emacs - you avoid the xterm altogether, and emacs will do a better job at screen updating to boot since it can skip all the termcap/termlib stuff. More generally, the following shellscript allows for any X command to be executed remotely (or any command in background for that matter). #!/bin/sh case $# in [01]) echo "Usage: $0 host x-cmd [args...]";; *) host="$1"; shift xhost "$host" rsh "$host" "(setenv TERM xterm; setenv DISPLAY `hostname`:0; $*)" & ;; esac On autoraise: can't you get close to what you want with appropriate window manager bindings? Does require a mouse click, I guess, but is that too awful? /jr jr@bbn.com or jr@bbnccv.uucp Without life, there wouldn't be chemical companies.