5

I want to display text in multiple lines in the pin's label when it is clicked, but when I have a very long text to be displayed in Address it shows me only a part of it and rest of it remains hidden eg: 'Street 12A...'. How can I make the label to display the whole text on clicking it and if possible then in multiple lines using Xamarin.Forms.Maps.

 var pin = new Pin
{
    Type = PinType.Place,
    Position = position,
    Label = "Label Name",

    Address = "some text..........."
};
map.Pins.Add(pin);
A. Sinha
  • 2,666
  • 3
  • 26
  • 45

1 Answers1

1

You would be to create a custom render for map on each platform to replace the standard iOS pin annotations, Android pin markers, etc...

Xamarin has a full guide for creating custom pin annotations/markers and thus you can create the UI elements you need to display your full text.

enter image description here

Ref: https://developer.xamarin.com/guides/xamarin-forms/custom-renderer/map/

SushiHangover
  • 73,120
  • 10
  • 106
  • 165