public class HersheyFont extends Object
Modifier and Type | Field and Description |
---|---|
protected int[] |
characterMaxX |
protected int[] |
characterMinX |
protected int |
characterSetMaxX |
protected int |
characterSetMaxY |
protected int |
characterSetMinX |
protected int |
characterSetMinY |
protected int |
charactersInSet |
protected char[][][] |
characterVectors |
protected boolean |
fixedWidth |
protected String |
name |
protected int[] |
numberOfPoints |
protected static int |
X |
protected static int |
Y |
Constructor and Description |
---|
HersheyFont()
Default constructor.
|
HersheyFont(String fontName)
Get a Hershey Font by name.
|
HersheyFont(URL base)
Get a Hershey Font by URL.
|
HersheyFont(URL base,
String fontName)
Get a Hershey Font by URL and name.
|
Modifier and Type | Method and Description |
---|---|
protected void |
calculateCharacterSize(int j,
int xadj) |
boolean |
equals(Object o)
See if o is equal to this
|
int[] |
getCharacterMaxX()
get the maximum X coordinate values for all characters
|
int[] |
getCharacterMinX()
get the minimum X coordinate values for all characters
|
int |
getCharacterSetMaxX()
get the maximum X coordiante value for all characters
|
int |
getCharacterSetMaxY()
get the maximum Y coordiante value for all characters
|
int |
getCharacterSetMinX()
get the minimum X coordiante value for all characters
|
int |
getCharacterSetMinY()
get the minimum Y coordiante value for all characters
|
int |
getCharactersInSet()
get the minimum Y coordiante value for all characters
|
char[][] |
getCharacterVector(int i)
get the vector of X and Y coordinates for the i-th character
|
boolean |
getFixedWidth()
indicate whether this is a fixed-width font
|
boolean |
getIsCursive()
indicate whether this is a cursive font
|
int |
getMaxPoints()
get the maximum number of points (segments) allowed
|
int |
getNumberOfPoints(int i)
get the number of points for the i-th character
|
int |
hasCode()
Get the hashcode
|
void |
setFixedWidth(boolean fw)
set whether this font is 'fixed width' or not (not =
proportional spacing)
Right now, only the 'wmo' font is defaulted to fixed.
|
String |
toString() |
protected static final int X
protected static final int Y
protected String name
protected char[][][] characterVectors
protected int[] numberOfPoints
protected int[] characterMinX
protected int[] characterMaxX
protected int characterSetMinY
protected int characterSetMaxY
protected int characterSetMinX
protected int characterSetMaxX
protected int charactersInSet
protected boolean fixedWidth
public HersheyFont()
public HersheyFont(String fontName)
fontName
- name of the Hershey font to usepublic HersheyFont(URL base, String fontName)
base
- is the base URL of the filefontName
- the name of the fontfile (include .jhf extension)public HersheyFont(URL base)
base
- is the URL of the file (e.g.,
http://www.ssec.wisc.edu/visad/futural.jhf)public boolean equals(Object o)
public int hasCode()
public int getMaxPoints()
public int[] getCharacterMinX()
public int[] getCharacterMaxX()
public int getCharacterSetMinY()
public int getCharacterSetMaxY()
public int getCharacterSetMinX()
public int getCharacterSetMaxX()
public int getCharactersInSet()
public int getNumberOfPoints(int i)
i
- the index of the characterpublic char[][] getCharacterVector(int i)
i
- the index of the characterpublic void setFixedWidth(boolean fw)
public boolean getFixedWidth()
public boolean getIsCursive()
protected void calculateCharacterSize(int j, int xadj)
Copyright © 1996–2023 The SSEC Visualization Project. All rights reserved.