开发者

WPF ListBox Template/Style (ScrollBar and InnerShadow)

开发者 https://www.devze.com 2023-03-19 03:00 出处:网络
Hy. Could you help me create the fallowing control style/template? What do I need: A (Vertical and Horizontal) ScollBar Style like that. (Without the two arrow button)

Hy.

Could you help me create the fallowing control style/template?

WPF ListBox Template/Style (ScrollBar and InnerShadow)

What do I need:

  1. A (Vertical and Horizontal) ScollBar Style like that. (Without the two arrow button)
  2. Inner sh开发者_开发百科adow on the top and bottom of the "ScrollViewer area".

    That's all I need, I can create the rest parts of the control. (Selected Item's color etc)

    Thank you.


The scrollbar control in WPF can be thought of as collection of the two repeatbuttons and the track part. You can change the template of the scrollbar and remove the repeatbutton.

For the shadow part, you need to provide the the Zorder index. Refer to the following link - WPF shadow on stackpanel controls


I know is too late for an answer but Style is very easy to get if you understand basic templating. Here you will find a Scrollbar that emulate the one you want, hope you like it.

0

精彩评论

暂无评论...
验证码 换一张
取 消