com.alee.laf
Class WebFonts

java.lang.Object
  extended by com.alee.laf.WebFonts

public class WebFonts
extends java.lang.Object

This class returns base fonts for all component types on various OS. This is some kind of workaround since there is no good way to retrieve native component fonts from OS itself. Usually it is native L&F who setup system fonts but inside it simply has hardcoded fonts, which is not really different from my way.

Author:
Mikle Garin

Field Summary
static java.lang.String LUCIDA_GRANDE
          Mac OS X fonts.
static java.lang.String SANS_SERIF
          Unix fonts.
static java.lang.String SEGOE_UI
           
static java.lang.String TAHOMA
          Windows fonts.
 
Constructor Summary
WebFonts()
           
 
Method Summary
static javax.swing.plaf.FontUIResource getSystemAcceleratorFont()
          Returns system accelerator font.
static javax.swing.plaf.FontUIResource getSystemAlertFont()
          Returns system alert dialog font.
static javax.swing.plaf.FontUIResource getSystemControlFont()
          Returns system controls font.
static javax.swing.plaf.FontUIResource getSystemMenuFont()
          Returns system menu font.
static javax.swing.plaf.FontUIResource getSystemTextFont()
          Returns system text font.
static javax.swing.plaf.FontUIResource getSystemTitleFont()
          Returns system title font.
static javax.swing.plaf.FontUIResource getSystemTooltipFont()
          Returns system tooltip font.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TAHOMA

public static final java.lang.String TAHOMA
Windows fonts.

See Also:
Constant Field Values

SEGOE_UI

public static final java.lang.String SEGOE_UI
See Also:
Constant Field Values

LUCIDA_GRANDE

public static final java.lang.String LUCIDA_GRANDE
Mac OS X fonts.

See Also:
Constant Field Values

SANS_SERIF

public static final java.lang.String SANS_SERIF
Unix fonts.

See Also:
Constant Field Values
Constructor Detail

WebFonts

public WebFonts()
Method Detail

getSystemControlFont

public static javax.swing.plaf.FontUIResource getSystemControlFont()
Returns system controls font.

Returns:
system controls font

getSystemAlertFont

public static javax.swing.plaf.FontUIResource getSystemAlertFont()
Returns system alert dialog font.

Returns:
system alert dialog font

getSystemMenuFont

public static javax.swing.plaf.FontUIResource getSystemMenuFont()
Returns system menu font.

Returns:
system menu font

getSystemAcceleratorFont

public static javax.swing.plaf.FontUIResource getSystemAcceleratorFont()
Returns system accelerator font.

Returns:
system accelerator font

getSystemTitleFont

public static javax.swing.plaf.FontUIResource getSystemTitleFont()
Returns system title font.

Returns:
system title font

getSystemTextFont

public static javax.swing.plaf.FontUIResource getSystemTextFont()
Returns system text font.

Returns:
system text font

getSystemTooltipFont

public static javax.swing.plaf.FontUIResource getSystemTooltipFont()
Returns system tooltip font.

Returns:
system tooltip font