home *** CD-ROM | disk | FTP | other *** search
Java Source | 1998-03-20 | 2.8 KB | 82 lines |
- /*
- * @(#)MultipleMaster.java 1.11 98/03/18
- *
- * Copyright 1997, 1998 by Sun Microsystems, Inc.,
- * 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
- * All rights reserved.
- *
- * This software is the confidential and proprietary information
- * of Sun Microsystems, Inc. ("Confidential Information"). You
- * shall not disclose such Confidential Information and shall use
- * it only in accordance with the terms of the license agreement
- * you entered into with Sun.
- */
- package java.awt.font;
-
- import java.awt.Font;
-
- /**
- * This is an interface representing Type 1 Multiple Master fonts.
- * A particular Font object may implement this interface.
- * @version 10 Feb 1997
- */
- public interface MultipleMaster {
-
- /**
- * Returns the number of multiple master design controls.
- * Design axes include things like width, weight and optical scaling.
- */
- public int getNumDesignAxes();
-
- /**
- * Returns an array of design limits interleaved in the form [from->to]
- * for each axis. For example,
- * design limits for weight could be from 0.1 to 1.0. The values will be
- * returned in the same order returned by getDesignAxisNames().
- */
- public float[] getDesignAxisRanges();
-
- /**
- * Returns an array of default design values for each axis. For example,
- * the default value for weight could be 1.6. The values will be returned
- * in the same order returned by getDesignAxisNames().
- */
- public float[] getDesignAxisDefaults();
-
- /**
- * Returns the name for each design axis. This also determines the order in
- * which the values for each axis will be returned.
- */
- public String[] getDesignAxisNames();
-
- /**
- * Creates a new instance of a multiple master font based on the design axes
- * values specified by the array. The size of the array
- * must correspond to the value returned from getNumDesignAxes() and the
- * values of the array elements must fall within limits specified by
- * getDesignAxesLimits(). In case of an error, NULL is returned.
- */
- public Font deriveMMFont(float[] axes);
-
- /**
- * Creates a new instance of a multiple master font based on detailed metric
- * information. In case of an error, NULL is returned.
- * @param glyphWidths An array of floats representing the desired width of
- * each glyph in font space.
- * @param avgStemWidth The average stem width for the overall font in font
- * space.
- * @param typicalCapHeight The height of a typical upper case char.
- * @param typicalXHeight The height of a typical lower case char.
- * @param italicAngle The angle at which the italics lean, in degrees
- * counterclockwise from vertical.
- */
- public Font deriveMMFont(
- float[] glyphWidths,
- float avgStemWidth,
- float typicalCapHeight,
- float typicalXHeight,
- float italicAngle);
-
-
- }
-