With things like this I think you have to set the graphics port somehow. If
you make a method to do this that requires a graphics parameter then if you
do something like g.drawstring " ",0,0 then the call should use the right
font settings.
Only a guess!
Ian.
> Subject: Truncating Text at various sizes
> From: "Scott Crick (Lists)" <lists at swssoftware dot com>
> Date: Mon, 18 Feb 2002 16:40:38 -0600
>
> Hi All!
>
> Someone once provided me with the following bit of code for truncating text
> to fit within a given amount of space:
>
>
> The problem with this is, it appears to assume that the text is formatted as
> Geneva, 10 pt. I need this to be able to work at any given font and size.
> Anyone have any ideas?
>
> Thanks!
>
> Scott
> --
> SearchWare Solutions
> Simply Great Software
> http://www.swssoftware.com
|