Class Maps
Implements
Inherited Members
Namespace: Syncfusion.Windows.Forms.Maps
Assembly: Syncfusion.Maps.Windows.dll
Syntax
public class Maps : BaseControl, IThemeProvider, IVisualStyle, IDisposable, INotifyPropertyChanged
Constructors
Maps()
Declaration
[SecurityCritical]
public Maps()
Properties
BaseMapIndex
Gets or sets a value to specify the BaseMapIndex.
Declaration
public int BaseMapIndex { get; set; }
Property Value
Type |
---|
System.Int32 |
EnableZoomOnSelection
Gets or sets a value indicating whether to zoom on selection.
Declaration
public bool EnableZoomOnSelection { get; set; }
Property Value
Type |
---|
System.Boolean |
IsVisualStyleEnabled
Gets a value indicating whether the visual style based theme is applied to the control and also indicates whether the theme files are referred from external assemblies or not.
Declaration
public bool IsVisualStyleEnabled { get; }
Property Value
Type | Description |
---|---|
System.Boolean | Return true, if the visual style based theme is applied to the control. Otherwise returns false. |
Layers
Gets or sets the layer collection of shape file layer.
Declaration
public ObservableCollection<ShapeFileLayer> Layers { get; set; }
Property Value
Type |
---|
System.Collections.ObjectModel.ObservableCollection<ShapeFileLayer> |
MapBackgroundBrush
Gets or sets the background color for the map.
Declaration
public Brush MapBackgroundBrush { get; set; }
Property Value
Type |
---|
System.Drawing.Brush |
MapItemFont
Gets or sets items font style of the map.
Declaration
public Font MapItemFont { get; set; }
Property Value
Type |
---|
System.Drawing.Font |
MapItemsShape
Gets or sets the items shape of the map.
Declaration
public MapItemShapes MapItemsShape { get; set; }
Property Value
Type |
---|
MapItemShapes |
MapItemStroke
Gets or sets the item stroke of the map.
Declaration
public Brush MapItemStroke { get; set; }
Property Value
Type |
---|
System.Drawing.Brush |
MaxZoomLevel
To specify the maximum Zoominglevel
Declaration
public int MaxZoomLevel { get; set; }
Property Value
Type |
---|
System.Int32 |
OnSelectionChanged
Gets or sets a value on selection changed.
Declaration
public string OnSelectionChanged { get; set; }
Property Value
Type |
---|
System.String |
SelectedMapShapes
Gets the selected map shapes.
Declaration
public ObservableCollection<MapShape> SelectedMapShapes { get; }
Property Value
Type |
---|
System.Collections.ObjectModel.ObservableCollection<MapShape> |
ThemeStyle
Gets or sets the MapsVisualStyle value used to customize the appearance of the Maps.
Declaration
public MapsVisualStyle ThemeStyle { get; set; }
Property Value
Type |
---|
MapsVisualStyle |
Remarks
This ThemeStyle settings will be applied only when the VisualStyleBased theme has been applied to the control.
ZoomFactor
To specify the zooming factor
Declaration
public float ZoomFactor { get; set; }
Property Value
Type |
---|
System.Single |
ZoomLevel
To specify the Zoomlevel
Declaration
public int ZoomLevel { get; set; }
Property Value
Type |
---|
System.Int32 |
Methods
CreateAccessibilityInstance()
To specify wheather to enable zoom on selection or not
Declaration
protected override AccessibleObject CreateAccessibilityInstance()
Returns
Type |
---|
System.Windows.Forms.AccessibleObject |
Dispose(Boolean)
Clean up any resources being used.
Declaration
protected override void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing | true if managed resources should be disposed; otherwise, false. |
GetControlName(String)
Helps to apply the ControlName settings in control
Declaration
public override string GetControlName(string controlName)
Parameters
Type | Name | Description |
---|---|---|
System.String | controlName | ControlName |
Returns
Type |
---|
System.String |
Overrides
GetMapCoordinates(PointF)
Get the pixel point from the shape point(latitude and logitude) value.
Declaration
public PointF GetMapCoordinates(PointF shapePoint)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.PointF | shapePoint | The shape point value. |
Returns
Type | Description |
---|---|
System.Drawing.PointF | The screen(pixel) point. |
OnKeyUp(KeyEventArgs)
Invoked when an unhandled OnKeyUp(KeyEventArgs) routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
Declaration
protected override void OnKeyUp(KeyEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Forms.KeyEventArgs | e | The key event arguments. |
OnMouseClick(MouseEventArgs)
Invoked when an unhandled OnMouseClick(MouseEventArgs) routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
Declaration
protected override void OnMouseClick(MouseEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Forms.MouseEventArgs | e | The mouse event arguments. |
OnMouseDown(MouseEventArgs)
Invoked when an unhandled OnMouseDown(MouseEventArgs) routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
Declaration
protected override void OnMouseDown(MouseEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Forms.MouseEventArgs | e | The mouse event arguments. |
OnMouseLeave(EventArgs)
Invoked when an unhandled OnMouseLeave(EventArgs) routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
Declaration
protected override void OnMouseLeave(EventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.EventArgs | e | The event arguments. |
OnMouseMove(MouseEventArgs)
Invoked when an unhandled OnMouseMove(MouseEventArgs) routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
Declaration
protected override void OnMouseMove(MouseEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Forms.MouseEventArgs | e | The mouse event arguments. |
OnMouseUp(MouseEventArgs)
Invoked when an unhandled OnMouseUp(MouseEventArgs) routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
Declaration
protected override void OnMouseUp(MouseEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Forms.MouseEventArgs | e | The mouse event arguments. |
OnMouseWheel(MouseEventArgs)
Invoked when an unhandled OnMouseWheel(MouseEventArgs) routed event reaches an element in its route that is derived from this class. Implement this method to add class handling for this event.
Declaration
protected override void OnMouseWheel(MouseEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Forms.MouseEventArgs | e | The mouse event arguments |
OnPaint(PaintEventArgs)
override method to draw shapes, bubbles, selected shape and map items.
Declaration
protected override void OnPaint(PaintEventArgs pe)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Forms.PaintEventArgs | pe | The paint event args. |
OnPropertyChanged(String)
Called when the property value gets changed.
Declaration
protected virtual void OnPropertyChanged(string propertyName)
Parameters
Type | Name | Description |
---|---|---|
System.String | propertyName | The property name. |
OnThemeNameChanged(String)
Helps to apply the ThemeName settings in control
Declaration
public override void OnThemeNameChanged(string themeName)
Parameters
Type | Name | Description |
---|---|---|
System.String | themeName | ThemeName |
Overrides
UpdateLayers()
To upate the is update layer property value.
Declaration
public void UpdateLayers()
ZoomIn()
To perform zoom in operation.
Declaration
public void ZoomIn()
ZoomIn(Int32)
To perform zoom in operation with the empty point value.
Declaration
public void ZoomIn(int zoomLevel)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | zoomLevel | The zoom level value. |
ZoomOut()
Perfom zoom out operation based on the zoom level.
Declaration
public void ZoomOut()
Events
AnnotationDrawing
Raised when the annotation gets drawn.
Declaration
public event Maps.AnnotationDrawingEventHandler AnnotationDrawing
Event Type
Type |
---|
Maps.AnnotationDrawingEventHandler |
MapItemDrawing
Raised when the map item gets drawn.
Declaration
public event Maps.MapItemEventHandler MapItemDrawing
Event Type
Type |
---|
Maps.MapItemEventHandler |
PropertyChanged
Raised when property value gets changed..
Declaration
public event PropertyChangedEventHandler PropertyChanged
Event Type
Type |
---|
System.ComponentModel.PropertyChangedEventHandler |
ShapeSelected
Raised when the shape selected in the map.
Declaration
public event Maps.ShapeSelectedEventHandler ShapeSelected
Event Type
Type |
---|
Maps.ShapeSelectedEventHandler |
TooltipDrawing
Raised tooltip drawing event when the tooltip gets drawn.
Declaration
public event Maps.TooltipDrawingEventHandler TooltipDrawing
Event Type
Type |
---|
Maps.TooltipDrawingEventHandler |