SCOUG Logo


Next Meeting: Sat, TBD
Meeting Directions


Be a Member
Join SCOUG

Navigation:


Help with Searching

20 Most Recent Documents
Search Archives
Index by date, title, author, category.


Features:

Mr. Know-It-All
Ink
Download!










SCOUG:

Home

Email Lists

SIGs (Internet, General Interest, Programming, Network, more..)

Online Chats

Business

Past Presentations

Credits

Submissions

Contact SCOUG

Copyright SCOUG



warp expowest
Pictures from Sept. 1999

The views expressed in articles on this site are those of their authors.

warptech
SCOUG was there!


Copyright 1998-2024, Southern California OS/2 User Group. ALL RIGHTS RESERVED.

SCOUG, Warp Expo West, and Warpfest are trademarks of the Southern California OS/2 User Group. OS/2, Workplace Shell, and IBM are registered trademarks of International Business Machines Corporation. All other trademarks remain the property of their respective owners.

The Southern California OS/2 User Group
USA

June 2003


 Dear Mr. Know-It-All 

Mr. Know-It-All has the answers to even the really tough questions.


Question:

Several people have told me I should install MS Web fonts and that this will improve text rendering for Java 1.3 applications. How do I do this?

Answer:

The MS Web Fonts are standard TrueType fonts. They are installed like any other OS/2 fonts and once installed you can use them with native OS/2 PM applications just like any other font. They will also be available with Java applications that let you select fonts.

To get Java to use these fonts when there is no application specific selection method, such as with the Java plug-in for Mozilla, you need to do a bit more work. You need to modify the Java font properties file. This file defines the default font selections and other font characteristics. This is what really improves the text display for Java apps. The preset defaults are just not that good.

Here's how to do it.

  • Download the MS Web Fonts from Hobbes to a work directory.

  • Unzip the file to a convenient installation directory. Mr KIA used:
      \webfonts
    
    on the boot drive.

  • Install the fonts using your favorite font installer. You can use the Font Pallete. Mr. KIA prefers FontFolder. Font Foldler supports Font Libraries which makes it easy to keep track of groups of related fonts. Font Folder and Font Libraries make is simple to install and uninstall multiple fonts in a single operation.

  • Locate the file
      \java131\jre\lib\fonts\f.prp
    
    This is the Java font properties control file. It's a text file and it contains the physical to logical font associations. Make a backup of this file, just in case your editing is not perfect.

  • Edit the file with an editor that does not wrap lines or insert Ctrl-Z's at the end of a file. EPM is a good choice.

    Change the lines as shown by the 'diff' listing that follows.

    • The lines prefixed with '<' are the lines before editing.
    • The lines prefixed with '>' are the lines after editing.
    • Lines like 34c34 indicate the line number of the file before and after editing. Since we are not adding or deleting lines, the line numbers will not change.
      34c34
      < sansserif.0=Helvetica,UGL_CHARSET
      ---
      > sansserif.0=Arial,UGL_CHARSET
      38c38
      < sansserif.italic.0=Helvetica Italic,UGL_CHARSET
      ---
      > sansserif.italic.0=Arial Italic,UGL_CHARSET
      42c42
      < sansserif.bold.0=Helvetica Bold,UGL_CHARSET
      ---
      > sansserif.bold.0=Arial Bold,UGL_CHARSET
      47c47
      < sansserif.bolditalic.0=Helvetica Bold Italic,UGL_CHARSET
      ---
      > sansserif.bolditalic.0=Arial Bold Italic,UGL_CHARSET
      52c52
      < monospaced.0=Courier,UGL_CHARSET
      ---
      > monospaced.0=Courier New,UGL_CHARSET
      56c56
      < monospaced.italic.0=Courier Italic,UGL_CHARSET
      ---
      > monospaced.italic.0=Courier New Italic,UGL_CHARSET
      60c60
      < monospaced.bold.0=Courier Bold,UGL_CHARSET
      ---
      > monospaced.bold.0=Courier New Bold,UGL_CHARSET
      64c64
      < monospaced.bolditalic.0=Courier Bold Italic,UGL_CHARSET
      ---
      > monospaced.bolditalic.0=Courier New Bold Italic,UGL_CHARSET
    
    What these changes do is change the default Sans Serif and Monospace fonts from Helvetica and Courier to Arial and Courier New, respectively. This has two benefits. The new fonts are better quality and they are TrueType rather than PostScript. Java seems to be a better job of rendering TrueType fonts.

After you have made the changes, save the file, restart the JVM and test the effect they have on your favorite Java apps. These changes noticably improve text display for Polarbar and Netbeans, two Java apps Mr. KIA uses regularly.

You might notice that f.prp also contains a list of associations between font and and font file names. There's no need to edit these on the OS/2 platform. These defintions are used to speed up font loading on other platforms.

Although his name might imply otherwise, Mr. KIA does not consider himself a font expert, so let him know if you have suggestions for better font choices than those described here.


Curious or in doubt, you can ask Mr. Know-It-All
OS/2 is his specialty and sharing solutions is his passion
Mr. Know-It-All lives in Southern California.


The Southern California OS/2 User Group
P.O. Box 26904
Santa Ana, CA 92799-6904, USA

Copyright 2003 the Southern California OS/2 User Group. ALL RIGHTS RESERVED.

SCOUG, Warp Expo West, and Warpfest are trademarks of the Southern California OS/2 User Group. OS/2, Workplace Shell, and IBM are registered trademarks of International Business Machines Corporation. All other trademarks remain the property of their respective owners.