org.minueto.image
Class MinuetoFont

java.lang.Object
  extended by org.minueto.image.MinuetoFont

public class MinuetoFont
extends java.lang.Object

The MinuetoFont class is used to store information describing a Font. All "writing" fonctionnality in Minueto requires a MinuetoFont at some point.

Loading a font in Minueto is a best effort task. If the specified font is not available, Minueto will load a default font instead.

The following fonts are available in the JVM, thus making them platform independant.

Since:
Minueto 0.3

Field Summary
static java.lang.String Dialog
          One of the standard Java font, similar to Arial.
static java.lang.String DialogInput
          One of the standard Java font, similar to Courrier New.
static java.lang.String Monospaced
          One of the standard Java font, similar to Courrier New.
static java.lang.String SansSerif
          One of the standard Java font, similar to Arial.
static java.lang.String Serif
          One of the standard Java font, similar to Times New Roman.
 
Constructor Summary
MinuetoFont(java.lang.String fontName, int fontSize, boolean bold, boolean italic)
          Creates a font object by loading the specified font with the specified caracteristics.
 
Method Summary
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

Dialog

public static final java.lang.String Dialog
One of the standard Java font, similar to Arial.

See Also:
Constant Field Values

DialogInput

public static final java.lang.String DialogInput
One of the standard Java font, similar to Courrier New.

See Also:
Constant Field Values

Monospaced

public static final java.lang.String Monospaced
One of the standard Java font, similar to Courrier New.

See Also:
Constant Field Values

Serif

public static final java.lang.String Serif
One of the standard Java font, similar to Times New Roman.

See Also:
Constant Field Values

SansSerif

public static final java.lang.String SansSerif
One of the standard Java font, similar to Arial.

See Also:
Constant Field Values
Constructor Detail

MinuetoFont

public MinuetoFont(java.lang.String fontName,
                   int fontSize,
                   boolean bold,
                   boolean italic)
Creates a font object by loading the specified font with the specified caracteristics. Loading a font in Minueto is a best effort task. If the specified font is not available, Minueto will load a default font instead.

Parameters:
fontName - String denoting the name of the font to be loeaded.
fontSize - int indicating the size of the font.
bold - boolean indicating if the font should be bold.
italic - boolean indicating if the font should be italic.
Throws:
MinuetoZeroNegativeException - if the font is invalid.