Re: Coming to closure on ae...
On Tue, 5 May 1998, Carlos Barros wrote:
> On Wed, 6 May 1998, Anand Kumria wrote:
> > On Sat, 2 May 1998, Dale Scheetz wrote:
> > > There doesn't seem to be a "reliable" method for determining whether or
> > > not you are in an xterm. Any method so far suggested has "natural"
> > > configuration situations that break the method.
> > How about just checking for the existance of the DISPLAY variable?
> What about trying to connext to X server, and if an error, do it in
> terminal mode.
That doesn't work properly when working from a console if you have access
rights to a local X server. The same goes for testing the DISPLAY
variable. The only other way I can come up with is checking the WINDOWID
variable. Or look at how 'elvis' determines if it's running in X or not. I
don't know how elvis checks for X, but it does this quite well.
To UNSUBSCRIBE, email to firstname.lastname@example.org
with a subject of "unsubscribe". Trouble? Contact email@example.com