回答編集履歴
1
見直しキャンペーン中
answer
CHANGED
@@ -7,12 +7,12 @@
|
|
7
7
|
スタイルも継承?する必要があります。
|
8
8
|
[Style.BasedOn プロパティ (System.Windows) | Microsoft Docs](https://docs.microsoft.com/ja-jp/dotnet/api/system.windows.style.basedon)
|
9
9
|
|
10
|
-
```
|
10
|
+
```xml
|
11
11
|
<Style BasedOn="{StaticResource {x:Type CheckBox}}" TargetType="{x:Type local:MyCheckBox}" />
|
12
12
|
```
|
13
13
|
どこに置いてもいいでしょうが、すべてに適用するなら`App.xaml`に置きます。
|
14
14
|
|
15
|
-
```
|
15
|
+
```xml
|
16
16
|
<Application
|
17
17
|
x:Class="Q0e3bd9vebiquet.App"
|
18
18
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
@@ -33,7 +33,7 @@
|
|
33
33
|
</Application>
|
34
34
|
```
|
35
35
|
|
36
|
-
```
|
36
|
+
```xml
|
37
37
|
<mah:MetroWindow
|
38
38
|
x:Class="Q0e3bd9vebiquet.MainWindow"
|
39
39
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
@@ -49,7 +49,7 @@
|
|
49
49
|
</mah:MetroWindow>
|
50
50
|
```
|
51
51
|
|
52
|
-
```
|
52
|
+
```cs
|
53
53
|
using System.Windows.Controls;
|
54
54
|
|
55
55
|
namespace Q0e3bd9vebiquet
|