com.realtime.crossfire.jxclient.skin.io
Class FontParser

java.lang.Object
  extended by com.realtime.crossfire.jxclient.skin.io.FontParser

public class FontParser
extends java.lang.Object

Creates Font instances from string representations.


Field Summary
private  JXCSkinSource skinSource
          The JXCSkinSource for loading resources.
 
Constructor Summary
FontParser(JXCSkinSource skinSource)
          Creates a new instance.
 
Method Summary
 java.awt.Font getFont(java.lang.String name)
          Returns a font by font file base name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

skinSource

@NotNull
private final JXCSkinSource skinSource
The JXCSkinSource for loading resources.

Constructor Detail

FontParser

public FontParser(@NotNull
                  JXCSkinSource skinSource)
Creates a new instance.

Parameters:
skinSource - the skin source for loading resources
Method Detail

getFont

@NotNull
public java.awt.Font getFont(@NotNull
                                     java.lang.String name)
                      throws java.io.IOException
Returns a font by font file base name.

Parameters:
name - the file base name of the font file to load
Returns:
the font
Throws:
java.io.IOException - if the font cannot be loaded