This week's book giveaway is in the OCPJP forum. We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line! See this thread for details.
Hi, I would like to use custom font (TTF), which I can do using Font.createFont(), but I would like other applications to be able to use that font which means I would like to install in my OS(my OS- windows 7) fonts directory. I tried to register to GraphicsEnvironment but other applications are not able to use that font.
There's a big question here: if you want the font installed on your system, why do you want that to be done by a Java program?
Joined: Oct 11, 2010
What I am trying to do is that use a custom font(not available in windows), which I am able to do using CreateFont() and I am using that font in my application. Now when I try to print the text using a Virtual PDF printer(PDFCreator), PDFCreator is printing as Shapes hence the text in the PDF is not selectable.
So just to test I tried to use a font(instead of a custom) which is available in windows font directory, and when I print the content now, the pdf text is selectable, i.e. the content is printed as text and not Shapes. I guess, because the font is not available in windows, PDFCreator is not able to use it.
So in order to deal with this problem, I think only way to achieve is to install in windows and then use the font.