Platforms to show: All Mac Windows Linux Cross-Platform
Back to MKAnnotationViewMBS class.
MKAnnotationViewMBS.annotation as MKAnnotationMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
You should not change the value of this property directly. This property contains a non-nil value only while the annotation view is visible on the map. If the view is queued and waiting to be reused, the value is nil
(Read and Write property)
Some examples using this property:
MKAnnotationViewMBS.CalloutOffset as NSPointMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
This property determines the additional distance by which to move the callout bubble. When this property is set to (0, 0), the anchor point of the callout bubble is placed on the top-center point of the annotation view’s frame. Specifying positive offset values moves the callout bubble down and to the right, while specifying negative values moves it up and to the left.
The calloutOffset property is not used in macOS apps. Instead, macOS apps use leftCalloutOffset and rightCalloutOffset.
(Read and Write property)
MKAnnotationViewMBS.canShowCallout as Boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
If the value of this property is YES, a standard callout bubble is shown when the user taps a selected annotation view. The callout uses the title and subtitle text from the associated annotation object. If there is no title text, though, the annotation view is treated as if its enabled property is set to NO. The callout also displays any custom callout views stored in the leftCalloutAccessoryView and rightCalloutAccessoryView properties.
If the value of this property is NO, the value of the title and subtitle strings are ignored and the annotation view remains enabled by default. You can still disable the view explicitly using the enabled property.
(Read and Write property)
Some examples using this property:
MKAnnotationViewMBS.CenterOffset as NSPointMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
By default, the center point of an annotation view is placed at the coordinate point of the associated annotation. You can use this property to reposition the annotation view as needed. This x and y offset values are measured in points. Positive offset values move the annotation view down and to the right, while negative values move it up and to the left.
(Read and Write property)
MKAnnotationViewMBS.clusterAnnotationView as MKAnnotationViewMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
When the annotation view is being displayed on the map, the value of this property is nil.
(Read only property)
MKAnnotationViewMBS.clusteringIdentifier as String
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
The default value of this property is empty, which prevents the annotation view from being clustered with other annotation views. Setting the property to a non empty value it to participate in clustering.
Clustering occurs when there is a collision between multiple annotation views with the same identifier on the map surface. The annotation views involved in the collision are removed from the map view and replaced by a clustering annotation view, which displays the title from one of the annotations and provides access to the other annotations.
(Read and Write property)
Some examples using this property:
MKAnnotationViewMBS.collisionMode as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
(Read and Write property)
Some examples using this property:
MKAnnotationViewMBS.detailCalloutAccessoryView as NSViewMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
(Read and Write property)
MKAnnotationViewMBS.displayPriority as Double
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
An annotation view whose priority is set to DisplayPriorityRequired is always visible on the map, whereas other priorities may result in the annotation view being hidden.
The default value of this property is DisplayPriorityRequired.
(Read and Write property)
Some examples using this property:
MKAnnotationViewMBS.draggable as Boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
Setting this property to true makes an annotation draggable by the user. If true, the associated annotation object must also implement the setCoordinate: method. The default value of this property is false.
Setting this property to true, lets the map view know that the annotation is always draggable. In other words, you cannot conditionalize drag operations by attempting to stop an operation that has already been initiated; doing so can lead to undefined behavior. Once begun, the drag operation should always continue to completion.
(Read and Write property)
Some examples using this property:
MKAnnotationViewMBS.dragState as Integer
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
To support drag operations, you must override the implementation of this property and update the drag state at the following times:
When the drag state changes to MKAnnotationViewDragStateStarting, you should set the state to MKAnnotationViewDragStateDragging. If you perform an animation to indicate the beginning of a drag, you should perform that animation before changing the state. Changing the state to the new value lets the map know that your animations are done.
When the state changes to either MKAnnotationViewDragStateCanceling or MKAnnotationViewDragStateEnding, set the state to MKAnnotationViewDragStateNone. If you perform an animation at the end of a drag, you should perform that animation before changing the state.
Changing the state to the MKAnnotationViewDragStateDragging or MKAnnotationViewDragStateNone value is the way to signal to the map view that you are done with any animations you wanted to perform. For example, when a drag operation begins for a pin annotation, the MKPinAnnotationView class executes an animation to lift the pin off the map. Similarly, when the pin is dropped, the class performs a drop animation. Even if you do not perform any animations, you should still change the value of this property to reflect the correct state.
You must not try to abort a new drag operation by changing the state from MKAnnotationViewDragStateStarting to MKAnnotationViewDragStateNone. If you do not want your annotation view to be draggable, set the draggable property to NO.
(Read and Write property)
MKAnnotationViewMBS.enabled as Boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
The default value of this property is YES. If the value of this property is NO, the annotation view ignores touch events and cannot be selected. Subclasses may also display the annotation contents differently depending on the value of this property.
(Read and Write property)
MKAnnotationViewMBS.highlighted as Boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
You should not set the value of this property directly. The map view sets it in response to touch events entering or exiting the annotation view’s bounds.
(Read and Write property)
MKAnnotationViewMBS.image as NSImageMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
Looks like MKPinAnnotationViewMBS likes to ignore it, so you may prefer to use MKAnnotationViewMBS directly.
(Read and Write property)
MKAnnotationViewMBS.leftCalloutAccessoryView as NSViewMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
The default value of this property is nil. The left callout view is typically used to display information about the annotation or to link to custom information provided by your application.
In an iOS app, if the view you specify is also a descendant of the UIControl class, you can use the map view’s delegate to receive notifications when your control is tapped. If it does not descend from UIControl, your view is responsible for handling any touch events within its bounds.
In a macOS app, the callout view’s view controller can implement an action method that responds when a user clicks the control in a callout view.
(Read and Write property)
MKAnnotationViewMBS.leftCalloutOffset as NSPointMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
This property specifies where the anchor of the callout should be shown when it’s oriented off the left side of the annotation view.
(Read and Write property)
MKAnnotationViewMBS.reuseIdentifier as String
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
You specify the reuse identifier when you create the view. You use this type later to retrieve an annotation view that was created previously but which is currently unused because its annotation is not on screen.
If you define distinctly different types of annotations (with distinctly different annotation views to go with them), you can differentiate between the annotation types by specifying different reuse identifiers for each one.
(Read only property)
Some examples using this property:
MKAnnotationViewMBS.rightCalloutAccessoryView as NSViewMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
This property is set to nil by default. The right callout view is typically used to link to more detailed information about the annotation. In an iOS app, a common view to specify for this property is a button object whose type is set to UIButtonTypeDetailDisclosure.
In an iOS app, if the view you specify is also a descendant of the UIControl class, you can use the map view’s delegate to receive notifications when your control is tapped. If it does not descend from UIControl, your view is responsible for handling any touch events within its bounds.
In a macOS app, the callout view’s view controller can implement an action method that responds when a user clicks the control in a callout view.
(Read and Write property)
MKAnnotationViewMBS.rightCalloutOffset as NSPointMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ❌ No | Desktop only |
This property specifies where the anchor of the callout should be shown when it’s oriented off the right side of the annotation view.
(Read and Write property)
MKAnnotationViewMBS.selected as Boolean
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
property | MapKit | MBS MacFrameworks Plugin | 19.0 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
You should not set the value of this property directly. If the property contains true, the annotation view is displaying a callout bubble.
(Read and Write property)
The items on this page are in the following plugins: MBS MacFrameworks Plugin.