|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectgov.nasa.worldwind.symbology.milstd2525.graphics.DefaultLabelLayouts
public class DefaultLabelLayouts
Object to provide default label layouts for MIL-STD-2525C tactical point graphics. The layout is used to arrange text modifiers around the icon.
| Field Summary | |
|---|---|
protected Map<String,List<TacticalGraphicSymbol.LabelLayout>> |
layouts
Map to hold layouts. |
| Constructor Summary | |
|---|---|
DefaultLabelLayouts()
Create the map and populate it with the default layouts. |
|
| Method Summary | |
|---|---|
protected void |
addLayout(List<TacticalGraphicSymbol.LabelLayout> layoutList,
String key,
Offset... offsets)
Add a layout to a layout map, possibly replacing an existing layout. |
protected List<TacticalGraphicSymbol.LabelLayout> |
createLayout(String key,
Offset offset,
Offset hotspot)
Create a simple layout map and populate it with one key value pair. |
List<TacticalGraphicSymbol.LabelLayout> |
get(String sidc)
Indicates the layout for a particular type of graphic. |
protected void |
populateMap()
Populate the map with the default layouts. |
protected void |
putAll(List<TacticalGraphicSymbol.LabelLayout> value,
String... keys)
Map one value to many keys. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Map<String,List<TacticalGraphicSymbol.LabelLayout>> layouts
| Constructor Detail |
|---|
public DefaultLabelLayouts()
| Method Detail |
|---|
protected void addLayout(List<TacticalGraphicSymbol.LabelLayout> layoutList,
String key,
Offset... offsets)
layoutList - List to which to add an entry.key - Modifier key.offsets - List of offsets from which to create one or more LabelLayout objects. The offsets are specified
in pairs: first the image offset and then the label offset. If multiple pairs are provided,
then multiple LabelLayouts will be created and added to the map.
IllegalArgumentException - if offsets does not have even length.
protected List<TacticalGraphicSymbol.LabelLayout> createLayout(String key,
Offset offset,
Offset hotspot)
key - Modifier key.offset - Offset within the image at which to place the label.hotspot - Offset within the label to align with the label point in the image.
public List<TacticalGraphicSymbol.LabelLayout> get(String sidc)
sidc - Symbol code of the graphic.
protected void populateMap()
protected void putAll(List<TacticalGraphicSymbol.LabelLayout> value,
String... keys)
value - Value to add.keys - Keys that map to the value.
|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||