<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "MapKit",
  "identifier" : "/documentation/MapKit/MKMapRect/init(x:y:width:height:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "MapKit"
    ],
    "preciseIdentifier" : "c:@F@MKMapRectMake"
  },
  "title" : "init(x:y:width:height:)"
}
-->

# init(x:y:width:height:)

Creates a new map rectangle structure from the specified values.

```
init(x: Double, y: Double, width: Double, height: Double)
```

## Parameters

`x`

The point along the east-west axis of the map projection to use for the origin.

`y`

The point along the north-south axis of the map projection to use for the origin.

`width`

The width of the rectangle (measured using map points).

`height`

The height of the rectangle (measured using map points).

## Return Value

A map rectangle with the specified values.

## Discussion

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)