background preloader

MapKit

Facebook Twitter

Up and running with MapKit - a free Hacking with Swift tutorial. Select your project in the project navigator – it's the top thing, with a blue icon next to it.

Up and running with MapKit - a free Hacking with Swift tutorial

In the center of the Xcode window you'll see lots of options, and this is usually where you limit the orientation of your app. But this time, I want you to go up to the list of tabs and change from General to Capabilities, because we're going to ask that our app be allowed to use maps. There are lots of capabilities you can request on this screen, but the one we're looking for right now is called simply "Maps". Find it, then change its switch from Off to On. You should be able to try running your app again, because this time will work. In the picture below you can see the Entitlements tab showing map support being enabled. You'll see a default map view, and you can pan around, zoom in and out, and so on. Using the assistant editor, please create an outlet for your map view called mapView.

Maps for Developers. MapKit Tutorial: Getting Started. Plot Honolulu public artwork data using MapKit!

MapKit Tutorial: Getting Started

Code update September 22, 2016: Updated the final project to Swift 3. Update April 10, 2015: Updated for Xcode 6.3 / Swift 1.2. Update notes: Audrey Tam updated this tutorial to Swift and iOS 8. Original post by Ray Wenderlich. Ray’s original tutorial queried and retrieved data from the Baltimore web service but the code broke when the web service made minor changes, so this update uses a static JSON file downloaded from the Honolulu data portal. MapKit is a really neat API available on iOS devices that makes it easy to display maps, jump to coordinates, plot locations, and even draw routes and other shapes on top.

This update uses public artworks data from Honolulu, where I was born and raised. In this tutorial, you’re going to make an app that zooms into a location in Honolulu, and you’ll plot one of the artworks on the map. Blog. Tutoriel iOs : Utilisation de MapKit Pour ce premier tutorial nous allons nous intéresser à l’utilisation de MapKit.

Blog

Cette Api permet d’afficher facilement une carte, des annotations et des itinéraires. C’est un élément qui peu revenir assez régulièrement lorsque vous réalisez une application iPhone. Dans ce tutorial nous allons afficher sur une carte les stations RATP que nous avons récupérées dans un fichier CSV open data. Pour commencer, affichage d’une carte.

Dans Xcode créer un nouveau projet de type SingleViewApplication. Cliquer sur MainStoryboard.storyboard pour afficher l’interface builder. Depuis la bibliothèque d’objets, sélectionnez MapView et glissez le sur la vue. Cliquez sur la MapView que vous venez d’ajouter, puis sélectionner le quatrième onglet de l’inspector et ajoutez “Show User Location”. Tracing routes with MapKit. Presenting a map to the user is a common feature of mobile apps.

Tracing routes with MapKit

And very often this feature comes with an additional requirement: to trace the route from the current user location to some arbitrary destination. The thing is, most apps accomplish this last requirement by adding a button to the right navigation item that opens up google maps on the browser. But usually this is not the best user experience. Most developers don’t know this (and I was one of them not too long ago), but it is possible to use the MKMapView to easily render paths between to locations. Apple MapKit Actually Hiding Something Insanely Great. Chalk up another point for Apple in the ongoing battle for iOS mapping SDK dominance.

Apple MapKit Actually Hiding Something Insanely Great

Via NSHipster, Mattt Thompson writes: In all of the hubbub of torch burning and pitchfork raising, you may have completely missed a slew of additions to MapKit in iOS 6.1. Namely: MKLocalSearch..., which provides a simple way to find local points of interest. Because of its no-hassle web services integration and tight integration with MapKit, any location-based app would do well to take advantage of it. With MKLocalSearch, users can search within a geographically defined area of maps displayed within your app. Incredibly, it’s free! Perhaps the most counter-intuitive thing about MapKit in iOS 6 is that it's still widely used.

There might be new competition from Facebook, which announced yesterday that it was hard at work on natural-language Graph Search. Integrating Maps into iOS 8 Applications using MKMapItem and Swift. From Techotopia If there is one single fact about Apple that we can state with any degree of certainty, it is that the company is fanatical about retaining control of its own destiny.

Integrating Maps into iOS 8 Applications using MKMapItem and Swift

One glaring omission in this overriding corporate strategy has been the reliance on a competitor (in the form of Google) for mapping data in iOS. Using Maps (Swift in Xcode) Maps URL Scheme - Google Maps SDK for iOS. You can use the Google Maps URL scheme to launch the Google Maps app for iOS and perform searches, get direction requests, and display map views.

Maps URL Scheme - Google Maps SDK for iOS

When you launch Google Maps your bundle identifier is automatically sent as part of the request. Overview A URL scheme allows you to launch a native iOS application from another iOS app or a web application. You can set options in the URL that will be passed to the launched application. The Google Maps app for iOS supports the following URL schemes: and comgooglemaps-x- - These schemes allow you to launch the Google Maps app for iOS and perform one of several actions:Display a map at a specified location and zoom level.Search for locations or places, and display them on a map.Request directions from one location to another.

Launch the Google Maps app for iOS and perform a specific function To launch the Google Maps app for iOS and optionally perform one of the supported functions, use a URL scheme of the following form: or: Exploring-Google-Maps-For-iOS-FULL.pdf. MKDirections Tutorial - DevFright. Iphone - MapKit - Make route line follow streets when map zoomed in.