Deep Dive into the Quick Start of Xamarin.Forms

I have created Phoneword App of Xamarin.Forms by devotedly following the instruction of Xamarin.Forms Quickstart, and the Apps for both of iOS and Android are built simultaneously.

Some points that I learned from the Deep Dive of the Phoneword (Xamarin.Forms) are shown below:

  • Three new projects (Phoneword, Phoneword_iOS, Phoneword_Droid) are created in a new Phoneword Solution. Phoneword project has shared code and UI, and are called Portable Class Library (PCL).
  • Reference, Packages (NuGet Package?), Properties etc. are also created in the solution.
  • By adding a new ContentPage XAML as the name of MainPage, two new files, MainPage.xaml and MainPage.xaml.cs are created, and UI functions are programmed in the files.
  • In the Phoneword solution, UI architecture are:
    • Pages: ContentPage
    • Layout: StackLayout
    • Views: Label, Entry, Button
    • Cells: (not used in the Phoneword solution)
  • No need to change App.xaml. MainPage are called in App.xaml.cs, and the first page of this App are shown on display. The architecture of the Phoneword solution are App ? MainPage ? PhoneTranslator.
  • OnTranslator method responds the "Translate" button click.
  • Other some technichs used in Phoneword:
    • Enable/Disable Button (CallButton.IsEnable)
    • Telephone call alert (Display.Alert)
    • Use OpenURL to launch the system phone call of iPhone
    • To correctly display each page on different platforms, use different Padding value

コメント

このブログの人気の投稿

Get the Color Code from an Image Pixel

PCL Storage (1)

Prolog Interpreter