I’ve been playing with Xamarin.Forms for the last few days. While it is pretty impressive that you can build an iPhone, Android and WinPhone app from the same codebase, I get a feeling that WinPhone is a second class citizen. One of the first things that bugged me is that you do not get the standard WinPhone page titles “for free”. Here is some XAML to fix that:
<!-- WinPhone page title --> <StackLayout> <StackLayout.IsVisible> <OnPlatform x:TypeArguments="x:Boolean"> <OnPlatform.iOS>false</OnPlatform.iOS> <OnPlatform.Android>false</OnPlatform.Android> <OnPlatform.WinPhone>true</OnPlatform.WinPhone> </OnPlatform> </StackLayout.IsVisible> <Label Text="APPLICATION TITLE" TranslationX="4" TranslationY="4" /> <Label Text="page title" Font="64" TranslationY="-12"/> </StackLayout>