I know you can do that in java but all you get is the name, family and
metrics. There's no font data in sight. If you really want to go that way,
you can enumerate all the fonts in your windows/fonts folder and match the
names. There are methods in BaseFont the get the names of the fonts, long
names and postscript names.

Best Regards,
Paulo Soares

> -----Original Message-----
> From: Serge S. Vasiljev [SMTP:[EMAIL PROTECTED]]
> Sent: Wednesday, February 20, 2002 11:29
> To:   Paulo Soares
> Cc:   iText
> Subject:      Re: [iText-questions] TrueType Fonts
> 
>  Well,  in Java2  we can run this 3 lines
>  
> String[] fontNames = Toolkit.getDefaultToolkit().getFontList();
>  -> result is predefined fonts in Java  ( 4 or 5 -  I'm not sure )
>  
>  
> String[] fontNames1 =
> GraphicsEnvironment.getLocalGraphicsEnvironment().getAvailableFontFamilyNa
> mes();
> ->  result is more  40 FontNames ( on my computer - on your it could be
> another number )
> It's the same as I can see it in MS Word, for example
>  
> java.awt.Font[] fonts =
> GraphicsEnvironment.getLocalGraphicsEnvironment().getAllFonts();
> -> result is more 90 Font objects ( all variations from fontNames1 )
>  
>  
> It means that we can get access to installed system fonts without using
> native interface ( aka JNI ) :-)
>  
> So - how I can I use one of thous Fonts ( from fontNames or font arrays )
> in iText
>  
> thanks
>  
> sv
>  
> 
> 
>  
> 
>       I'm not sure I understand your question. In C, in Windows, I can
> call
>       GetFontData() in gdi32.dll to retrieve the font data. In java
> there's no
>       such possibility without using JNI.
> 

_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to