org.geotools.renderer.style
Class FontCache

Object
  extended by FontCache

public class FontCache
extends Object

Lookup and caches font definitions for faster retrieval

Author:
Andrea Aime - TOPP

Constructor Summary
FontCache()
           
 
Method Summary
 Set<String> getAvailableFonts()
          Returns the set of font families and font faces available in the system and those manually loaded into the cache
static FontCache getDefaultInsance()
          Deprecated. Use getDefaultInstance() instead
static FontCache getDefaultInstance()
          Returns the default, system wide font cache
 Font getFont(String requestedFont)
           
 void registerFont(Font f)
          Adds the specified font in the font cache.
 void resetCache()
          Resets the font loading cache.
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FontCache

public FontCache()
Method Detail

getDefaultInsance

public static FontCache getDefaultInsance()
Deprecated. Use getDefaultInstance() instead

Returns the default, system wide font cache


getDefaultInstance

public static FontCache getDefaultInstance()
Returns the default, system wide font cache

Since:
2.6

getFont

public Font getFont(String requestedFont)

registerFont

public void registerFont(Font f)
Adds the specified font in the font cache. Useful if you want to load fonts that are not installed in the Operating System and cannot provide a full path to fonts either.

Parameters:
f -

resetCache

public void resetCache()
Resets the font loading cache. If any font was manually registered, it will have to be registered again


getAvailableFonts

public Set<String> getAvailableFonts()
Returns the set of font families and font faces available in the system and those manually loaded into the cache

Returns:


Copyright © 1996-2014 Geotools. All Rights Reserved.