HOW CAN I ALIGN A CHECKBOX WITH ITS CONTENT?

Royce Roy

Total Post:149

Points:1043
Posted by  Royce Roy
WPF 
WPF
 1216  View(s)
Ratings:
Rate this:

The XAML looks like this:

<CheckBox Content="Poorly aligned CheckBox" Margin="9"/>

The CheckBox is inside a Grid cell. Is there a simple way to make the content and check portions of a XAML CheckBox align vertically?

  1. Pravesh Singh

    Post:412

    Points:2888
    Re: How can I align a CheckBox with its content?

    Hi Royce,

    You can do the work:

    <CheckBox>

        <TextBlock Text="Poorly aligned CheckBox" Margin="0,-2,0,0"/>

    </CheckBox>

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!