API Overview API Index Package Overview Direct link to this page
JDK 1.6
  java.awt.font. MultipleMaster View Javadoc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89

/*
 * @(#)MultipleMaster.java	1.19 05/11/17
 *
 * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
 * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
 */
package java.awt.font;

import java.awt.Font;

/**
 * The <code>MultipleMaster</code> interface represents Type 1
 * Multiple Master fonts.
 * A particular {@link Font} object can 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.
   * @return the number of multiple master design controls
   */
  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 are
   * returned in the same order returned by
   * <code>getDesignAxisNames</code>.
   * @return an array of design limits for each axis.
   */
  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 are returned
   * in the same order returned by <code>getDesignAxisNames</code>.
   * @return an array of default design values for each axis.
   */
  public  float[]  getDesignAxisDefaults();

  /**
   * Returns the name for each design axis. This also determines the order in
   * which the values for each axis are returned.
   * @return an array containing the names of each design axis.
   */
  public  String[] getDesignAxisNames();

  /**
   * Creates a new instance of a multiple master font based on the design
   * axis values contained in the specified array. The size of the array
   * must correspond to the value returned from 
   * <code>getNumDesignAxes</code> and the values of the array elements
   * must fall within limits specified by 
   * <code>getDesignAxesLimits</code>. In case of an error,
   * <code>null</code> is returned.
   * @param axes an array containing axis values
   * @return a {@link Font} object that is an instance of
   * <code>MultipleMaster</code> and is based on the design axis values
   * provided by <code>axes</code>.
   */
  public Font deriveMMFont(float[] axes);

  /**
   * Creates a new instance of a multiple master font based on detailed metric
   * information. In case of an error, <code>null</code> 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
   * @return a <code>Font</code> object that is an instance of 
   * <code>MultipleMaster</code> and is based on the specified metric
   * information.
   */
  public Font deriveMMFont(
				   float[] glyphWidths,
				   float avgStemWidth,
				   float typicalCapHeight,
				   float typicalXHeight,
				   float italicAngle);
 

}

Generated By: JavaOnTracks Doclet 0.1.4     ©Thibaut Colar