How to create a common WPF base window style?

前端 未结 5 1316
一个人的身影
一个人的身影 2020-12-06 04:01

Is there any recommended way with WPF to create a common window style to be used across an application? I have several dialogs that appear in my app, and I would like them a

5条回答
  •  时光取名叫无心
    2020-12-06 04:22

    You can use define a style in App.Xaml that targets all windows.

    This is a sample of how your App.Xaml may look like:

    
    
        
    
    

    Then for more advanced scenarios you may need to set the ControlTemplate for your Window.

提交回复
热议问题