Article View: comp.windows.ms.programmer
Article #1739Aligning Proportionally Spaced Text in a Dialog Box
From: John R. Burgoyne
Date: Wed, 20 Mar 1991 03:06
Date: Wed, 20 Mar 1991 03:06
27 lines
1414 bytes
1414 bytes
Two Questions:
1) Is there a simple, reliable technique to have multiple lines
of text in a dialog box which uses a proportionally spaced
font align on a character which appears in every line?
Consider the following example where the text is aligned on
the colon.
blah blah : more blah
foobar : 87.4
We've only been able to use trial and error with sprintf and
TextOut to align the text with mixed success. Usually the text
comes out slightly skewed and the colons never seem to quite
line up.
2) Is there a simple, reliable technique to make multiple lines
of text align right in a dialog box which uses a
proportionally spaced font? Again we've only done trial and
error with sprintf and TextOut and things don't quite line up.
Thanks for any assistance.
Robert
Technical Details
Message-ID:
<1991Mar20.030630.16278@eng.umd.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!know!news.cs.indiana.edu!ux1.cso.uiuc.edu!midway!mimsy!mojo!burgoyneShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!know!news.cs.indiana.edu!ux1.cso.uiuc.edu!midway!mimsy!mojo!burgoyne From: burgoyne@eng.umd.edu (John R. Burgoyne) Newsgroups: comp.windows.ms.programmer Subject: Aligning Proportionally Spaced Text in a Dialog Box Message-ID: <1991Mar20.030630.16278@eng.umd.edu> Date: 20 Mar 91 03:06:30 GMT Sender: news@eng.umd.edu (C-News) Organization: College of Engineering, Maryversity of Uniland, College Park Lines: 27