1 /*
2 * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. Oracle designates this
8 * particular file as subject to the "Classpath" exception as provided
9 * by Oracle in the LICENSE file that accompanied this code.
10 *
11 * This code is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 * version 2 for more details (a copy is included in the LICENSE file that
15 * accompanied this code).
16 *
17 * You should have received a copy of the GNU General Public License version
18 * 2 along with this work; if not, write to the Free Software Foundation,
19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20 *
21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22 * or visit www.oracle.com if you need additional information or have any
78 * will be ignored.
79 * <li>The identity of the value does not matter, only the actual
80 * value. For example, <code>TextAttribute.WEIGHT_BOLD</code> and
81 * <code>new Float(2.0)</code>
82 * indicate the same <code>WEIGHT</code>.
83 * <li>Attribute values of type <code>Number</code> (used for
84 * <code>WEIGHT</code>, <code>WIDTH</code>, <code>POSTURE</code>,
85 * <code>SIZE</code>, <code>JUSTIFICATION</code>, and
86 * <code>TRACKING</code>) can vary along their natural range and are
87 * not restricted to the predefined constants.
88 * <code>Number.floatValue()</code> is used to get the actual value
89 * from the <code>Number</code>.
90 * <li>The values for <code>WEIGHT</code>, <code>WIDTH</code>, and
91 * <code>POSTURE</code> are interpolated by the system, which
92 * can select the 'nearest available' font or use other techniques to
93 * approximate the user's request.
94 *
95 * </UL>
96 *
97 * <h4>Summary of attributes</h4>
98 * <table style="float:center" border="0" cellspacing="0" cellpadding="2" width="%95"
99 * summary="Key, value type, principal constants, and default value
100 * behavior of all TextAttributes">
101 * <tr style="background-color:#ccccff">
102 * <th valign="TOP" align="CENTER">Key</th>
103 * <th valign="TOP" align="CENTER">Value Type</th>
104 * <th valign="TOP" align="CENTER">Principal Constants</th>
105 * <th valign="TOP" align="CENTER">Default Value</th>
106 * </tr>
107 * <tr>
108 * <td valign="TOP">{@link #FAMILY}</td>
109 * <td valign="TOP">String</td>
110 * <td valign="TOP">See Font {@link java.awt.Font#DIALOG DIALOG},
111 * {@link java.awt.Font#DIALOG_INPUT DIALOG_INPUT},<br> {@link java.awt.Font#SERIF SERIF},
112 * {@link java.awt.Font#SANS_SERIF SANS_SERIF}, and {@link java.awt.Font#MONOSPACED MONOSPACED}.
113 * </td>
114 * <td valign="TOP">"Default" (use platform default)</td>
115 * </tr>
116 * <tr style="background-color:#eeeeff">
117 * <td valign="TOP">{@link #WEIGHT}</td>
118 * <td valign="TOP">Number</td>
|
1 /*
2 * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. Oracle designates this
8 * particular file as subject to the "Classpath" exception as provided
9 * by Oracle in the LICENSE file that accompanied this code.
10 *
11 * This code is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 * version 2 for more details (a copy is included in the LICENSE file that
15 * accompanied this code).
16 *
17 * You should have received a copy of the GNU General Public License version
18 * 2 along with this work; if not, write to the Free Software Foundation,
19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20 *
21 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22 * or visit www.oracle.com if you need additional information or have any
78 * will be ignored.
79 * <li>The identity of the value does not matter, only the actual
80 * value. For example, <code>TextAttribute.WEIGHT_BOLD</code> and
81 * <code>new Float(2.0)</code>
82 * indicate the same <code>WEIGHT</code>.
83 * <li>Attribute values of type <code>Number</code> (used for
84 * <code>WEIGHT</code>, <code>WIDTH</code>, <code>POSTURE</code>,
85 * <code>SIZE</code>, <code>JUSTIFICATION</code>, and
86 * <code>TRACKING</code>) can vary along their natural range and are
87 * not restricted to the predefined constants.
88 * <code>Number.floatValue()</code> is used to get the actual value
89 * from the <code>Number</code>.
90 * <li>The values for <code>WEIGHT</code>, <code>WIDTH</code>, and
91 * <code>POSTURE</code> are interpolated by the system, which
92 * can select the 'nearest available' font or use other techniques to
93 * approximate the user's request.
94 *
95 * </UL>
96 *
97 * <h4>Summary of attributes</h4>
98 * <table style="float:center" border="0" cellspacing="0" cellpadding="2" width="95%"
99 * summary="Key, value type, principal constants, and default value
100 * behavior of all TextAttributes">
101 * <tr style="background-color:#ccccff">
102 * <th valign="TOP" align="CENTER">Key</th>
103 * <th valign="TOP" align="CENTER">Value Type</th>
104 * <th valign="TOP" align="CENTER">Principal Constants</th>
105 * <th valign="TOP" align="CENTER">Default Value</th>
106 * </tr>
107 * <tr>
108 * <td valign="TOP">{@link #FAMILY}</td>
109 * <td valign="TOP">String</td>
110 * <td valign="TOP">See Font {@link java.awt.Font#DIALOG DIALOG},
111 * {@link java.awt.Font#DIALOG_INPUT DIALOG_INPUT},<br> {@link java.awt.Font#SERIF SERIF},
112 * {@link java.awt.Font#SANS_SERIF SANS_SERIF}, and {@link java.awt.Font#MONOSPACED MONOSPACED}.
113 * </td>
114 * <td valign="TOP">"Default" (use platform default)</td>
115 * </tr>
116 * <tr style="background-color:#eeeeff">
117 * <td valign="TOP">{@link #WEIGHT}</td>
118 * <td valign="TOP">Number</td>
|