public class RendererSettings
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
_SeaMineRenderMethod |
static int |
OperationalConditionModifierType_BAR |
static int |
OperationalConditionModifierType_SLASH |
static int |
SeaMineRenderMethod_ALT |
static int |
SeaMineRenderMethod_MEDAL |
static int |
TextBackgroundMethod_COLORFILL
There will be a colored box behind the text
|
static int |
TextBackgroundMethod_NONE
There will be no background for text
|
static int |
TextBackgroundMethod_OUTLINE
There will be an adjustable outline around the text (expensive)
Outline width of 4 is recommended.
|
static int |
TextBackgroundMethod_OUTLINE_QUICK
A different approach for outline which is quicker and seems to use
less memory.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addEventListener(armyc2.c5isr.renderer.utilities.SettingsEventListener sel) |
boolean |
getAutoCollapseModifiers() |
boolean |
getCacheEnabled() |
java.lang.Boolean |
getCenterOnHQStaff()
if true (default), when HQ Staff is present, location will be indicated by the free
end of the staff
|
int |
getDefaultPixelSize()
default size single point icons will render on the map
|
int |
getDeviceDPI() |
boolean |
getDrawAffiliationModifierAsLabel()
True to draw as modifier label in the "E/F" location.
|
java.awt.Color |
getFriendlyGraphicFillColor()
get the preferred fill affiliation color for graphics.
|
java.awt.Color |
getFriendlyGraphicLineColor()
get the preferred line affiliation color for graphics.
|
java.awt.Color |
getFriendlyUnitFillColor()
get the preferred fill affiliation color for units.
|
java.awt.Color |
getFriendlyUnitLineColor()
get the preferred line affiliation color for units.
|
java.awt.Color |
getHostileGraphicFillColor()
get the preferred fill affiliation color for graphics.
|
java.awt.Color |
getHostileGraphicLineColor()
get the preferred line affiliation color for graphics.
|
java.awt.Color |
getHostileUnitFillColor()
get the preferred fill affiliation color for units.
|
java.awt.Color |
getHostileUnitLineColor()
get the preferred line affiliation color for units.
|
static RendererSettings |
getInstance() |
float |
getKMLLabelScale() |
java.awt.Font |
getLabelFont()
get font object used for labels
|
int |
getLabelFontKerning() |
java.lang.String |
getLabelFontName()
the font name to be used for modifier labels
|
int |
getLabelFontSize()
get font point size
|
float |
getLabelFontTracking() |
int |
getLabelFontType()
Like Font.BOLD
|
java.awt.Font |
getMPLabelFont()
get font object used for labels
|
java.lang.String |
getMPLabelFontName()
the font name to be used for modifier labels
|
int |
getMPLabelFontSize()
get font point size
|
int |
getMPLabelFontType()
Like Font.BOLD
|
java.awt.Color |
getNeutralGraphicFillColor()
get the preferred fill affiliation color for graphics.
|
java.awt.Color |
getNeutralGraphicLineColor()
get the preferred line affiliation color for graphics.
|
java.awt.Color |
getNeutralUnitFillColor()
get the preferred fill affiliation color for units.
|
java.awt.Color |
getNeutralUnitLineColor()
get the preferred line affiliation color for units.
|
int |
getOperationalConditionModifierType() |
boolean |
getOutlineSPControlMeasures() |
boolean |
getScaleEchelon()
Returns the value determining if we scale the echelon font size or
just match the font size specified by the label font.
|
int |
getSeaMineRenderMethod() |
int |
getSinglePointSymbolOutlineWidth()
Deprecated.
|
int |
getTextBackgroundAutoColorThreshold()
Value from 0 to 255.
|
int |
getTextBackgroundMethod()
None, outline (default), or filled background.
|
int |
getTextOutlineWidth()
if RenderSettings.TextBackgroundMethod_OUTLINE is used,
the outline will be this many pixels wide.
|
boolean |
getTwoLabelOnly()
Get a boolean indicating between the use of ENY labels in all segments (false) or
to only set 2 labels one at the north and the other one at the south of the graphic (true).
|
java.awt.Color |
getUnknownGraphicFillColor()
get the preferred fill affiliation color for graphics.
|
java.awt.Color |
getUnknownGraphicLineColor()
get the preferred line affiliation color for graphics.
|
java.awt.Color |
getUnknownUnitFillColor()
get the preferred fill affiliation color for units.
|
java.awt.Color |
getUnknownUnitLineColor()
get the preferred line affiliation color for units.
|
boolean |
getUseLineInterpolation()
Returns the current setting for Line Interpolation.
|
void |
setAutoCollapseModifiers(boolean value)
Collapse Modifiers for fire support areas when the symbol isn't large enough to show all
the labels.
|
void |
setCacheEnabled(boolean active) |
void |
setCenterOnHQStaff(java.lang.Boolean value)
if true (default), when HQ Staff is present, location will be indicated by the free
end of the staff
|
void |
setDefaultPixelSize(int size)
default size single point icons will render on the map
|
void |
setDeviceDPI(int value)
set the screen DPI so the renderer can take DPI into account when
rendering for things like dashed lines and decorated lines.
|
void |
setDrawAffiliationModifierAsLabel(boolean value)
Determines how to draw the Affiliation modifier.
|
void |
setFriendlyGraphicFillColor(java.awt.Color friendlyGraphicFillColor)
Set the preferred fill affiliation color for graphics
|
void |
setFriendlyGraphicLineColor(java.awt.Color friendlyGraphicLineColor)
Set the preferred line affiliation color for graphics
|
void |
setFriendlyUnitFillColor(java.awt.Color friendlyUnitFillColor)
Set the preferred fill affiliation color for units
|
void |
setFriendlyUnitLineColor(java.awt.Color friendlyUnitLineColor)
Set the preferred line affiliation color for units
|
void |
setGraphicPreferredAffiliationColors(java.awt.Color friendlyGraphicLineColor,
java.awt.Color hostileGraphicLineColor,
java.awt.Color neutralGraphicLineColor,
java.awt.Color unknownGraphicLineColor,
java.awt.Color friendlyGraphicFillColor,
java.awt.Color hostileGraphicFillColor,
java.awt.Color neutralGraphicFillColor,
java.awt.Color unknownGraphicFillColor)
Set the preferred line and fill affiliation color for tactical graphics.
|
void |
setHostileGraphicFillColor(java.awt.Color hostileGraphicFillColor)
Set the preferred fill affiliation color for graphics
|
void |
setHostileGraphicLineColor(java.awt.Color hostileGraphicLineColor)
Set the preferred line affiliation color for graphics
|
void |
setHostileUnitFillColor(java.awt.Color hostileUnitFillColor)
Set the preferred fill affiliation color for units
|
void |
setHostileUnitLineColor(java.awt.Color hostileUnitLineColor)
Set the preferred line affiliation color for units
|
void |
setLabelFont(java.lang.String name,
int type,
int size)
Sets the font to be used for modifier labels
|
void |
setLabelFont(java.lang.String name,
int type,
int size,
java.lang.Boolean kerning,
float tracking) |
void |
setMPLabelFont(java.lang.String name,
int type,
int size) |
void |
setMPLabelFont(java.lang.String name,
int type,
int size,
float kmlScale) |
void |
setNeutralGraphicFillColor(java.awt.Color neutralGraphicFillColor)
Set the preferred fill affiliation color for graphics
|
void |
setNeutralGraphicLineColor(java.awt.Color neutralGraphicLineColor)
Set the preferred line affiliation color for graphics
|
void |
setNeutralUnitFillColor(java.awt.Color neutralUnitFillColor)
Set the preferred line affiliation color for units
|
void |
setNeutralUnitLineColor(java.awt.Color neutralUnitLineColor)
Set the preferred line affiliation color for units
|
void |
setOperationalConditionModifierType(int value)
Set the operational condition modifier to be slashes or bars
|
void |
setOutlineSPControlMeasures(boolean value) |
void |
setScaleEchelon(boolean value)
false to use label font size
true to scale it using symbolPixelBounds / 3.5
|
void |
setSeaMineRenderMethod(int method) |
void |
setSinglePointSymbolOutlineWidth(int width)
Deprecated.
|
void |
setTextBackgroundAutoColorThreshold(int value)
Value from 0 to 255.
|
void |
setTextBackgroundMethod(int textBackgroundMethod)
None, outline (default), or filled background.
|
void |
setTwoLabelOnly(boolean TwoLabelOnly)
Set a boolean indicating between the use of ENY labels in all segments (false) or
to only set 2 labels one at the north and the other one at the south of the graphic (true).
|
void |
setUnitPreferredAffiliationColors(java.awt.Color friendlyUnitLineColor,
java.awt.Color hostileUnitLineColor,
java.awt.Color neutralUnitLineColor,
java.awt.Color unknownUnitLineColor,
java.awt.Color friendlyUnitFillColor,
java.awt.Color hostileUnitFillColor,
java.awt.Color neutralUnitFillColor,
java.awt.Color unknownUnitFillColor)
Set the preferred line and fill affiliation color for units and tactical graphics.
|
void |
setUnknownGraphicFillColor(java.awt.Color unknownGraphicFillColor)
Set the preferred fill affiliation color for graphics
|
void |
setUnknownGraphicLineColor(java.awt.Color unknownGraphicLineColor)
Set the preferred line affiliation color for graphics
|
void |
setUnknownUnitFillColor(java.awt.Color unknownUnitFillColor)
Set the preferred fill affiliation color for units
|
void |
setUnknownUnitLineColor(java.awt.Color unknownUnitLineColor)
Set the preferred line affiliation color for units
|
void |
setUseLineInterpolation(boolean value)
For lines symbols with "decorations" like FLOT or LOC, when points are
too close together, we will start dropping points until we get enough
space between 2 points to draw the decoration.
|
public static final int TextBackgroundMethod_NONE
public static final int TextBackgroundMethod_COLORFILL
public static final int TextBackgroundMethod_OUTLINE
public static final int TextBackgroundMethod_OUTLINE_QUICK
public static int OperationalConditionModifierType_SLASH
public static int OperationalConditionModifierType_BAR
public static final int SeaMineRenderMethod_MEDAL
public static final int SeaMineRenderMethod_ALT
public static int _SeaMineRenderMethod
public static RendererSettings getInstance()
public void addEventListener(armyc2.c5isr.renderer.utilities.SettingsEventListener sel)
public void setTextBackgroundMethod(int textBackgroundMethod)
textBackgroundMethod - like RenderSettings.TextBackgroundMethod_NONEpublic int getTextBackgroundMethod()
public void setDefaultPixelSize(int size)
size - Integerpublic int getDefaultPixelSize()
Integerpublic void setOperationalConditionModifierType(int value)
value - like RendererSettings.OperationalConditionModifierType_SLASHpublic int getOperationalConditionModifierType()
public void setSeaMineRenderMethod(int method)
public int getSeaMineRenderMethod()
public void setUseLineInterpolation(boolean value)
value - Booleanpublic boolean getUseLineInterpolation()
Booleanpublic void setDeviceDPI(int value)
value - Integerpublic int getDeviceDPI()
public void setAutoCollapseModifiers(boolean value)
value - Booleanpublic boolean getAutoCollapseModifiers()
public void setCenterOnHQStaff(java.lang.Boolean value)
value - public java.lang.Boolean getCenterOnHQStaff()
public int getTextOutlineWidth()
public void setTextBackgroundAutoColorThreshold(int value)
value - public int getTextBackgroundAutoColorThreshold()
public void setSinglePointSymbolOutlineWidth(int width)
width - public int getSinglePointSymbolOutlineWidth()
public void setOutlineSPControlMeasures(boolean value)
public boolean getOutlineSPControlMeasures()
public void setScaleEchelon(boolean value)
value - public boolean getScaleEchelon()
public void setDrawAffiliationModifierAsLabel(boolean value)
public boolean getDrawAffiliationModifierAsLabel()
public void setLabelFont(java.lang.String name,
int type,
int size)
name - Like "arial"type - Like Font.TRUETYPE_FONTsize - Like 12public void setMPLabelFont(java.lang.String name,
int type,
int size)
public void setMPLabelFont(java.lang.String name,
int type,
int size,
float kmlScale)
public java.lang.String getMPLabelFontName()
public int getMPLabelFontType()
public int getMPLabelFontSize()
public void setLabelFont(java.lang.String name,
int type,
int size,
java.lang.Boolean kerning,
float tracking)
name - Like "arial"type - Like Font.BOLDsize - Like 12kerning - - default false. The default advances of single characters are not
appropriate for some character sequences, for example "To" or
"AWAY". Without kerning the adjacent characters appear to be
separated by too much space. Kerning causes selected sequences
of characters to be spaced differently for a more pleasing
visual appearance.tracking - - default 0.04 (TextAttribute.TRACKING_LOOSE).
The tracking value is multiplied by the font point size and
passed through the font transform to determine an additional
amount to add to the advance of each glyph cluster. Positive
tracking values will inhibit formation of optional ligatures.
Tracking values are typically between -0.1 and
0.3 values outside this range are generally not desirable.public java.lang.String getLabelFontName()
public int getLabelFontType()
public int getLabelFontSize()
public int getLabelFontKerning()
public float getLabelFontTracking()
public java.awt.Font getLabelFont()
public java.awt.Font getMPLabelFont()
public float getKMLLabelScale()
public void setCacheEnabled(boolean active)
public boolean getCacheEnabled()
public boolean getTwoLabelOnly()
public void setTwoLabelOnly(boolean TwoLabelOnly)
TwoLabelOnly - public java.awt.Color getFriendlyUnitFillColor()
public void setFriendlyUnitFillColor(java.awt.Color friendlyUnitFillColor)
friendlyUnitFillColor - Color like Color(255, 255, 255)public java.awt.Color getHostileUnitFillColor()
public void setHostileUnitFillColor(java.awt.Color hostileUnitFillColor)
hostileUnitFillColor - Color like Color(255, 255, 255)public java.awt.Color getNeutralUnitFillColor()
public void setNeutralUnitFillColor(java.awt.Color neutralUnitFillColor)
neutralUnitFillColor - Color like Color(255, 255, 255)public java.awt.Color getUnknownUnitFillColor()
public void setUnknownUnitFillColor(java.awt.Color unknownUnitFillColor)
unknownUnitFillColor - Color like Color(255, 255, 255)public java.awt.Color getHostileGraphicFillColor()
public void setHostileGraphicFillColor(java.awt.Color hostileGraphicFillColor)
hostileGraphicFillColor - Color like Color(255, 255, 255)public java.awt.Color getFriendlyGraphicFillColor()
public void setFriendlyGraphicFillColor(java.awt.Color friendlyGraphicFillColor)
friendlyGraphicFillColor - Color like Color(255, 255, 255)public java.awt.Color getNeutralGraphicFillColor()
public void setNeutralGraphicFillColor(java.awt.Color neutralGraphicFillColor)
neutralGraphicFillColor - Color like Color(255, 255, 255)public java.awt.Color getUnknownGraphicFillColor()
public void setUnknownGraphicFillColor(java.awt.Color unknownGraphicFillColor)
unknownGraphicFillColor - Color like Color(255, 255, 255)public java.awt.Color getFriendlyUnitLineColor()
public void setFriendlyUnitLineColor(java.awt.Color friendlyUnitLineColor)
friendlyUnitLineColor - Color like Color(255, 255, 255)public java.awt.Color getHostileUnitLineColor()
public void setHostileUnitLineColor(java.awt.Color hostileUnitLineColor)
hostileUnitLineColor - Color like Color(255, 255, 255)public java.awt.Color getNeutralUnitLineColor()
public void setNeutralUnitLineColor(java.awt.Color neutralUnitLineColor)
neutralUnitLineColor - Color like Color(255, 255, 255)public java.awt.Color getUnknownUnitLineColor()
public void setUnknownUnitLineColor(java.awt.Color unknownUnitLineColor)
unknownUnitLineColor - Color like Color(255, 255, 255)public java.awt.Color getFriendlyGraphicLineColor()
public void setFriendlyGraphicLineColor(java.awt.Color friendlyGraphicLineColor)
friendlyGraphicLineColor - Color like Color(255, 255, 255)public java.awt.Color getHostileGraphicLineColor()
public void setHostileGraphicLineColor(java.awt.Color hostileGraphicLineColor)
hostileGraphicLineColor - Color like Color(255, 255, 255)public java.awt.Color getNeutralGraphicLineColor()
public void setNeutralGraphicLineColor(java.awt.Color neutralGraphicLineColor)
neutralGraphicLineColor - Color like Color(255, 255, 255)public java.awt.Color getUnknownGraphicLineColor()
public void setUnknownGraphicLineColor(java.awt.Color unknownGraphicLineColor)
unknownGraphicLineColor - Color like Color(255, 255, 255)public void setGraphicPreferredAffiliationColors(java.awt.Color friendlyGraphicLineColor,
java.awt.Color hostileGraphicLineColor,
java.awt.Color neutralGraphicLineColor,
java.awt.Color unknownGraphicLineColor,
java.awt.Color friendlyGraphicFillColor,
java.awt.Color hostileGraphicFillColor,
java.awt.Color neutralGraphicFillColor,
java.awt.Color unknownGraphicFillColor)
friendlyGraphicLineColor - ColorhostileGraphicLineColor - ColorneutralGraphicLineColor - ColorunknownGraphicLineColor - ColorfriendlyGraphicFillColor - ColorhostileGraphicFillColor - ColorneutralGraphicFillColor - ColorunknownGraphicFillColor - Colorpublic void setUnitPreferredAffiliationColors(java.awt.Color friendlyUnitLineColor,
java.awt.Color hostileUnitLineColor,
java.awt.Color neutralUnitLineColor,
java.awt.Color unknownUnitLineColor,
java.awt.Color friendlyUnitFillColor,
java.awt.Color hostileUnitFillColor,
java.awt.Color neutralUnitFillColor,
java.awt.Color unknownUnitFillColor)
friendlyUnitLineColor - Color like Color(255, 255, 255). Set to null to ignore settinghostileUnitLineColor - ColorneutralUnitLineColor - ColorunknownUnitLineColor - ColorfriendlyUnitFillColor - ColorhostileUnitFillColor - ColorneutralUnitFillColor - ColorunknownUnitFillColor - Color