Search code examples
c#xamlwindows-8microsoft-metro

How to increase the thickness of a `Slider` control


I have a slider control in my grid:

<Slider x:Name="MainSlider"
        Margin="659,145,417,146"
        Grid.Row="1"
        Orientation="Vertical"
        SmallChange="1"
        RenderTransformOrigin="0.0799999982118607,0.5"/>

I want it to be wider though, so that the whole bar is stretched out.

I've gone through the properties and Width doesn't actually change the thickness of the slider itself, just the frame.

How can I make the actual Slider thicker?


Solution

  • You will probably need to define your own style. You can copy the default style (using Expression Blend for example) and tweak the individual component values.

    Use the "Edit Style" option to take a copy of the template and then work on that.

    There's more information on MSDN