You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/documentation/getting-started.md
+8-11
Original file line number
Diff line number
Diff line change
@@ -2,8 +2,7 @@
2
2
3
3
## Adding dictionaries
4
4
5
-
[XAML](https://docs.microsoft.com/en-us/dotnet/desktop/wpf/xaml/?view=netdesktop-6.0), and hence WPF, operate on resource dictionaries. These are HTML-like files that describe the appearance and various aspects of the [controls](https://wpfui.lepo.co/documentation/controls).
6
-
**WPF UI** adds its own sets of these files to tell the application how the controls should look like.
5
+
[XAML](https://docs.microsoft.com/en-us/dotnet/desktop/wpf/xaml/?view=netdesktop-6.0), and hence WPF, operate on resource dictionaries. These are HTML-like files that describe the appearance and various aspects of the [controls](https://wpfui.lepo.co/documentation/controls). **WPF UI** adds its own sets of these files to tell the application how the controls should look.
7
6
8
7
There should be a file called `App.xaml` in your new application. Add new dictionaries to it using **WPF UI**`ControlsDictionary` and `ThemesDictionary` classes:
9
8
@@ -20,16 +19,13 @@ There should be a file called `App.xaml` in your new application. Add new dictio
20
19
</ResourceDictionary>
21
20
</Application.Resources>
22
21
</Application>
23
-
24
22
```
25
23
26
-
You can choose a color theme here,
27
-
`Light` or `Dark`.
24
+
Notice that the `ThemeDictionary` lets you choose a color theme, `Light` or `Dark`.
28
25
29
26
## The main window
30
27
31
-
There should be a `MainWindow.xaml` file in your newly created application.
32
-
It contains the arrangement of the controls used and their parameters.
28
+
There should be a `MainWindow.xaml` file in your newly created application. It contains the arrangement of the controls used and their parameters.
33
29
34
30
```xml
35
31
<Windowx:Class="WpfApp1.MainWindow"
@@ -46,7 +42,7 @@ It contains the arrangement of the controls used and their parameters.
46
42
</Window>
47
43
```
48
44
49
-
You can add a new namespace to this window to tell the interpreter that you will be using controls from somewhere, like the**WPF UI** library.
45
+
Add the **WPF UI** library namespace to this window to tell the XAML compiler that you will be using controls from the library.
50
46
51
47
```xml
52
48
<Window
@@ -56,7 +52,7 @@ You can add a new namespace to this window to tell the interpreter that you will
56
52
57
53
## Adding controls
58
54
59
-
To add a new control from the **WPF UI** library, you just need to enter its class name, prefixing it with the `ui:` prefix:
55
+
To add a new control from the **WPF UI** library, just enter its class name, prefixing it with the `ui:` prefix:
60
56
61
57
```xml
62
58
<Windowx:Class="WpfApp1.MainWindow"
@@ -76,5 +72,6 @@ To add a new control from the **WPF UI** library, you just need to enter its cla
76
72
77
73
# Well...
78
74
79
-
That's it when it comes to the basics, information about individual controls can be found in [documentation](https://wpfui.lepo.co/documentation/), rules for building a WPF application can be found in the [official Microsoft documentation](https://learn.microsoft.com/en-us/dotnet/desktop/wpf/controls/styles-templates-overview?view=netdesktop-6.0). You can check out [**how to build MVVM applications** here](https://learn.microsoft.com/en-us/windows/communitytoolkit/mvvm/puttingthingstogether).
80
-
If you think this documentation sucks, [help improve it here](https://github.com/lepoco/wpfui/tree/development/docs/tutorial).
75
+
That's it when it comes to the basics, information about individual controls can be found in [documentation](https://wpfui.lepo.co/documentation/). Rules for building a WPF application can be found in the [official Microsoft documentation](https://learn.microsoft.com/en-us/dotnet/desktop/wpf/controls/styles-templates-overview?view=netdesktop-6.0). You can check out [**how to build MVVM applications** here](https://learn.microsoft.com/en-us/windows/communitytoolkit/mvvm/puttingthingstogether).
76
+
77
+
If you think this documentation needs improvement, please [help improve it here](https://github.com/lepoco/wpfui/tree/development/docs/tutorial).
SystemThemeWatcher automatically updates the application background if the system theme or color changes. This component is used to adapt the application's background effect and theme according to the system theme.
4
+
5
+
## Features
6
+
7
+
* Automatic Theme Updates: Updates the application's background and theme when the system theme changes.
8
+
9
+
* Global Settings: Settings apply globally and cannot be changed for each System.Windows.Window.
> If UnWatch is called on a window that has not yet loaded, an InvalidOperationException may occur. Ensure that the window is loaded before calling UnWatch.
<Description>WPF UI provides the Fluent experience in your known and loved WPF framework. Intuitive design, themes, navigation and new immersive controls. All natively and effortlessly.</Description>
0 commit comments