James Montemagno
James Montemagno

Live, Love, Bike, and Code.

Tags


James Montemagno

XAML

Xamarin.Forms Design Time Data Tips & Best Practices

One of my favorite features of building applications with XAML is the ability to use design time data to preview it inside the IDE. Recently in Xamarin.Forms 4.0 the team introduced an official pattern to specify design time properties, controls, or just about anything else. It is a really neat feature that I have been using on my live streams and in my apps. There is some really great docs that you should read through, but I will repeat the core info here. Why Design Time Data? Xamarin.Forms…

James Montemagno James Montemagno

Xamarin.Forms: How to Clip Images with Rounded Corners

I love watching trends in mobile design. Currently gradients are all the rage, but two trends that have been around for a while are rounded corners and circular images. A long time ago I created the Circle Image plugin for Xamarin.Forms that many developers know and love, but did you know that you can just use built in controls to get a circle or rounded corners? All you have to do is use a frame and set a few special properties! Let's start slow and just put a beautiful Red-shanked Douc Langur…

James Montemagno James Montemagno

Why Xamarin.Forms Embedding Matters

Last week I wrote about Xamarin.Forms Embedding, a great new feature of Xamarin.Forms, that enables developers to convert a Xamarin.Forms ContentPage into an iOS UIViewController, Android Fragment, and a UWP Page. I walked through the current setup and a real world example of adding Xamarin.Forms details pages to my Xamarin Native application which previously only had native Storyboards and Android XML pages. When I originally got this setup and working I was blown away by this feature and it is…

James Montemagno James Montemagno

Important OnPlatform Changes in Xamarin.Forms

Last week I blogged about the important changes to Device.OS in the latest version of Xamarin.Forms. Well, I am back with some other changes from that same exact Pull Request that have to do with OnPlatform in code and XAML that use the new Device.RuntimePlatform. So, what is OnPlatform? It allows you to set properties on elements or run specific code based on specific platforms. This is really nifty for tiny tweaks to UI and can be done completely in the XAML, which is awesome. To make way for…

James Montemagno James Montemagno

Xamarin.Forms XAML Previewer Design Time Data

UPDATE Checkout my newly updated blog on Design Time Data best practices that are updated for the most recent changes in Xamarin.Forms. Original Post The most annticipated announcement of Xamarin Evolve 2016 had to be the Xamarin.Forms xAML Previewer. Enabling you to see a live preview of your Xamarin.Forms XAML without having to run it on a simulator or device. Simply write some XAML and there it is running on an iOS or Android phone or simulator design surface. Writing XAML and seeing it i…

James Montemagno James Montemagno

Enhancing Xamarin.Forms ListView with Grouping Headers

Sometimes a plain ListView just isn’t good enough. You can easily spice it up with images or custom cells, but what about organizing the data. With C# and LINQ it is easy to sort your list, but how about giving it some visuals? How about some headers? With Xamarin.Forms it is extremely simple to add in headers and to create a custom view as well. I am working out of my Xamarin.Forms-Monkeys project that I have blogged about before, which consists of a nice list of Monkeys with Images. Yo…

James Montemagno James Montemagno

I crush code and share it, publish NuGet packages, speak at conferences, upload videos, pretend I am good at playing video games, tweet up a storm, drink gallons of coffee, and ride my bike. Checkout my monthly newsletter that you should subscribe to!