Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Arrow up icon
GO TO TOP
Cross-platform UI Development with Xamarin.Forms

You're reading from   Cross-platform UI Development with Xamarin.Forms

Arrow left icon
Product type Paperback
Published in Aug 2015
Publisher
ISBN-13 9781784391195
Length 330 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Paul Johnson Paul Johnson
Author Profile Icon Paul Johnson
Paul Johnson
Arrow right icon
View More author details
Toc

Table of Contents (22) Chapters Close

Cross-platform UI Development with Xamarin.Forms
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
1. In the Beginning… 2. Let's Get the Party Started FREE CHAPTER 3. Making It Look Pretty and Logging In 4. Making Your Application Portable 5. Data, Generics, and Making Sense of Information 6. A View to a Kill 7. Connect Me to Your Other Services 8. What a Bind! 9. Addressing the Issue 10. This is the World Calling… 11. A Portable Settings Class 12. Xamarin Forms Labs 13. Social Media into the Mix 14. Bringing It All Together Index

Index

A

  • abstraction layer, standard UI login
    • about / Abstract this, abstract that
    • uniform size, ensuring / When size really does matter
    • device, setting / Let the device help you
    • login button / That button, though…
  • address book
    • incorporating, in messenger application / Addressing issues
    • address storage class, creating / The address storage class
    • internal address book, accessing / Accessing the internal address book
    • Xamarin Mobile component, using / Using the Xamarin mobile component
    • viewing / Viewing the address book
    • WeakReference / What is WeakReference?
    • BindingContext, using / Using BindingContext
  • Aggregate method / Aggregate
  • All method / All
  • Android
    • Xamarin Forms, instantiating within / Android
    • WebViews / Displaying a web page from a file – Android
    • maps, setting up / Setting up on Android
    • setting up, for push notifications / Setting up Android for push notifications
    • geolocation events, adding to / Adding the geolocation events to Android
    • about / Let's make a start – Android
    • connectivity code, setting up / Setting up your Android code
    • broadcast receiver, creating / Broadcast whatcha-ma-call-it?
    • interface, setting up / Setting up the interface
    • connectivity, listening on Windows Phone / Listening for connectivity on Windows Phone
    • notification, adding / Adding a notification
  • Android custom renderer
    • about / An Android custom renderer
  • Android native platform storage
    • about / The Android native platform storage
  • Android push notifications
    • setting up, in app / Setting up the Android push notifications in the app
    • additional permissions / Additional permissions
    • broadcast receiver / The broadcast receiver
  • Android service
    • about / The Android service
    • register action / The Register action
    • unregister action / The Unregister action
    • return value, using / Listening for a return
    • receive / Receive
    • actions, handling in code / Handling the actions in code
  • Android UI
    • about / Back to basics, Uncle Tommy, there's more at the door…
  • Any method / Any
  • Apple developer console
    • URL / Creating your iOS profile
  • application
    • planning / Application planning
    • design templates / The design templates
    • shopping list / A messenger – a shopping list of features
    • messenger application UI, list / A messenger – a shopping list of features
    • speech to text and text to speech / Speech to text and text to speech
    • other considerations / Other considerations
    • cross platform considerations / Cross-platform considerations
    • internal data structure / The internal data structure
    • backend storage / Backend storage
    • push notifications, setting up for Android / Setting up for Android
    • push notifications, setting up for iOS / Setting up for iOS
    • iOS profile, creating / Creating your iOS profile
    • push notifications, creating / Creating and configuring for push notifications
    • push notifications, configuring / Creating and configuring for push notifications
    • certificate, exporting for Azure / Exporting the certificate for Azure
    • packages, adding / Adding packages to your application
  • As a loop method / As a loop
  • Azure
    • setting up / Setting up Azure
    • signing up / Signing up
    • data, adding / Adding data
    • storage, adding / Adding storage
    • application, setting up / Setting up the application
    • adding / Adding Azure
    • login API, adding / Adding the Azure login API
    • same code, signing up with / Sign up and log in with the same code
    • same code, logging up with / Sign up and log in with the same code
    • automatic login / The automatic login
    • required data, for sign up / The required data to sign up
    • data organization / The data organization
    • base settings, wrapping up / Wrapping up the login and base settings
    • login, wrapping up / Wrapping up the login and base settings
  • Azure storage
    • about / The Azure Storage
    • data, storing / Storing data
    • setting / Setting and storing

B

  • BasicUI
    • about / Introducing the standard UI login experience
  • BindingContext
    • using / Using BindingContext
    • versus WeakReference / Weak reference versus BindingContext
  • binding project
    • creating / A simple binding project
    • list of strings, binding / Let's step it up a notch
    • List<string> container, creating / LINQ, anyone?
    • data, adding to List / How to perform the binding
    • message reply, checking / Can we do anything else with the bindings?
    • IValueConverter, using / IValueConverter
    • horizontal position, setting / Setting the horizontal position
    • trigger, using / Any other alternatives?
    • background, implementing / To the next level, we will go!
    • background, implementing for Android / Android
    • extension method, creating / Extension methods
    • text width, obtaining / The text width and height
    • text height, obtaining / The text width and height
    • text typeface, considering / Taking into account the text typeface
    • drawable image, converting to bitmap image / Converting a drawable image to a bitmap image
    • new message, adding to list / Adding to your list
    • message addition, simulating / Simulating to add a message
  • BLOB (Binary Large OBject) / The message

C

  • cells
    • about / Cells
    • EntryCell / Cells
    • SwitchCell / Cells
    • TextCell / Cells
    • ImageCell / Cells
  • checkboxes, Xamarin Forms labs
    • about / Checkboxes
    • iOS / iOS
    • Android / Android
    • Windows Phone / Windows Phone
    • in PCL / In the PCL
  • complex UI example, custom renderer
    • about / A complex UI example
    • Android custom renderer / An Android custom renderer
    • iOS custom renderer / An iOS custom renderer
  • contacts, messenger application
    • about / Contacts
    • social media, using / Using social media
    • direct invitation / The direct invitation
  • cross-platform app
    • creating / Touch-a-touch-a-touch me
  • cross-platform settings system
    • about / Constructing a persistent and cross-platform settings system
    • initial data, creating / Creating the initial data
    • Android IUserSettings interface, creating / Creating the implementation of the IUserSettings interface – Android, Saving preferences
    • preferences, saving / Saving preferences
    • preferences, loading / Loading preferences
    • iOS IUserSettings interface, creating / Creating the implementation of the IUserSettings interface – iOS
    • Windows Phone IUserSettings interface, creating / Creating the implementation of the IUserSettings interface – Windows Phone
  • cross platform, considerations
    • about / Cross-platform considerations
    • language considerations / Language considerations
    • online translation services / Online translation services
  • custom renderer
    • about / The custom renderer
    • creating / Creating a custom renderer
    • customizing, for Android / Customizing for Android
    • implementing, on iOS / Implementing on iOS
    • complex UI example / A complex UI example

D

  • data
    • finding, with LINQ / Finding data with LINQ
  • data, ordering
    • about / Ordering data
    • OrderBy / OrderBy
    • t=>t? / t=>t?
    • OrderByDescending / OrderByDescending
  • database helper class
    • about / The database helper class
    • generic types / Generic types within the helper class
    • data classes, interfacing with / Interfacing with the data classes
    • creating / Creating the helper class
  • database helper class, creating
    • about / Creating the helper class
    • database connection / The database connection
    • database, setting up / Setting up the database
    • data, adding to SQLite database / Data, data everywhere…
    • code / The code bit
    • Func delegate / Getting funky with Func
    • data back out, getting / Getting data back out
  • data binding
    • history / A bit of a history lesson
    • in mobile arena / Binding the mobile arena
  • defacto method
    • about / Adding social media to your app
  • Dependency Injection (DI)
    • about / Dependency injection
    • Inversion of Control (IoC) / Inversion of Control?
    • implementing / Implementing DI
    / If you don't have access to parts of libraries, such as hardware access, how can they be implemented?, The old code
  • design templates
    • URL / The design templates

E

  • error code
    • ACCOUNT_MISSING / Listening for a return
    • AUTHENTICATION_FAILED / Listening for a return
    • INVALID_PARAMETERS / Listening for a return
    • INVALID_SENDER / Listening for a return
    • PHONE_REGISTRATION_ERROR / Listening for a return
    • SERVICE_NOT_AVAILABLE / Listening for a return
  • event system
    • setting up / Setting up the event system and interface

F

  • First method / First and FirstOrDefault
  • FirstOrDefault method / First and FirstOrDefault
  • Func delegate
    • about / Getting funky with Func

G

  • Garbage Collection (GC)
    • about / What is WeakReference?
  • Garbage Collector (GC) / .NET generics
  • geolocation events
    • adding, to code / Adding the geolocation events to the code
    • adding, to Android / Adding the geolocation events to Android
    • adding, to iOS / Adding the geolocation events to iOS
  • gestures
    • about / Gestures, maps, and WebViews, Gestures
    • gesture recognizer, adding / Adding a gesture recognizer
  • GET
    • and POST / POST and GET
  • GetSet class / The GetSet class
  • GPS
    • using / Using GPS and push notifications
    • about / What about GPS and maps?
    • defining / Why bother?
    • used, in PCL / In the PCL
    • Xamarin Forms map, creating / Creating the Xamarin Forms map
    • map, adding / Adding the map
    • map types / Map types and pins
    • pins / Map types and pins
  • GUID (Global Unique Identifier) / The required data to sign up
  • GUID math
    • URL / The data organization
  • GUI package creator
    • URL / Creating the library

I

  • Inline method / Inline
  • interface
    • setting up / Setting up the event system and interface
  • internal address book
    • accessing / Accessing the internal address book
    • native implementation / The native implementation
    • native implementation, for Android / The native implementation for Android
    • native implementation, for iOS / The native implementation for iOS
  • internal data structure
    • about / The internal data structure
    • messenger data structure / The messenger data structure
    • message / The message
    • contacts / Contacts
  • Inversion of Control (IoC)
    • about / Inversion of Control?
    / If you don't have access to parts of libraries, such as hardware access, how can they be implemented?
  • iOS
    • Xamarin Forms, instantiating within / iOS
    • WebViews / Displaying a web page from a file – iOS
    • maps, setting up / Setting up on iOS
    • geolocation events, adding to / Adding the geolocation events to iOS
    • about / iOS
    • setting up / Setting up iOS
  • iOS custom renderer
    • about / An iOS custom renderer
  • iOS native platform storage
    • about / The iOS native platform storage
  • iOS profile
    • creating / Creating your iOS profile
  • iOS provisioning profile
    • setting up / Setting up the iOS provisioning profile

J

  • JSON (JavaScript Object Notation)
    • about / So far, it's easy
    • transferring / Transferring JSON to something we can use
  • Json.NET
    • using / Using Json.NET
    • about / Which is better?
  • JSON2CSharp
    • about / It's a bit messy, isn't it?

L

  • Last method / Last and LastOrDefault
  • LastOrDefault method / Last and LastOrDefault
  • layouts
    • about / Layouts
    • ContentLayout / Layouts
    • Frame / Layouts
    • ScrollView / Layouts
    • AbsoluteLayout / Layouts
    • Grid / Layouts
    • RelativeLayout / Layouts
    • StackLayout / Layouts
  • library
    • creating / Creating the library
  • linked lists
    • about / The generic methods, Modern linked lists
  • LINQ
    • about / LINQ me up baby – yeah!, Getting Linq'd
    • code / Jumping into the code
    • errors / Wait, hold on, that's wrong!
    • data, finding with / Finding data with LINQ
    • mutables / Filters and mutables within LINQ
    • filters / Filters and mutables within LINQ
    • data, skipping / Skipping and taking data
    • data, taking / Skipping and taking data
    • Skip / Skip and SkipWhile
    • SkipWhile / Skip and SkipWhile
    • Take / Take and TakeWhile
    • TakeWhile / Take and TakeWhile
    • methods / Other LINQ methods
  • LINQ, methods
    • Where method / Where
    • First / First and FirstOrDefault
    • FirstOrDefault / First and FirstOrDefault
    • SingleOrDefault / Single and SingleOrDefault
    • Single / Single and SingleOrDefault
    • Select / Select
    • As a loop / As a loop
    • Inline / Inline
    • SelectMany / SelectMany
    • Last / Last and LastOrDefault
    • LastOrDefault / Last and LastOrDefault
    • AsEnumerable / Filters and mutables within LINQ
    • AsParallel / Filters and mutables within LINQ
    • Cast / Filters and mutables within LINQ
    • Concat / Filters and mutables within LINQ
    • Contains / Filters and mutables within LINQ
    • DefaultIfEmpty / Filters and mutables within LINQ
    • Distinct / Filters and mutables within LINQ
    • ElementAt / Filters and mutables within LINQ
    • ElementAtOrDefault / Filters and mutables within LINQ
    • GroupBy / Filters and mutables within LINQ
    • GroupJoin / Filters and mutables within LINQ
    • Intersect / Filters and mutables within LINQ
    • Join / Filters and mutables within LINQ
    • OfType / Filters and mutables within LINQ
    • Reverse / Filters and mutables within LINQ
    • Union / Filters and mutables within LINQ
    • Zip / Filters and mutables within LINQ
    • about / Other LINQ methods
    • Aggregate / Aggregate
    • All / All
    • Any / Any
    • SequenceEqual / SequenceEqual
  • listener
    • deregistering / Deregistering the listener
  • login screen, standard UI
    • implementing / Implementing a login screen
    • UI positioning / UI positioning
    • enhancing / Making it look good
    • enhancing, EventTrigger, used / Using EventTrigger
    • trigger enhancements / Further trigger enhancements
  • long weak reference
    • versus short weak reference / What is WeakReference?

M

  • maps
    • about / Gestures, maps, and WebViews, Maps, What about GPS and maps?
    • setting up, on iOS / Setting up on iOS
    • setting up, on Android / Setting up on Android
    • setting up, on Windows Phone / Setting up on Windows Phone
    • adding / Adding a map
    • zoom facility, adding / Adding a zoom facility to a map
    • pins, adding / Sticking a pin in it
  • messenger application
    • address book, incorporating / Addressing issues
    • about / The messenger application
    • messages, displaying / What about displaying the messages?
    • message composition / The message composition, The message composition
    • speech to text / Speech to text
    • lazy image loading / Lazy image loading
    • contacts / Contacts
    • attachments, storing / Displaying and storing the attachments
    • attachments, displaying / Displaying and storing the attachments
    • file streams, used for saving / Using file streams to save and load
    • file streams, used for loading / Using file streams to save and load
  • messenger application UI
    • about / A messenger – a shopping list of features
  • Microsoft 101 LINQ examples
    • URL / Summary
  • mobile arena
    • data binding / Binding the mobile arena
    • binding project, creating / A simple binding project

N

  • .NET generics
    • about / .NET generics
    • class usage, restrictions / Restrictions on using a generic class
    • methods / The generic methods
    • linked lists / Modern linked lists
  • native platform storage
    • about / The native platform storage
    • iOS native platform storage / The iOS native platform storage
    • Android native platform storage / The Android native platform storage
    • Windows Phone native platform storage / The Windows Phone native platform storage
  • network connection
    • checking / Connect me up, Scotty
  • NuGet
    • Xamarin Mobile component, installing / Installing through NuGet
    • Xamarin.Auth, installing / Installing Xamarin.Auth from NuGet

O

  • OAuth
    • about / The difference between OAuth and OAuth2
    • versus OAuth2 / The difference between OAuth and OAuth2
    • implementing / Implementing OAuth
    • Xamarin.Auth, installing from NuGet / Installing Xamarin.Auth from NuGet
  • OAuth1
    • for Twitter / OAuth1 for Twitter
    • interface, creating / Let's jump on
    • app, authenticating / Authentication in the application
  • OAuth2
    • versus OAuth / The difference between OAuth and OAuth2
    • using / Using OAuth2

P

  • pages
    • about / Pages
    • ContentPage / Pages
    • MasterDetailPage / Pages
    • NavigationPage / Pages
    • TabbedPage / Pages
    • CarouselPage / Pages
  • parameterless query / t=>t?
  • PCL
    • about / PCLs – the pros and cons, Let's make a start, PCL
    • URL / PCLs – the pros and cons
    • pros / If you don't have the full .NET base, what is the point of having a PCL?, If you don't have access to parts of libraries, such as hardware access, how can they be implemented?, Is there a processor speed hit?
    • cons / If you don't have the full .NET base, what is the point of having a PCL?, If you don't have access to parts of libraries, such as hardware access, how can they be implemented?, Is there a processor speed hit?
    • library, writing / Writing your PCL library
    • other options / Other options for PCL
    • magical type T / The magical type T, The devil is in the detail
  • PCL library, writing
    • about / Writing your PCL library
    • code, examining / Examining the code
    • old code / The old code
    • new code / The new code
  • platform-specific considerations
    • about / Platform-specific considerations
  • Portable Class Library (PCL)
    • about / What is Xamarin Forms?
  • POST
    • and GET / POST and GET
  • Primary Key / The internal data structure
  • push notifications
    • using / Using GPS and push notifications
    • setting up, in app / Setting up push notifications in the app
    • Android, setting up for / Setting up Android for push notifications
    • messages, handling / Handling the messages
  • push notifications
    • setting up, for Android / Setting up for Android
    • setting up, for iOS / Setting up for iOS
    • creating / Creating and configuring for push notifications
    • configuring / Creating and configuring for push notifications

R

  • Reachability.cs class
    • URL / Setting up iOS
  • REST
    • about / Let's take a REST

S

  • SBase / Application planning
  • SelectMany method / SelectMany
  • Select method / Select
  • SequenceEqual method / SequenceEqual
  • serializer class / The serializer class
  • Shared Code Library (SCL) / Other options for PCL
  • short weak reference
    • versus long weak reference / What is WeakReference?
  • Single method / Single and SingleOrDefault
  • SingleOrDefault method / Single and SingleOrDefault
  • Skip method / Skip and SkipWhile
  • SkipWhile method / Skip and SkipWhile
  • social media
    • adding, to app / Adding social media to your app
    • OAuth / The difference between OAuth and OAuth2
    • OAuth2 / The difference between OAuth and OAuth2
  • SQLite solution
    • about / The SQLite solution
  • standard UI login
    • about / Introducing the standard UI login experience
    • abstraction layer / Abstract this, abstract that
    • custom renderer / The custom renderer
    • login screen, implementing / Implementing a login screen
  • Strong Reference
    • about / What is WeakReference?

T

  • tab page
    • about / Knowing me, knowing you
    • code / Start all over
    • creating, with Xamarin forms / Little boxes made of ticky-tacky
    • issues, removing / Can we fix it? Yes we can!
    • view / Now you see me, now you don't
    • PCL / Problem 1 – talking with the PCL
    • Android approach / Problem 2 – the Android approach
    • iOS approach / Problem 3 – the iOS approach
    • Windows Phone / Problem 4 – Windows Phone
    • issues / Let's see what's left
  • Take method / Take and TakeWhile
  • TakeWhile method / Take and TakeWhile
  • Time of Death app
    • about / Wanted… dead or alive
    • URL / Wanted… dead or alive
  • ToArray / ToList, ToArray, ToDictionary, and ToLookup
  • ToDictionary / ToList, ToArray, ToDictionary, and ToLookup
  • ToList / ToList, ToArray, ToDictionary, and ToLookup
  • ToLookup / ToList, ToArray, ToDictionary, and ToLookup
  • triggers
    • about / Making it look good
  • Twitter
    • OAuth1 / OAuth1 for Twitter
    • URL / OAuth1 for Twitter

U

  • UI
    • customizing / Customizing the UI
    • about / The general UI considerations
    • considerations / What have we currently got?
    • generating / Generating the UI
  • undefined behavior / A history lesson
  • UserData class / The UserData class
  • user interface
    • making unresponsive / Two caveats to be aware of
    • updating / Updating the UI very often
    • about / The user interface
  • UUID-Universal Unique IDentifier) / The required data to sign up

V

  • views
    • about / Views
    • ActivityIndicator / Views
    • BoxView / Views
    • Button / Views
    • DatePicker / Views
    • Editor / Views
    • Entry / Views
    • Image / Views
    • Label / Views
    • ListView / Views
    • OpenGLView / Views
    • Picker / Views
    • ProgressBar / Views
    • SearchBar / Views
    • Slider / Views
    • Stepper / Views
    • Switch / Views
    • TableView / Views
    • TimePicker / Views
    • WebView / Views

W

  • WeakReference
    • about / What is WeakReference?
    • short weak reference / What is WeakReference?
    • long weak reference / What is WeakReference?
    • versus BindingContext / Weak reference versus BindingContext
  • web service
    • about / The practicalities
  • WebViews
    • about / Gestures, maps, and WebViews, WebViews
    • webpage, displaying / Displaying a web page
    • generated webpage, displaying / Displaying a generated web page
    • webpage, displaying from file / Displaying a web page from a file
    • for iOS / Displaying a web page from a file – iOS
    • for Android / Displaying a web page from a file – Android
    • for Windows Phone / Displaying a web page from a file – Windows Phone
  • Where method / Where
  • Windows Communication Framework (WCF)
    • about / The Windows Communication Framework
    • web service, using / Using the web service
    • web reference, adding / Adding a web reference
  • Windows Phone
    • Xamarin Forms, instantiating within / Windows Phone
    • adding / Adding Windows Phone to your project
    • importing, from Mac into Visual Studio / Import from Mac into Visual Studio
    • libraries, adding / Adding the libraries
    • XAML code, modifying / Modifying the XAML code
    • WebViews / Displaying a web page from a file – Windows Phone
    • maps, setting up / Setting up on Windows Phone
    • modifications / Modifying on Windows Phone
    • about / Windows Phone
    • connectivity, listening / Listening for connectivity on Windows Phone
    • setting up / Setting up Windows Phone
  • Windows Phone native platform storage
    • about / The Windows Phone native platform storage

X

  • Xamarin.Auth
    • installing, from NuGet / Installing Xamarin.Auth from NuGet
  • Xamarin Forms
    • about / What is Xamarin Forms?, Size matters
    • pages / Pages
    • layouts / Layouts
    • views / Views
    • cells / Cells
    • working with / So, how does this all work?
    • information, storing / Storing information
    • instantiating, within app / Instantiating Xamarin Forms within an app
    • instantiating, within Android / Android
    • instantiating, within iOS / iOS
    • instantiating, within Windows Phone / Windows Phone
    • parent property / Move over Beethoven
  • Xamarin Forms labs
    • about / What is Xamarin Forms Labs?
    • installing, in project / Installing Xamarin Forms Labs in your project
    • checkboxes / Checkboxes
    • resolver / The resolver
  • Xamarin Mobile component
    • using / Using the Xamarin mobile component
    • installing, through component store / Installing through the component store
    • installing, through NuGet / Installing through NuGet
    • components, mixing with packages / Mixing components and packages
    • errors / Errors
    • about / Xamarin Mobile
  • XLabs
    • URL / The resolver
  • XML-based solution
    • about / The XML-based solution
    • GetSet class / The GetSet class
    • UserData class / The UserData class
    • serializer class / The serializer class

Y

  • yEd Graph Editor
    • URL / The design templates
lock icon The rest of the chapter is locked
arrow left Previous Section
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime