开发者

Style vs. ControlTemplate

开发者 https://www.devze.com 2022-12-30 13:04 出处:网络
is it possible to define resources in the style rather then using a template? <ListView.Resources >

is it possible to define resources in the style rather then using a template?

    <ListView.Resources >
        <Style TargetType="{x:Type ScrollBar}">
              <Setter开发者_开发问答 Property="Background" Value="Transparent" />
         </Style>
    </ListView.Resources>

How can I wrap this thing into:

   <Style TargetType="{x:Type ListView}"> 

   </Style>

?


I'm not sure I understand your question correctly... is that what you're looking for ?

    <Style TargetType="{x:Type ScrollBar}">
          <Style.Resources>
              <Style TargetType="{x:Type ListView}"> 

              </Style>

          </Style.Resources>
          <Setter Property="Background" Value="Transparent" />
     </Style>
0

精彩评论

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