|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectsdljava.ttf.SDLTTF
public class SDLTTF
SDL_ttf is a TrueType font rendering library that is used with the SDL library, and almost as portable. It depends on freetype2 to handle the TrueType font data. It allows a programmer to use multiple TrueType fonts without having to code a font rendering routine themselves. With the power of outline fonts and antialiasing, high quality text output can be obtained without much effort.
| Constructor Summary | |
|---|---|
SDLTTF()
|
|
| Method Summary | |
|---|---|
static SDLVersion |
getTTFVersion()
get a version structure with the compile-time version of the SDL_ttf library. |
static void |
init()
Initialize the truetype font API. |
static SDLTrueTypeFont |
openFont(java.lang.String path,
int ptsize)
Load file for use as a font, at ptsize size. |
static SDLTrueTypeFont |
openFontIndex(java.lang.String path,
int ptsize,
int index)
Load file for use as a font, at ptsize size. |
static void |
quit()
Shutdown and cleanup the truetype font API. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SDLTTF()
| Method Detail |
|---|
public static void init()
throws SDLException
SDLException - if an error occurs
public static void quit()
throws SDLException
SDLException - if an error occurs
public static SDLTrueTypeFont openFont(java.lang.String path,
int ptsize)
throws SDLException
path - Path to font fileptsize - Point size (based on 72DPI) to load font as. This basically translates to pixel height.
TTFFont value
SDLException - if an error occurs
public static SDLTrueTypeFont openFontIndex(java.lang.String path,
int ptsize,
int index)
throws SDLException
path - Path to font fileptsize - Point size (based on 72DPI) to load font as. This basically translates to pixel height.index - The index to load at
TTFFont value
SDLException - if an error occurspublic static SDLVersion getTTFVersion()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||