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