home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / windows / x / 20677 < prev    next >
Encoding:
Internet Message Format  |  1992-12-31  |  1.8 KB

  1. Xref: sparky comp.windows.x:20677 comp.windows.x.motif:8287 comp.windows.x.intrinsics:698
  2. Newsgroups: comp.windows.x,comp.windows.x.motif,comp.windows.x.intrinsics
  3. Path: sparky!uunet!spool.mu.edu!umn.edu!csus.edu!netcom.com!rogerr
  4. From: rogerr@netcom.com (roger reynolds)
  5. Subject: Xm100TH_FONT_UNITS as XmNunitType problems
  6. Message-ID: <1992Dec31.215525.4798@netcom.com>
  7. Followup-To: poster
  8. Organization: Netcom - Online Communication Services  (408 241-9760 guest) 
  9. Date: Thu, 31 Dec 1992 21:55:25 GMT
  10. Lines: 32
  11.  
  12.     I am trying to use the Xm100TH_FONT_UNITS as the unitType for
  13.     an XmManager widget, and then place children (say XmTextFields)
  14.     at x,y locations which are 100*row (for y) and 100*col (for x)
  15.     The obvious goal being that no matter what font is used, the
  16.     relative positions of the children remain the same.
  17.     
  18.     Problem is it doesn't seem to work.  For example, with the
  19.     font -misc-fixed-*-*-*-*-14-*-*-*-*-*-*-*,
  20.  
  21.     Now, the right edge of a text field created with XmNx 100
  22.     and XmNcolumns 8 will exactly abutt, another text field 
  23.     created with its XmNx set to 800.  Note that I expected
  24.     this with the second XmNx set to 900, or 100 + 800, or
  25.     col 1 + 8 columns.  So, already I see that the fontUnits
  26.     do not appear to be accurate.
  27.  
  28.     Secondly, if I change the font in the above example to
  29.     -misc-fixed-*-*-*-*-24-*-*-*-*-*-*-*,  the 2 text fields
  30.     no longer abutt, but overlap by 2.5 columns or so.  The
  31.     problem naturally gets worse as values of XmNx increase.
  32.     And this is with a fixed width font!
  33.  
  34.     So hears the question,  did I completely misunderstand the 
  35.     purpose of XmNunitType, or does it just not work, or have I
  36.     missed some little bit of how it is supposed to work.
  37.     
  38.     Oh yeah, I am using Motif version 1.1.4 supplied by OSF,
  39.     on sparc SunOs 4.1.3
  40.  
  41.     Thanks in advance for any tips,
  42.     rogerr@netcom.com
  43.  
  44.