---
title: "MTTextPopup | Mobile sdk | Mobile sdk ios | Ios"
description: "Basic text popup."
---

> For AI agents: a documentation index is available at [/llms.txt](https://docs.maptiler.com/llms.txt). Markdown versions of all pages are available by appending .md to any URL.

# MTTextPopup

```
public class MTTextPopup : MTAnnotation, MTMapViewContent, @unchecked Sendable
```

Basic text popup.

Can be attached to MTMarker or standalone.

-   `[identifier](#/s:11MapTilerSDK11MTTextPopupC10identifierSSvp)`
    
    Unique id of the popup.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var identifier: String { get }
    ```
    
-   `[coordinates](#/s:11MapTilerSDK11MTTextPopupC11coordinatesSo22CLLocationCoordinate2DVvp)`
    
    Position of the popup on the map.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var coordinates: CLLocationCoordinate2D { get }
    ```
    
-   `[text](#/s:11MapTilerSDK11MTTextPopupC4textSSvp)`
    
    Text content of the popup.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var text: String { get }
    ```
    
-   `[offset](#/s:11MapTilerSDK11MTTextPopupC6offsetSdSgvp)`
    
    The pixel distance from the popup’s coordinates.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var offset: Double? { get }
    ```
    
-   `[anchor](#/s:11MapTilerSDK11MTTextPopupC6anchorAA8MTAnchorOSgvp)`
    
    Anchor of the popup.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var anchor: MTAnchor? { get }
    ```
    
-   `[maxWidth](#/s:11MapTilerSDK11MTTextPopupC8maxWidthSdSgvp)`
    
    The maximum width of the popup in pixels.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var maxWidth: Double? { get }
    ```
    
-   `[isSubpixelPositioningEnabled](#/s:11MapTilerSDK11MTTextPopupC28isSubpixelPositioningEnabledSbvp)`
    
    Boolean value indicating whether the popup uses subpixel positioning.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var isSubpixelPositioningEnabled: Bool { get }
    ```
    
-   `[isTrackingPointer](#/s:11MapTilerSDK11MTTextPopupC17isTrackingPointerSbvp)`
    
    Boolean value indicating whether the popup is tracking the pointer.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var isTrackingPointer: Bool { get }
    ```
    
-   `[isOpen](#/s:11MapTilerSDK11MTTextPopupC6isOpenSbvp)`
    
    Boolean value indicating whether the popup is currently open on the map.
    
    #### Declaration
    
    Swift
    
    ```
    public private(set) var isOpen: Bool { get }
    ```
    
-   `[onOpen](#/s:11MapTilerSDK11MTTextPopupC6onOpenyycSgvp)`
    
    Called when the popup opens on the map.
    
    #### Declaration
    
    Swift
    
    ```
    public var onOpen: (() -> Void)?
    ```
    
-   `[onClose](#/s:11MapTilerSDK11MTTextPopupC7onCloseyycSgvp)`
    
    Called when the popup closes from the map.
    
    #### Declaration
    
    Swift
    
    ```
    public var onClose: (() -> Void)?
    ```
    
-   `[init(coordinates:text:offset:maxWidth:anchor:)](#/s:11MapTilerSDK11MTTextPopupC11coordinates4text6offset8maxWidth6anchorACSo22CLLocationCoordinate2DV_SSS2dSgAA8MTAnchorOSgtcfc)`
    
    Initializes the popup with the specified position and text.
    
    #### Declaration
    
    Swift
    
    ```
    public init(
        coordinates: CLLocationCoordinate2D,
        text: String,
        offset: Double = 0.0,
        maxWidth: Double? = nil,
        anchor: MTAnchor? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>coordinates</em></code></td><td><div><p>Position of the popup.</p></div></td></tr><tr><td><code><em>text</em></code></td><td><div><p>Text content of the popup.</p></div></td></tr></tbody></table>
    
-   `[setCoordinates(_:in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC14setCoordinates_2in17completionHandlerySo22CLLocationCoordinate2DV_AA9MTMapViewCys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Sets coordinates for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func setCoordinates(
        _ coordinates: CLLocationCoordinate2D,
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>coordinates</em></code></td><td><div><p>Position of the popup</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[setLngLat(_:in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC9setLngLat_2in17completionHandlerySo22CLLocationCoordinate2DV_AA9MTMapViewCys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Sets coordinates for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func setLngLat(
        _ coordinates: CLLocationCoordinate2D,
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>coordinates</em></code></td><td><div><p>Position of the popup.</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[setMaxWidth(_:in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC11setMaxWidth_2in17completionHandlerySd_AA9MTMapViewCys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Sets the maximum width of the popup in pixels.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func setMaxWidth(
        _ maxWidth: Double,
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>maxWidth</em></code></td><td><div><p>Maximum width in pixels.</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[setOffset(_:in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC9setOffset_2in17completionHandlerySd_AA9MTMapViewCys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Sets the pixel offset distance from the popup’s anchor coordinate.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func setOffset(
        _ offset: Double,
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>offset</em></code></td><td><div><p>Pixel offset applied on both axes.</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[setSubpixelPositioning(_:in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC22setSubpixelPositioning_2in17completionHandlerySb_AA9MTMapViewCys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Enables or disables subpixel positioning for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func setSubpixelPositioning(
        _ isEnabled: Bool,
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>isEnabled</em></code></td><td><div><p>Boolean indicating whether subpixel positioning is enabled.</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[setText(_:in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC7setText_2in17completionHandlerySS_AA9MTMapViewCys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Updates the popup text content.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func setText(
        _ text: String,
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>text</em></code></td><td><div><p>Text content of the popup.</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[setAnchor(_:in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC9setAnchor_2in17completionHandleryAA8MTAnchorOSg_AA9MTMapViewCys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Sets anchor for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func setAnchor(
        _ anchor: MTAnchor?,
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>anchor</em></code></td><td><div><p>Anchor of the popup.</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[trackPointer(in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC12trackPointer2in17completionHandleryAA9MTMapViewC_ys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Enables tracking the pointer position for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func trackPointer(
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[open(in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC4open2in17completionHandleryAA9MTMapViewC_ys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Opens the popup on the provided map view.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func open(
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to add the popup to.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[close(in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC5close2in17completionHandleryAA9MTMapViewC_ys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Closes the popup on the provided map view.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func close(
        in mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to remove the popup from.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[remove(from:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC6remove4from17completionHandleryAA9MTMapViewC_ys6ResultOyytAA7MTErrorOGcSgtF)`
    
    Removes the popup from the map.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func remove(
        from mapView: MTMapView,
        completionHandler: ((Result<Void, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to remove the popup from.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[getCoordinates(in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC14getCoordinates2in17completionHandleryAA9MTMapViewC_ys6ResultOySo22CLLocationCoordinate2DVAA7MTErrorOGcSgtF)`
    
    Returns current coordinates of the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func getCoordinates(
        in mapView: MTMapView,
        completionHandler: ((Result<CLLocationCoordinate2D, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to query.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[getAnchor(in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC9getAnchor2in17completionHandleryAA9MTMapViewC_ys6ResultOyAA8MTAnchorOSgAA7MTErrorOGcSgtF)`
    
    Returns current anchor of the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func getAnchor(
        in mapView: MTMapView,
        completionHandler: ((Result<MTAnchor?, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to query.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[isOpen(in:completionHandler:)](#/s:11MapTilerSDK11MTTextPopupC6isOpen2in17completionHandleryAA9MTMapViewC_ys6ResultOySbAA7MTErrorOGcSgtF)`
    
    Returns a Boolean value indicating whether the popup is currently open.
    
    #### Declaration
    
    Swift
    
    ```
    @available(iOS, deprecated: 16.0, message: "Prefer the async version for modern concurrency handling")
    @MainActor
    public func isOpen(
        in mapView: MTMapView,
        completionHandler: ((Result<Bool, MTError>) -> Void)? = nil
    )
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to query.</p></div></td></tr><tr><td><code><em>completionHandler</em></code></td><td><div><p>A handler block to execute when function finishes.</p></div></td></tr></tbody></table>
    
-   `[setCoordinates(_:in:)](#/s:11MapTilerSDK11MTTextPopupC14setCoordinates_2inySo22CLLocationCoordinate2DV_AA9MTMapViewCtYaF)` Asynchronous
    
    Sets coordinates for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func setCoordinates(_ coordinates: CLLocationCoordinate2D, in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>coordinates</em></code></td><td><div><p>Position of the popup.</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr></tbody></table>
    
-   `[setLngLat(_:in:)](#/s:11MapTilerSDK11MTTextPopupC9setLngLat_2inySo22CLLocationCoordinate2DV_AA9MTMapViewCtYaF)` Asynchronous
    
    Sets coordinates for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func setLngLat(_ coordinates: CLLocationCoordinate2D, in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr></tbody></table>
    
-   `[setMaxWidth(_:in:)](#/s:11MapTilerSDK11MTTextPopupC11setMaxWidth_2inySd_AA9MTMapViewCtYaF)` Asynchronous
    
    Sets the maximum width of the popup in pixels.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func setMaxWidth(_ maxWidth: Double, in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr></tbody></table>
    
-   `[setOffset(_:in:)](#/s:11MapTilerSDK11MTTextPopupC9setOffset_2inySd_AA9MTMapViewCtYaF)` Asynchronous
    
    Sets the pixel offset distance from the popup’s anchor coordinate.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func setOffset(_ offset: Double, in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr></tbody></table>
    
-   `[setSubpixelPositioning(_:in:)](#/s:11MapTilerSDK11MTTextPopupC22setSubpixelPositioning_2inySb_AA9MTMapViewCtYaF)` Asynchronous
    
    Enables or disables subpixel positioning for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func setSubpixelPositioning(_ isEnabled: Bool, in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr></tbody></table>
    
-   `[setText(_:in:)](#/s:11MapTilerSDK11MTTextPopupC7setText_2inySS_AA9MTMapViewCtYaF)` Asynchronous
    
    Updates the popup text content.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func setText(_ text: String, in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr></tbody></table>
    
-   `[setAnchor(_:in:)](#/s:11MapTilerSDK11MTTextPopupC9setAnchor_2inyAA8MTAnchorOSg_AA9MTMapViewCtYaF)` Asynchronous
    
    Sets anchor for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func setAnchor(_ anchor: MTAnchor?, in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>anchor</em></code></td><td><div><p>Anchor of the popup.</p></div></td></tr><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr></tbody></table>
    
-   `[trackPointer(in:)](#/s:11MapTilerSDK11MTTextPopupC12trackPointer2inyAA9MTMapViewC_tYaF)` Asynchronous
    
    Enables tracking the pointer position for the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func trackPointer(in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to apply to.</p></div></td></tr></tbody></table>
    
-   `[open(in:)](#/s:11MapTilerSDK11MTTextPopupC4open2inyAA9MTMapViewC_tYaF)` Asynchronous
    
    Opens the popup on the provided map view.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func open(in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to add the popup to.</p></div></td></tr></tbody></table>
    
-   `[close(in:)](#/s:11MapTilerSDK11MTTextPopupC5close2inyAA9MTMapViewC_tYaF)` Asynchronous
    
    Closes the popup on the provided map view.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func close(in mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to remove the popup from.</p></div></td></tr></tbody></table>
    
-   `[remove(from:)](#/s:11MapTilerSDK11MTTextPopupC6remove4fromyAA9MTMapViewC_tYaF)` Asynchronous
    
    Removes the popup from the map.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func remove(from mapView: MTMapView) async
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to remove the popup from.</p></div></td></tr></tbody></table>
    
-   `[getCoordinates(in:)](#/s:11MapTilerSDK11MTTextPopupC14getCoordinates2inSo22CLLocationCoordinate2DVAA9MTMapViewC_tYaF)` Asynchronous
    
    Returns current coordinates of the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func getCoordinates(in mapView: MTMapView) async -> CLLocationCoordinate2D
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to query.</p></div></td></tr></tbody></table>
    
-   `[getAnchor(in:)](#/s:11MapTilerSDK11MTTextPopupC9getAnchor2inAA8MTAnchorOSgAA9MTMapViewC_tYaF)` Asynchronous
    
    Returns current anchor of the popup.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func getAnchor(in mapView: MTMapView) async -> MTAnchor?
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to query.</p></div></td></tr></tbody></table>
    
-   `[isOpen(in:)](#/s:11MapTilerSDK11MTTextPopupC6isOpen2inSbAA9MTMapViewC_tYaF)` Asynchronous
    
    Returns a Boolean value indicating whether the popup is currently open.
    
    #### Declaration
    
    Swift
    
    ```
    @MainActor
    public func isOpen(in mapView: MTMapView) async -> Bool
    ```
    
    #### Parameters
    
    <table class="graybox"><tbody><tr><td><code><em>mapView</em></code></td><td><div><p>Map view to query.</p></div></td></tr></tbody></table>
    
-   `[addToMap(_:)](#/s:11MapTilerSDK11MTTextPopupC05addToA0yyAA9MTMapViewCF)`
    
    Adds popup to map DSL style.
    
    Prefer `[addTextPopup(_:)](https://docs.maptiler.com/mobile-sdk/ios/api/Classes/MTMapView/#/s:11MapTilerSDK9MTMapViewC12addTextPopupyyAA06MTTextH0CYaF)` instead.
    
    #### Declaration
    
    Swift
    
    ```
    public func addToMap(_ mapView: MTMapView)
    ```
