98 private final JLabel label; |
98 private final JLabel label; |
99 |
99 |
100 /** |
100 /** |
101 * Use the default vertical orientation for the title text. |
101 * Use the default vertical orientation for the title text. |
102 */ |
102 */ |
103 static public final int DEFAULT_POSITION = 0; |
103 public static final int DEFAULT_POSITION = 0; |
104 /** Position the title above the border's top line. */ |
104 /** Position the title above the border's top line. */ |
105 static public final int ABOVE_TOP = 1; |
105 public static final int ABOVE_TOP = 1; |
106 /** Position the title in the middle of the border's top line. */ |
106 /** Position the title in the middle of the border's top line. */ |
107 static public final int TOP = 2; |
107 public static final int TOP = 2; |
108 /** Position the title below the border's top line. */ |
108 /** Position the title below the border's top line. */ |
109 static public final int BELOW_TOP = 3; |
109 public static final int BELOW_TOP = 3; |
110 /** Position the title above the border's bottom line. */ |
110 /** Position the title above the border's bottom line. */ |
111 static public final int ABOVE_BOTTOM = 4; |
111 public static final int ABOVE_BOTTOM = 4; |
112 /** Position the title in the middle of the border's bottom line. */ |
112 /** Position the title in the middle of the border's bottom line. */ |
113 static public final int BOTTOM = 5; |
113 public static final int BOTTOM = 5; |
114 /** Position the title below the border's bottom line. */ |
114 /** Position the title below the border's bottom line. */ |
115 static public final int BELOW_BOTTOM = 6; |
115 public static final int BELOW_BOTTOM = 6; |
116 |
116 |
117 /** |
117 /** |
118 * Use the default justification for the title text. |
118 * Use the default justification for the title text. |
119 */ |
119 */ |
120 static public final int DEFAULT_JUSTIFICATION = 0; |
120 public static final int DEFAULT_JUSTIFICATION = 0; |
121 /** Position title text at the left side of the border line. */ |
121 /** Position title text at the left side of the border line. */ |
122 static public final int LEFT = 1; |
122 public static final int LEFT = 1; |
123 /** Position title text in the center of the border line. */ |
123 /** Position title text in the center of the border line. */ |
124 static public final int CENTER = 2; |
124 public static final int CENTER = 2; |
125 /** Position title text at the right side of the border line. */ |
125 /** Position title text at the right side of the border line. */ |
126 static public final int RIGHT = 3; |
126 public static final int RIGHT = 3; |
127 /** Position title text at the left side of the border line |
127 /** Position title text at the left side of the border line |
128 * for left to right orientation, at the right side of the |
128 * for left to right orientation, at the right side of the |
129 * border line for right to left orientation. |
129 * border line for right to left orientation. |
130 */ |
130 */ |
131 static public final int LEADING = 4; |
131 public static final int LEADING = 4; |
132 /** Position title text at the right side of the border line |
132 /** Position title text at the right side of the border line |
133 * for left to right orientation, at the left side of the |
133 * for left to right orientation, at the left side of the |
134 * border line for right to left orientation. |
134 * border line for right to left orientation. |
135 */ |
135 */ |
136 static public final int TRAILING = 5; |
136 public static final int TRAILING = 5; |
137 |
137 |
138 /** |
138 /** |
139 * Space between the border and the component's edge |
139 * Space between the border and the component's edge |
140 */ |
140 */ |
141 static protected final int EDGE_SPACING = 2; |
141 protected static final int EDGE_SPACING = 2; |
142 |
142 |
143 /** |
143 /** |
144 * Space between the border and text |
144 * Space between the border and text |
145 */ |
145 */ |
146 static protected final int TEXT_SPACING = 2; |
146 protected static final int TEXT_SPACING = 2; |
147 |
147 |
148 /** |
148 /** |
149 * Horizontal inset of text that is left or right justified |
149 * Horizontal inset of text that is left or right justified |
150 */ |
150 */ |
151 static protected final int TEXT_INSET_H = 5; |
151 protected static final int TEXT_INSET_H = 5; |
152 |
152 |
153 /** |
153 /** |
154 * Creates a TitledBorder instance. |
154 * Creates a TitledBorder instance. |
155 * |
155 * |
156 * @param title the title the border should display |
156 * @param title the title the border should display |