|
Chart FX 7 for Java Server | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.softwarefx.chartfx.server.maps.MapRegion
public abstract class MapRegion
Provides access to the MapRegion object.
The supported members fo the MapRegion class allow you to read the attributes for a selected map region. Use the FindMapRegion method of the Map class to return a MapRegion object, which will then expose the properties and methods of this class. These members are also utilized within the mouse events (MouseUp, MouseDown, etc.).
Constructor Summary | |
---|---|
MapRegion()
|
Method Summary | |
---|---|
void |
drillDownTo()
Error: Member MapRegion.drillDownTo member not found |
double |
get(int series)
Returns the element at the specified position in the MapRegion. |
AnnotationObject |
getBoundary()
Returns the AnnotationObject of the selected MapRegion from the AnnotationObjectsList for the map. |
String |
getDataText()
Gets the DataText attribute of the MapRegion object. |
String |
getDisplayText()
Gets the DisplayText. |
Font |
getFont()
Gets the Font. |
int |
getLevel()
Gets the current DetailLevel which the MapRegion object exists. |
int |
getPoint()
Gets the point index of the MapRegion object. |
PointAttributes |
getPointAttributes()
Gets the PointAttributes object for the selected map region. |
String |
getSvgText()
Gets the SvgText attribute of the MapRegion object. |
AnnotationObject |
getText()
Returns the Text/Label part of the selected MapRegion from the map. |
int |
getWinnerSeries()
Gets the WinnerSeries for the MapRegion. |
void |
setDisplayText(String value)
Gets the DisplayText attribute of the MapRegion object. |
void |
setFont(Font value)
Sets the Font for the selected MapRegion object. |
void |
zoomTo()
Error: Member MapRegion.zoomTo member not found |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MapRegion()
Method Detail |
---|
public void drillDownTo()
Error: Member MapRegion.drillDownTo member not found
ERROR: Doc member not found
public double get(int series)
Returns the element at the specified position in the MapRegion.
series
- Index of the series to return.public AnnotationObject getBoundary()
Returns the AnnotationObject of the selected MapRegion from the AnnotationObjectsList for the map.
This is a read only property.
Once you have selected a MapRegion using the Map.findMapRegion(java.lang.String)
method of the Map
class, using this property you can obtain the AnnotationObject that region contained in the Map.getAnnotationObjectsList()
.
MapRegion mr = map1.FindMapRegion("CA",LabelLinkSearchTypes.FromDisplay);
AnnotationObject annObj = mr.Boundary;
annObj.Color = Color.Purple;
This could also be very useful if you wish to add an Annotation object to the map. For example, if you wanted to create an AnnotationArrow that points to a selected region:
MapRegion mr = map1.FindMapRegion("CA",LabelLinkSearchTypes.FromDisplay);
AnnotationObject annObj = mr.Boundary;
AnnotationArrow arrow = new AnnotationArrow();
arrow.Color = Color.Red;
arrow.Height = 30;
arrow.Width = 30;
arrow.Top = annObj.Top;
arrow.Left = (annObj.Left-10);
arrow.Border.Color = Color.Red;
map1.AnnotationObjectsList.Add(arrow);
Map.getAnnotationObjectsList()
,
Map.findMapRegion(java.lang.String)
,
Map
public String getDataText()
Gets the DataText attribute of the MapRegion object.
This is a read-only property.
The Map.findMapRegion(java.lang.String)
method of the Map
class returns a desired MapRegion object.
Map.findMapRegion(java.lang.String)
,
Map
public String getDisplayText()
Gets the DisplayText. For more detail see setDisplayText(java.lang.String)
.
public Font getFont()
Gets the Font. For more detail see setFont(java.awt.Font)
.
public int getLevel()
Gets the current DetailLevel which the MapRegion object exists.
This is a read-only property.
The Map.findMapRegion(java.lang.String)
method of the Map
class returns a selected MapRegion object.
Map.setDetailLevel(int)
,
Map.findMapRegion(java.lang.String)
,
Map
public int getPoint()
Gets the point index of the MapRegion object.
This is a read-only property.
The Map.findMapRegion(java.lang.String)
method of the Map
class returns a selected MapRegion object.
Map.findMapRegion(java.lang.String)
,
Map
public PointAttributes getPointAttributes()
Gets the PointAttributes object for the selected map region.
This property may be used to return the PointAttributes object for a selected MapRegion. It is important to remember if this point object is utilized for any other region, that region will also be modified.
getBoundary()
public String getSvgText()
Gets the SvgText attribute of the MapRegion object.
This is a read-only property.
The Map.findMapRegion(java.lang.String)
method of the Map
class returns a selected MapRegion object.
Map.findMapRegion(java.lang.String)
,
Map
public AnnotationObject getText()
Returns the Text/Label part of the selected MapRegion from the map.
This is a read only property.
Once you have selected a MapRegion using the Map.findMapRegion(java.lang.String)
methodMap
, using this property you can obtain the text/label object for that region. The Map.getAnnotationObjectsList()
is a collection of all the annotation objects used to create the map.
This property can return either an AnnotationText object or AnnotationGroup object. In the case of an AnnotationGroup object, one of the AnnotationObjects in the group will be of type AnnotationText. The Sample below illistrates how to determine the type of an object and modify the text:
MapRegion mp = map1.FindMapRegion("CT",LabelLinkSearchTypes.FromDisplay);
AnnotationText annText = null;
AnnotationGroup annGrp = null;
if( mp.Text != null)
{
if (mp.Text.GetType() == typeof(AnnotationText))
{
annText = (AnnotationText) mp.Text;
annText.Text = "NewText";
}
else
{
annGrp = (AnnotationGroup) mp.Text;
foreach ( AnnotationObject annObjTemp in annGrp.List)
{
// Only one text object per region
if ( annObjTemp.GetType() == typeof(AnnotationText))
{
annText = (AnnotationText) annObjTemp;
annText.Text = "NewText";
break;
}
}
}
}
Map.getAnnotationObjectsList()
,
Map.findMapRegion(java.lang.String)
,
Map
public int getWinnerSeries()
Gets the WinnerSeries for the MapRegion.
This is a read only property used to obtain the WinnerSeries for the selected MapRegion object.
MapRegion
public void setDisplayText(String value)
Gets the DisplayText attribute of the MapRegion object.
This is a read-only property.
The Map.findMapRegion(java.lang.String)
method of the Map
class returns a selected MapRegion object.
Map.findMapRegion(java.lang.String)
,
Map
public void setFont(Font value)
Sets the Font for the selected MapRegion object.
The Map
class also supports a #Font
property which may be used to set a Font object for the entire map.
The Map.findMapRegion(java.lang.String)
method is used to obtain a selected map region based on the DataText, DisplayText or SvgText of a map region.
For more information regarding the Font type, please refer to the java.awt.Font Documentation.
setFont(java.awt.Font)
,
Map.findMapRegion(java.lang.String)
,
Map
public void zoomTo()
Error: Member MapRegion.zoomTo member not found
ERROR: Doc member not found
|
http://www.softwarefx.com | |||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |