MaterialDesignInXamlToolkit icon indicating copy to clipboard operation
MaterialDesignInXamlToolkit copied to clipboard

DialogHost Style

Open myloveCc opened this issue 1 year ago • 4 comments

How can i change "wpf:Card.Style" with "MaterialDesignOutlinedCard"?

myloveCc avatar Jan 02 '24 07:01 myloveCc

At present, the style for the internal card on the dialog host is not exposed, so there is no simple way to expose that.

Keboo avatar Jan 02 '24 08:01 Keboo

@Keboo The dailog host content is so blurry with default card style. Can you add a new style named "MaterialDesignOutlinedDialogHost"?

...
<wpf:Card.Style>
   <Style TargetType="wpf:Card" BasedOn="{StaticResource MaterialDesignOutlinedCard}">
     <Setter Property="Background" Value="{Binding Tag, RelativeSource={RelativeSource Self}}" />
     <Style.Triggers>
       <Trigger Property="Tag" Value="{x:Null}">
         <Setter Property="Background" Value="{DynamicResource MaterialDesignPaper}" />
       </Trigger>
     </Style.Triggers>
   </Style>
 </wpf:Card.Style>\
...

myloveCc avatar Jan 02 '24 08:01 myloveCc