Using XAML in Xamarin Forms we can change the accent color of the Progress Bars we define, and being able to set it to a HEX value, the possibilities are endless (well, not exactly, only about 16 million, but you know what I mean).
But what if you want that color to change dynamically, say, depending on how much the progress bar is filled, especially if you're going to keep your code-behind as clean as possible, so no handling of events and messy code.
Something that I haven't always liked about Android is the top-side tab bars. You know, those that can take you from one page to another very easily without reaching your finger too far onto the screen or opening a side menu. I love bottom tab bars, iOS has always had them, and I use them a lot.
In the previous post, I showed you how you could handle multiple states for a specific element using the VisualStateManager and defining various groups and VisualStates.
In this post, we will use this same feature to change the UI of an example application so that it hides a title when the device is on portrait mode, so there is more space for the main component of the interface, which will be a ListView.
If there is something that can take a good-looking app to an incredible-looking app that may very well be Visual States. By defining different Visual States you are able to define how a certain element must look depending on some interaction from the user. The simpler example is with buttons, with which you are able to see when someone hovers over them (perhaps they change color), someone presses them (maybe in addition to colors the scale also changes), maybe also when they lose focus.
It could be a bit of a pain to try to use Images as buttons, for those scenarios when you needed to display a certain image but also needed the user to be able to click on it, with all that that implies. A nice animation, perhaps change of color, and of course the triggering of an event or the ability to bind a Command. As of Xamarin Forms 3.4, this is no longer a pain, now you can define an ImageButton like you would define any element in the interface, and use it similarly to how you would use an Image, and make it respond to how a Button would.
Let’s imagine that you already have some login functionality in place inside your application so we can focus on the task at hand: implementing biometrics inside the iOS application. Basically either TouchID or FaceID, depending on what is supported by the device (iPhone 5s to iPhone 8 support TouchID and iPhone X, XR, XS and XS Max support FaceID).
The Xamarin Forms previewer is a great tool that helps you see in real time how your Xamarin apps' interface is going to look like in a real device. But it seems that Microsoft decided in Visual Studio 2017 15.8 to get rid of it, it isn't anywhere to be found! Is it?
What the content moderator service does is, as its name may suggest, provide you information that will help you automate moderation decisions. For example, you may want to hide images that are sexually explicit, or that contain some sort of adult content. In the example that we will be working with we will be hiding profanity (curse words) from a "tweet" (you know, for our imaginary Twitter for Kids app).
As I was working with a ListView in Xamarin Forms I came across a couple of issues, here I explain how I solve some custom renders not being correctly displayed inside a ViewCell, and the NumberOfRowsInSection method throwing an exception when HasUnevenRows is set to true.
In this video, I talk about how you can create a custom renderer to customize the looks of a Progress Bar for your iOS applications built with Xamarin Forms. That includes changing the progress tint color (foreground color) and the height.
Take this complete guide to Xamarin.Forms and learn to create a full Xamarin.Forms app that uses XAML to define the interface, that uses the NavigationPage to navigate between pages, that implements local databases with SQLite, that uses ListView and DataBinding to list elements from the database, that creates a ToolbarItem, and that is tested directly from Visual Studio 2017 into an Android and an iOS simulator.