tags:

views:

15

answers:

1
MKCoordinateRegion region1; 
    region1.center.latitude = 50.366772;
    region1.center.longitude = 20.010607;
    region1.span.longitudeDelta = 0.01f;
    region1.span.latitudeDelta = 0.01f;     


    MyAnnotation *ann1 = [[MyAnnotation alloc] init];
    ann1.title = @"Text1";
    ann1.subtitle = @"Text2\n, Text3\n, Text4\n";   
    ann1.coordinate = region1.center;
    [mapView addAnnotation:ann1];

I want to show the multiple line text for subtitle in google map.If i give the \n to break the line,it display directly the \n in google map.How can i show the multilple lines?

Thanks.

A: 

The default style only supports the title and subtitle. Neither title nor subtitle can include line breaks. You cannot do this without subclassing.

To use a custom view review Apple's sample code:

http://developer.apple.com/library/ios/#samplecode/WeatherMap/Introduction/Intro.html

Nick