Look at the TemplatedView, with that ancestor you can create a fully customizable controls.
There is an actual Pull Request on the Xamarin.CommunityToolkit for adding the control that you need. You can be inspired by this one to create your own or wait for this PR to be merged.
Creating a Button with Multiple Components
I want to create a Button that is made up of multiple parts. I am very new to Xamarin.Forms & Android, but what I have found makes it sound like a CustomRenderer is what I should be using. However, from what I have seen in the examples I could find, the CustomRenderer only lets you change properties of a Button. I am looking for something more like the Content property or Template property & ControlTemplate that existed in UWP (I have a large background in UWP & am working on converting my apps to Xamarin.Forms). These let you use any elements you wanted for the visual component of the control. I want the same properties & events as a regular Button, but I need to have multiple elements in the visual part of the Button (such as an image, multiple text elements, shapes, etc.). How do I do this? Thanks.
1 answer
Sort by: Most helpful
-
Morgan SOULLEZ 1 Reputation point
2020-11-25T12:53:10.117+00:00