root / trunk / libraries / libFMap / src / com / iver / cit / gvsig / fmap / core / symbols / ITextSymbol.java @ 10993
History | View | Annotate | Download (1.39 KB)
1 |
package com.iver.cit.gvsig.fmap.core.symbols; |
---|---|
2 |
|
3 |
import java.awt.Color; |
4 |
import java.awt.Font; |
5 |
import java.awt.Graphics2D; |
6 |
import java.awt.geom.AffineTransform; |
7 |
|
8 |
import com.iver.cit.gvsig.fmap.core.FShape; |
9 |
/**
|
10 |
* Represents a ISymbol that draws a text.
|
11 |
* @author jaume
|
12 |
*
|
13 |
*/
|
14 |
public interface ITextSymbol extends ISymbol { |
15 |
/**
|
16 |
* Establishes the font that will be used to render this ITextSymbol.
|
17 |
* @param font
|
18 |
*/
|
19 |
public abstract void setFont(Font font); |
20 |
|
21 |
/**
|
22 |
* Returns the currently set font.
|
23 |
* @return Font
|
24 |
*/
|
25 |
public abstract Font getFont(); |
26 |
|
27 |
/**
|
28 |
* Returns the currently color set to be applied to the text
|
29 |
* @return Color
|
30 |
*/
|
31 |
public abstract Color getTextColor(); |
32 |
|
33 |
/**
|
34 |
* Sets the color of the text
|
35 |
* @param color
|
36 |
*/
|
37 |
public abstract void setTextColor(Color color); |
38 |
|
39 |
/**
|
40 |
* Returns the text contained by this symbol
|
41 |
* @return
|
42 |
* @deprecated ?do i need it?
|
43 |
*/
|
44 |
public abstract String getText(); |
45 |
|
46 |
/**
|
47 |
* Sets the text to be rendered by this symbol
|
48 |
* @param text, a String
|
49 |
*/
|
50 |
public abstract void setText(String text); |
51 |
|
52 |
/**
|
53 |
* Sets the font size currently set to this symbol
|
54 |
* @param d
|
55 |
*/
|
56 |
public abstract void setFontSize(double d); |
57 |
|
58 |
/**
|
59 |
* Computes a FShape wrapping the text to be applied
|
60 |
* @param g
|
61 |
* @param targetSymbolShape
|
62 |
* @return
|
63 |
*/
|
64 |
public abstract FShape getTextWrappingShape(Graphics2D g, AffineTransform affineTransform, FShape targetSymbolShape); |
65 |
|
66 |
} |