[Question] How to justify text in a label? #13786
-
Hi all, I have a label that displays on more than a line and I would like to justify the text in it (align left and right). What is the best way to achieve that? |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 3 replies
-
Nevermind, I figured it out how to do it. Thanks. |
Beta Was this translation helpful? Give feedback.
-
Can you please share how you acheived it. |
Beta Was this translation helpful? Give feedback.
-
Can you please share your solution here? |
Beta Was this translation helpful? Give feedback.
-
This is the way I did it. I created a new class that inherits from Label, just like this:
Then I also had to create a handler:
And I had to add this on my MauiProgram.cs:
And use it just like this:
|
Beta Was this translation helpful? Give feedback.
Nevermind, I figured it out how to do it.
Thanks.