Introduction to Xamarin.Forms
-
Upload
pierce-boggan -
Category
Documents
-
view
489 -
download
0
description
Transcript of Introduction to Xamarin.Forms
Portable Class Libraries
Pierce Boggan @piercebogganDeveloper Evangelist (Intern), Xamarin pierceboggan.com
Xamarin + Xamarin.FormsXamarin.Forms
Code Sharing + 100% Native ControlsTraditional Xamarin Approach
Shared UI Code
Xamarin.Forms
Shared UI Code
Quickly and easy build native user interfaces from a single, shared C# codebase
Xamarin.Forms elements map directly to native controls and behaviors
Mix-and-match Xamarin.Forms with platform-specific APIs
What’s in the box?
• 40+ Layouts, Pages, and Controls• Build UIs in C# or XAML• Data Binding• Navigation• Animation API• Dependency Service• Custom Renderers• Messaging Center• So much more!
Pages
Content MasterDetail Navigation Tabbed Carousel
Layouts
Stack Absolute Relative Grid ContentView ScrollView Frame
Controls
ActivityIndicator
BoxView Button DatePicker Editor
Entry Image Label ListView Map
OpenGLView Picker ProgressBar SearchBar Slider
Stepper TableView TimePicker WebView EntryCell
ImageCell SwitchCell TextCell ViewCell
Controls
DEMO
Model-View-ViewModel
ModelView ViewModel
How to display information
What to displayFlow of interaction
Business LogicData objects
Events
Data Dat
a
Model-View-ViewModel
ModelView ViewModel
Xamarin.Forms Data Binding
Events
Data
Data Binding (Step 1)
Data Binding (Step 2)
Data Binding (Step 3)
Commands
• Execute a method when an action is performed, such as button click
• Parameter passing to commands
• Helps to increase code-sharing even more
Commands (Step 1)
Commands (Step 2)
DEMO
iOS APIs | 100% Coverage
Android APIs | 100% Coverage
Anything you can do in Objective-C, Swift, or Java
can be done in C# with Xamarin.
Dependency Service
• Full access to platform-specific APIs
• Access platform-specific implementations cleanly with Xamarin.Forms DependencyService
Dependency Service
Dependency Service
Dependency Service
DEMO
Wait… there’s more?
• Animation API
• Messaging Center
• Custom Controls
• Gesture Recognizers
• Xamarin.Forms.Maps
REAL-WORLD?
Resources
• API Documentation (http://developer.xamarin.com/guides/cross-platform/xamarin-forms/)
• Samples (https://github.com/xamarin/xamarin-forms-samples)
• Hanselman.Forms (https://github.com/jamesmontemagno/Hanselman.Forms)
• Xamarin.Forms Labs (https://github.com/XForms/Xamarin-Forms-Labs)
• Session Code (http://bit.ly/xamarin-forms-intro)
GET YOUR C# or F# SHIRT TODAY!
Learn more
Unrivaled Mobile Development TrainingLive unlimited mobile development training from mobile
experts, in your time-zone, on your schedule and as often as you'd
like
Key Attendees
Get Started Today: xamarin.com/download