xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Scott Moore" <scott.mo...@netdecide.com>
Subject Re: Text size
Date Fri, 05 Oct 2001 15:35:46 GMT

----- Original Message -----
From: "Chris Lilley" <chris@w3.org>
To: "Batik Users" <batik-users@xml.apache.org>
Sent: Friday, October 05, 2001 10:31 AM
Subject: Re: Text size


>
>
> Scott Moore wrote:
>
> > The real problem I have is determining how big to make the legend so the
> > words don't flow off the picture.  Because I allow the users to choose
the
> > font and size, I'm currently using some haphazard calculations based on
font
> > size to guesstimate the maximum size needed.  After tweaking it, it
seems to
> > work pretty well for proportional fonts.  It isn't the ideal solution,
but
> > sounds like that's about the best I can do for now.
>
> If you use an SVG font you can iterate through the string and tell the
> exact width of it by adding all the glyph widths.

Oh yeah?  Is this API in Batik?  How do I use it?


>
> >
> > I have one question about font sizes.  When specifying a pt size (say a
10
> > point font), what exactly does that mean?  How does it correspond to
pixels?
>
> Depeds on the screen resolution.
>
> > Or is it even possible to relate to pixels?
>
> If you want to specify in pixels, you can do exactly that.
>
> >  Because I'm generating JPEG and
> > PNG files from Batik, I tend to base my coordinate system in terms of
> > pixels.
>
> You can directly  ask for a 12px font or whatever, rathder than using pt
>
> --
> Chris
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: batik-users-help@xml.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-users-help@xml.apache.org


Mime
View raw message