| advance |
A read-only
double
that represents the maximum distance the current point moves for any
character in this font, in units of 72 dots per inch.
advance
is not used much and is really only interesting when all character in
the font are designed to have the same width.
|
| ascent |
A read-only
double
that represents the maximum distance from the baseline to the top of
most alphanumeric characters, in units of 72 dots per inch.
ascent
is usually positive, but the value is adjusted when transformations, like
translatefont,
are applied, so any value is possible.
Subtracting
ascent
from the y-coordinate of the baseline results in a y-coordinate that lies
above the top of most alphanumeric characters.
|
| descent |
A read-only
double
that represents the maximum distance from the baseline to the bottom of
most alphanumeric characters, in units of 72 dots per inch.
descent
is usually positive, but the value is adjusted when transformations, like
translatefont,
are applied, so any value is possible.
Adding
descent
to the y-coordinate of the baseline results in a y-coordinate that lies
below the bottom of most alphanumeric characters.
|
| family |
A read-only
String
that represents the font family that is encoded in the font's
name.
|
| fontfacename |
A read-only
String
that is the name of the font face.
|
| height |
A read-only
double
that represents the recommended distance between baselines for this font,
in units of 72 dots per inch.
height
is a positive number that is usually close to the value obtained by adding
ascent,
descent,
and
leading.
|
| leading |
A read-only
double
that represents the recommended interline spacing for this font,
in units of 72 dots per inch.
|
| matrix |
A read-only
Matrix
that describes the transformation from the font's internal coordinate
system to user space.
|
| name |
A
String
that identifies the font.
The actual interpretation of
name
depends of the value assigned to
type,
but since
0
is currently the only supported type,
name
should be given in standard Java notation that allows dash separated style
and size strings to be appended to one of the available font names.
The font names that Java supports on your platform can be obtained using the
getFontList
built-in.
name
can only be defined in the font's declaration;
changing it at any other time will result in an
invalidaccess
error.
|
| pointsize |
A read-only
double
that represents that actual point size of this font.
The value is adjusted when transformations, like
scalefont,
are applied to this font and it also depends on whether your program has
asked for special adjustments by setting
VM.fontmagnification
or
VM.fixfonts,
so
pointsize
will not always match the size encoded in
name,
which is available as
size.
|
| psname |
A read-only
String
that is the PostScript name of this font.
|
| rotatefont |
A
Builtin
that creates a new font by rotating the characters in this font.
|
| scalefont |
A
Builtin
that creates a new font by scaling the characters in this font.
|
| shearfont |
A
Builtin
that creates a new font by shearing the characters in this font.
|
| size |
A read-only
int
that represents the size that is encoded in the font's
name,
which may not match
pointsize.
|
| stringbounds |
A
Builtin
that returns a
Rectangle
that covers a string if it were
drawn at the origin.
|
| stringfit |
A
Builtin
that can be used to fit a string, printed in this font, to a width.
|
| stringsize |
A
Builtin
that returns a
Dimension
that can cover a string.
|
| stringwidth |
A
Builtin
that calculates how far the current point would move horizontally
after a string is drawn.
|
| style |
A read-only
String
that represents the style of the font as one of
plain,
bold,
or
bolditalic.
|
| transformfont |
A
Builtin
that creates a new font by applying an affine transformation to the
characters in this font.
|
| translatefont |
A
Builtin
that creates a new font by translating the characters in this font.
|
| type |
An
int
that identifies what kind of font this is to the internal font machinery
supported by the Yoix interpreter.
Setting
type
to
0,
which is currently the only supported value, means this font represents
one of the fonts supported by Java.
type
can only be defined in the font's declaration;
changing it at any other time will result in an
invalidaccess
error.
|
Several permanent fields have not been documented and should not be
used in Yoix applications.