[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: gdm and display size



-- Matthew Weier O'Phinney <matthew@weierophinney.net> wrote
(on Monday, 07 April 2003, 02:32 PM -0400):
> I'm new to xdm/gdm, and very excited about the possibilities of using my
> higher end machine as an application server to my older machines. I've
> got gdm set up to act as an xdmcp server, and I can successfully log on
> from remote machines and access my desktop.
> 
> This is where it gets a little dicey. One machine I wish to log on from
> is an old P-120 laptop with a 640x480 display; my other displays are all
> 1024x768. 
> 
> Is it possible to detect the resolution of the display on which the
> xdmcp server is drawing? If so, how? I'd like to write a script that
> would load different defaults based on display size.

Just a followup:

First, thanks to both Colin W. and Brian K. for their ideas and scripts
-- they put me on the right track, and got things working for me
initially. 

The real "duh" moment came to me this afternoon when I remembered that
the DISPLAY environmental variable is set to "hostname:0.0" -- I could
simply test for the hostname in the DISPLAY value from within my
.xsession file to determine what set of defaults to use.

So now in my .xsession, I test for the appropriate hostname and set a
few environmental variables, which are then accessed by other setup
files to set up my desktop on this smaller display.

Thanks for all the pointers!

-- 
Matthew Weier O'Phinney
matthew@weierophinney.net
http://matthew.weierophinney.net



Reply to: