🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.windows.ms.programmer
Article #1511

Aligning list box items with a header.

#1511
From: Lynn Wallace
Date: Tue, 05 Mar 1991 18:43
31 lines
1961 bytes
My application has a dialog that looks like:


       Name                    Char    Flag   Flag   Flag   Icon   Icon   Icon
--------------------------------------------------------------------------------
|                                                                              |
|                                                                              |                               etc...        
|                                                                              |
|                                                                              |
--------------------------------------------------------------------------------

		[button]	[button]	[button]


What we have is a static text control, three icon controls, followed by a
generic list box with scrolling, followed by some buttons.

Items under Name will be up to 30 chars, Char is one character, Flag's are a 
a check mark or a blank, and I want to display integers under the Icon's.

Assuming the system font will change, and my current font is proportional
anyway, what is the way to have the text in this list box stay neat? 
(Currently I've brute-forced my way through setting tabs and printing spaces and
leading zeros until it aligns.  Neither efficient nor fun.)

Thanks in advance!
-- 
Lynn Wallace			   |I am not an official representative of
Evans and Sutherland Computer Corp.| <- E&S.  Or for that matter, unofficial.
Salt Lake City, UT 84108	   |Internet: lwallace@javelin.sim.es.com
			War not make one great! -- Yoda
Technical Details
Message-ID: <1991Mar5.184356.10941@javelin.es.com>
Path: arc1-ca.pugleaf.net!utzoo!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!olivea!uunet!orca!javelin.es.com!lwallace

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!olivea!uunet!orca!javelin.es.com!lwallace
From: lwallace@javelin.es.com (Lynn Wallace)
Newsgroups: comp.windows.ms.programmer
Subject: Aligning list box items with a header.
Message-ID: <1991Mar5.184356.10941@javelin.es.com>
Date: 5 Mar 91 18:43:56 GMT
Organization: Evans & Sutherland Computer Corp., Salt Lake City, Utah
Lines: 31