home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / sys / hp / 9266 < prev    next >
Encoding:
Internet Message Format  |  1992-08-13  |  2.3 KB

  1. Path: sparky!uunet!olivea!sgigate!odin!mips!sdd.hp.com!hpscdc!hplextra!hpcc05!hpunila!hpfcse!hpfcmgw!chan
  2. From: chan@hpfcmgw.FC.HP.COM (Chan Benson)
  3. Newsgroups: comp.sys.hp
  4. Subject: Re: Xlib bugs in HP-UX 8.07
  5. Message-ID: <17780229@hpfcmgw.FC.HP.COM>
  6. Date: 12 Aug 92 16:41:50 GMT
  7. References: <85922@netnews.upenn.edu>
  8. Organization: HP Fort Collins, CO
  9. Lines: 46
  10.  
  11. > I have two specific complaints about Xlib functions under HP-UX 8.07.
  12. > 1.  For the life of me, I cannot figure out how to add a new font
  13. > directory to a server's font path using XSetFontPath() (or
  14. > equivalently, 'xset +fp' or 'xset fp+').  I wrote a small C program
  15. > that calls XSetFontPath() but it keeps giving me BadValue errors.  It
  16. > is possible to "add" font directories that are already in the path
  17. > (they will appear twice in the path), but adding a new directory
  18. > simply doesn't work, no matter where that directory actually is.  Does
  19. > anybody else have this problem, or am I losing my mind?
  20.  
  21. Make sure you do a "mkfontdir" in the directory you're trying to add
  22. to the font path. 
  23.  
  24. > 2.  Here's a simple Xlib program called xlib-test.c:
  25. > --------------------------------------------------------
  26. ...
  27. >   fg = XGetDefault( disp, argv[0], "foreground" );
  28. >   bg = XGetDefault( disp, argv[0], "background" );
  29. >   rnd = XGetDefault( disp, argv[0], "random" );
  30. ...
  31. > I have no .Xdefaults file in my home directory, and my XENVIRONMENT
  32. > variable is not set, so all three calls to XGetDefault() should have
  33. > returned null.  I get the same results no matter what the name of the
  34. > program is.
  35.  
  36. From the Xlib Manual, Chapter 10, Verse 2:
  37.  
  38. "Defaults are usually loaded into the RESOURCE_MANAGER property on the
  39.  root window at login. If no such property exists, a resource file in 
  40.  the user's home directory is loaded. On a POSIX system, this file is
  41.  $HOME/.Xdefaults."
  42.  
  43. In your case, XGetDefault is returning values from the RESOURCE_MANAGER 
  44. property. See xrdb(1x) for more details. 
  45.  
  46. > Xlib is the lowest level of what's supposed to be the ultimate
  47. > portable window system.  It's very disappointing to discover that even
  48. > basic functions like these have bugs.
  49.  
  50. If X is the "ultimate" in anything, it's in providing job security for
  51. those who've spent years learning its complexities.  I suspect that the
  52. real source of your disappointment is the documentation.
  53.  
  54.             -- Chan Benson
  55.             HP Fort Collins
  56.