I need a silverli开发者_如何学运维ght checkbox with the box that holds the checkmark much smaller(10px x 10 px) than the default size. is this possible?
Use a ScaleTransform
.
You can see from the code on the MSDN page that you can use it on any UI element. So in your case you'd want something like this:
<CheckBox ...>
<CheckBox.RenderTransform>
<ScaleTransform ScaleX="0.8" ScaleY="0.8" />
</CheckBox.RenderTransform>
</CheckBox>
You'll have to play with the scale values to get the numbers right, though if you know the current size you could do some maths to get the scale needed to reduce it to 10x10 pixels.
精彩评论