Apple Map Zoom Level (Argument)

Discussion in 'iOS Programming' started by oo7ml, Jul 10, 2014.

  1. oo7ml macrumors 6502

    Joined:
    Jan 20, 2010
    #1
    Hi,

    I'm hoping someone here can help settle an argument i am having with a friend.

    He is saying it is not possible to control the zoom level of maps (apple) in iOS development.

    For example, when an app displays a map with a pointer / marker, it is not possible to control what level zoom the app displays the map at. I find this very hard to believe.

    Can anyone confirm this? Thanks in advance.
     
  2. dantastic macrumors 6502a

    dantastic

    Joined:
    Jan 21, 2011
    #2
    And between you noone thought of checking the documentation?
    https://developer.apple.com/library/ios/documentation/MapKit/Reference/MKMapView_Class/MKMapView/MKMapView.html

    When you initialize a map view, you should specify the initial region for that map to display. You do this by setting the region property of the map. A region is defined by a center point and a horizontal and vertical distance, referred to as the span. The span defines how much of the map at the given point should be visible and is also how you set the zoom level. Specifying a large span results in the user seeing a wide geographical area and corresponds to a low zoom level. Specifying a small span results in the user seeing a more narrow geographical area and corresponds to a higher zoom level.

    In addition to setting the span programmatically, the MKMapView class supports many standard interactions for changing the position and zoom level of the map. In particular, map views support flick and pinch gestures for scrolling around the map and zooming in and out. Support for these gestures is enabled by default but can also be disabled using the scrollEnabled and zoomEnabled properties.
     
  3. oo7ml thread starter macrumors 6502

    Joined:
    Jan 20, 2010

Share This Page