MapKit.MKOverlayView.DrawMapRect Method
Draws the overlay view for the specified mapRect.

Syntax

[Foundation.Export("drawMapRect:zoomScale:inContext:")]
[ObjCRuntime.ThreadSafe]
public virtual void DrawMapRect (MKMapRect mapRect, CoreGraphics.CGContext context, nfloat zoomScale)

Parameters

mapRect
The MapKit.MKMapRect that needs to be redrawn.
zoomScale
The current scale factor of the map. Helpful for configuring stroke widths or other scalable aspects.
context
The CoreGraphics.CGContext to be used for rendering.

Remarks

Application developers should override this function, rather than UIView.DrawRect, for customized rendering.

Custom MapKit.MKOverlay rendering should be done with all positioning specified in MapKit types such as MapKit.MKMapPoint and MapKit.MKMapRect rather than screen-geometry values such as the UIView.Frame.

This method may be called from several background threads simultaneously on several tiles. Application developers are responsible for ensuring that their override of this method is thread-safe.

For performance reasons, application developers should not draw the entire MapKit.MKOverlayView when this method is called but should instead strive to render only the region specified by mapRect.

This can be used from a background thread.

Requirements

Namespace: MapKit
Assembly: Xamarin.iOS (in Xamarin.iOS.dll)
Assembly Versions: 0.0.0.0