Bundle font with application

This is probably an easy one.I have got a font that we purchased online. It's a non-standard font.I use it in my application.How do I package this font with the application so that everyone can see it regardless of their browser?Thanks!Emma
[283 byte] By [EmmaWykes] at [2007-11-26 9:00:01]
# 1

IMHO, it may not be easy. Browsers display HTML using the fonts installed on the user's system. Also, browsers usually allow the users to override the document settings and choose their own font preferences.

- Microsoft provides a web embedding font tool (WEFT): http://www.microsoft.com/typography/web/embedding/. But this is non-standard and will not work on other browsers.

- You can use programs like Flash. Programs like Flash are plugins/addons to the browser and perform their own rendering.

- You can provide the pages which needs to be in a specific font as an image in your application. (Run the page on a machine which has the fonts installed and capture the image). Including the pages as images is in a way taking over the rendering of HTML from the browser...

If HTML needs to be displayed in a custom font, the application can provide links to the font file and provide (platform-specific) instructions on manually installing the font and setting the browser preferences correctly. The browser will also need to be likely closed and restarted for the changes to take effect...

KarthikR at 2007-7-6 23:04:08 > top of Java-index,Development Tools,Java Tools...
# 2
Thanks very much KarthikR, Is there no way that you can save your font within the war and tell the application where to look for it?So if I'm designing for the web I can only really use the web fonts in creator, of which there are 8?Emma
EmmaWykes at 2007-7-6 23:04:08 > top of Java-index,Development Tools,Java Tools...
# 3
Can you use Font.createFont(int fontFormat, InputStream fontStream) with a web app?
EmmaWykes at 2007-7-6 23:04:08 > top of Java-index,Development Tools,Java Tools...
# 4

Hi,

I got this info : http://java.sun.com/j2se/1.3/docs/guide/intl/addingfonts.html

I was assuming if my application used beer.ttf as a font and that this was not a standard windows IE available font then I could put it into my webapplications jre/lib/fonts as suggested and this would work, however it does not. I retstart Tomcat after uploading the file but the font isnt found by the webapp. I think Iam also missing somthing here.

Could someone explain where the webapp looks for fonts ?

Regards

Jim

jimmykelso at 2007-7-6 23:04:08 > top of Java-index,Development Tools,Java Tools...
# 5

createFont() can be used from a standalone java application. It can also be used in a web application but then the code would execute on the server. Eventually a web app merely serves the HTML files to the client and it is the browser that renders the page.

On the client, browser, one possible way would be to use applets. (Or plugins or addons to browsers which perform their own rendering).

HTML documents can request a specific font but the browser will try to satisy the request with the closest matching font available on the user's system.

Ref:

http://www.netmechanic.com/news/vol3/css_no15.htm

http://www.webmonkey.com/webmonkey/99/45/index0a.html

KarthikR at 2007-7-6 23:04:08 > top of Java-index,Development Tools,Java Tools...