Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uwm.edu!wuarchive!kuhub.cc.ukans.edu!maverick.ksu.ksu.edu!deimos.cis.ksu.edu!mccall.com!tp From: tp@mccall.com (Terry Poot) Newsgroups: comp.windows.x.motif Subject: Re: Conditional Resources Message-ID: <1991Apr19.111032@mccall.com> Date: 19 Apr 91 16:10:32 GMT References: <14234@hacgate.UUCP> <13270008@hpsciz.sc.hp.com> Reply-To: tp@mccall.com (Terry Poot) Organization: The McCall Pattern Co., Manhattan, KS, USA Lines: 37 In article <13270008@hpsciz.sc.hp.com>, masa@hpsciz.sc.hp.com (Masayoshi Habu) writes: >In comp.windows.x.motif, sean@mitchell.eos.scg.hac.com (Sean Cohan) >writes: > >> Is it possible to specify in the app-defaults file a conditional if >> statement? I want my x, y, width, and height values to be one set of >> values if the display is a Sun 19" monitor, and I want them to be >> another set of values if the display is a Mac 14" monitor. > >Nice if we could. But there is another solution for this. Your X >server >is usually invoked from a start up script which is called .xinitrc or >something like that in your home directly. In this script, you can >load >resources into your X server by xrdb command. This script is no more >than a simple shell script, so you have control scructures like 'if'. > >Resources loaded to X server by xrdb take precedence over >app-defaults. >Please note that xrdb can pass your resource file through cpp, so you >have another place where control structure like '#ifdef' is available. > >I setup .Xresources file in my home directory and let xrdb read this >file as well as .Xdefaults. My .Xresources file has a bunch of cpp >directives to select the right fonts and colros for various displays >from B&W 16" to 8-plane color 19". Can anyone using Motif on VMS tell me how to do the equivalent of this on VMS? I did it the way the release notes said, which means that I can only use one workstation type or everything will be screwed up. We have 2 workstations, one B&W, and one 4 plane grayscale. We may be getting a new one which will be 8 plane grayscale, with a different screen size. *sigh*. -- Terry Poot The McCall Pattern Company (uucp: ...!rutgers!ksuvax1!deimos!mccall!tp) 615 McCall Road (800)255-2762, in KS (913)776-4041 Manhattan, KS 66502, USA