Revision 11138 trunk/libraries/libFMap/src/com/iver/cit/gvsig/fmap/rendering/styling/IPlacementConstraints.java

View differences:

IPlacementConstraints.java
43 43
 *
44 44
 * $Id$
45 45
 * $Log$
46
 * Revision 1.3  2007-04-02 16:34:56  jaume
46
 * Revision 1.4  2007-04-11 16:01:08  jaume
47
 * maybe a label placer refactor
48
 *
49
 * Revision 1.3  2007/04/02 16:34:56  jaume
47 50
 * Styled labeling (start commiting)
48 51
 *
49 52
 * Revision 1.2  2007/03/09 08:33:43  jaume
......
60 63

  
61 64
package com.iver.cit.gvsig.fmap.rendering.styling;
62 65

  
66
import java.awt.geom.AffineTransform;
67

  
63 68
import org.cresques.px.gml.MultiPolygon;
64 69

  
65 70
import com.iver.cit.gvsig.fmap.core.FShape;
......
72 77
public interface IPlacementConstraints {
73 78

  
74 79
	// constants regarding label duplication
75
	public static final int REMOVE_DUPLICATE_LABELS = 2;
76
	public static final int ONE_LABEL_PER_FEATURE = 3;
77
	public static final int ONE_LABEL_PER_FEATURE_PART = 4;
80
	public static final int REMOVE_DUPLICATE_LABELS             =       2;
81
	public static final int ONE_LABEL_PER_FEATURE               =       3;
82
	public static final int ONE_LABEL_PER_FEATURE_PART          =       4;
78 83

  
79 84
	// constants regarding point settings
80
	public static final int OFFSET_HORIZONTALY_AROUND_THE_POINT = 5;
81
	public static final int ON_TOP_OF_THE_POINT = 6;
82
	public static final int AT_SPECIFIED_ANGLE = 7;
83
	public static final int AT_ANGLE_SPECIFIED_BY_A_FIELD = 8;
85
	public static final int OFFSET_HORIZONTALY_AROUND_THE_POINT =       5;
86
	public static final int ON_TOP_OF_THE_POINT                 =       6;
87
	public static final int AT_SPECIFIED_ANGLE                  =       7;
88
	public static final int AT_ANGLE_SPECIFIED_BY_A_FIELD       =       8;
84 89

  
85 90
	// constants regarding polygon settings (also apply for lines)
86
	public static final int HORIZONTAL = 9;
87
	public static final int PARALLEL = 10;
91
	public static final int HORIZONTAL                          =       9;
92
	public static final int PARALLEL                            =      10;
88 93

  
89 94
	// constants regarding line settings
90
	public static final int FOLLOWING_LINE = 11;
91
	public static final int PERPENDICULAR = 12;
95
	public static final int FOLLOWING_LINE                      =      11;
96
	public static final int PERPENDICULAR                       =      12;
92 97

  
93 98
	// constants regarding label position along the line
94
	public static final int ABOVE_THE_LINE = 1000;
95
	public static final int ON_THE_LINE = 1100;
96
	public static final int BELLOW_THE_LINE = 1200;
99
	public static final int ABOVE_THE_LINE                      =    1000;
100
	public static final int ON_THE_LINE                         =    1100;
101
	public static final int BELLOW_THE_LINE                     =    1200;
102
	public static final int AT_THE_BEGINING                     =   10000;
103
	public static final int AT_THE_END                          =   20000;
104
	public static final int PAGE_ORIENTED                       =  100000;
105
	public static final int LINE_ORIENTED                       =  200000;
97 106

  
98 107
	public abstract void setDuplicateLabelsMode(int mode);
99 108

  
......
110 119
	public abstract int getDuplicateLabelsMode();
111 120

  
112 121
	/**
122
	 * Tells if the place mode selected is to put the label over the <b>POINT</b>
123
	 * @return boolean
124
	 */
125
	public abstract boolean isOnTopOfThePoint();
126

  
127
	public abstract boolean isAtTheBeginingOfLine();
128
	public abstract boolean isAtTheEndOfLine();
129
	public abstract boolean isBellowTheLine();
130
	public abstract boolean isAboveTheLine();
131
	public abstract boolean isPageOriented();
132
	public abstract boolean isLineOriented();
133

  
134

  
135
	/**
113 136
	 * Calculates the position where the next label will be placed. Or null
114 137
	 * if the label does not have to be placed.
115 138
	 *
......
121 144
	public abstract FShape[] getLocationsFor(IGeometry geom, FShape labelShape,
122 145
			MultiPolygon exclusionZone);
123 146

  
147
	public abstract void placeLabel(IGeometry geom, LabelClass lc, MultiPolygon exclusionZone, AffineTransform transform);
148

  
124 149
}

Also available in: Unified diff