Issue
I was wondering if there's any way to do padding in an editor in Xamarin forms and to add some border radious like we do with buttons and pictures but when I had to it to my code doesn't exist that property. Is there a way to reduce my editor height and make the corners round???
Solution
Solution 1 :
You could put the editor in a Frame and set the Padding , Border and CornerRadius of it .
<StackLayout VerticalOptions="CenterAndExpand" HorizontalOptions="CenterAndExpand">
<Frame Padding="10,0" WidthRequest="500" HeightRequest="120" BorderColor="Red" CornerRadius="20">
<Editor FontSize="30" />
</Frame>
</StackLayout>
Solution 2:
There is no property like Border and CornerRadius on editor in Forms .However , they are available in native platforms . So we could set it by using Custom Renderer .
Here is a similar case to set Border and CornerRadius on Entry . You could have a check .
Answered By - Lucas Zhang - MSFT
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.