Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!oliveb!sun!pepper!cmcmanis From: cmcmanis%pepper@Sun.COM (Chuck McManis) Newsgroups: comp.sys.amiga.tech Subject: Re: width of font characters Message-ID: <96526@sun.Eng.Sun.COM> Date: 29 Mar 89 22:01:22 GMT References: <1569@wpi.wpi.edu> Sender: news@sun.Eng.Sun.COM Reply-To: cmcmanis@sun.UUCP (Chuck McManis) Organization: Sun Microsystems, Mountain View Lines: 14 In article <1569@wpi.wpi.edu> pawn@wpi.wpi.edu (Kevin Goroway) writes: >Is there any way to get the actual width of a single character of a particular >font given that the font is loaded correctly. wid = TextLength(rp, "", 1); TextLength returns the width in pixels of any arbitrary string in the RastPort's current font. Use a one character string and a length of one. --Chuck McManis uucp: {anywhere}!sun!cmcmanis BIX: cmcmanis ARPAnet: cmcmanis@sun.com These opinions are my own and no one elses, but you knew that didn't you. "A most excellent barbarian ... Genghis Kahn!"