KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > jcckit > graphic > TextAttributes


1 /*
2  * Copyright 2003-2004, Franz-Josef Elmer, All rights reserved
3  *
4  * This library is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License as published by
6  * the Free Software Foundation; either version 2.1 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU Lesser General Public License for more details
13  * (http://www.gnu.org/copyleft/lesser.html).
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with this library; if not, write to the Free Software
17  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18  */

19 package jcckit.graphic;
20
21 import java.awt.Color JavaDoc;
22
23 /**
24  * Interface for text attributes.
25  *
26  * @author Franz-Josef Elmer
27  */

28 public interface TextAttributes extends GraphicAttributes {
29   /**
30    * Returns the text color.
31    * @return <tt>null</tt> means default color of the renderer.
32    */

33   public Color JavaDoc getTextColor();
34
35   /**
36    * Returns the font name.
37    * @return <tt>null</tt> means default font name of the renderer.
38    */

39   public String JavaDoc getFontName();
40
41   /**
42    * Returns the font style.
43    * @return <tt>null</tt> means default font style of the renderer.
44    */

45   public FontStyle getFontStyle();
46
47   /**
48    * Returns the font size in units of the device-independent coordinates.
49    */

50   public double getFontSize();
51
52   /**
53    * Returns the orientation angle in degree. Zero means
54    * normal text orientation. Any positive angle means a
55    * counter-clockwise rotation of the text.
56    */

57   public double getOrientationAngle();
58
59   /**
60    * Returns the anchor for horizontal position of the text.
61    * Note, that the anchor is related to the text <em>before</em>
62    * it is rotated by the orientation angle.
63    * @return one of the three instances of <tt>Anchor</tt>.
64    */

65   public Anchor getHorizontalAnchor();
66
67   /**
68    * Returns the anchor for vertical position of the text.
69    * Note, that the anchor is related to the text <em>before</em>
70    * it is rotated by the orientation angle.
71    * @return one of the three instances of <tt>Anchor</tt>.
72    */

73   public Anchor getVerticalAnchor();
74 }
75
76
Popular Tags