KsWare.Presentation.Resources.Core
0.1.6
.NET 6.0
This package targets .NET 6.0. The package is compatible with this framework or higher.
.NET Framework 4.6.2
This package targets .NET Framework 4.6.2. The package is compatible with this framework or higher.
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package KsWare.Presentation.Resources.Core --version 0.1.6
NuGet\Install-Package KsWare.Presentation.Resources.Core -Version 0.1.6
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="KsWare.Presentation.Resources.Core" Version="0.1.6" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add KsWare.Presentation.Resources.Core --version 0.1.6
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: KsWare.Presentation.Resources.Core, 0.1.6"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install KsWare.Presentation.Resources.Core as a Cake Addin #addin nuget:?package=KsWare.Presentation.Resources.Core&version=0.1.6 // Install KsWare.Presentation.Resources.Core as a Cake Tool #tool nuget:?package=KsWare.Presentation.Resources.Core&version=0.1.6
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
KsWare.Presentation.Resources.Core
Extended ResourceDictionaries
Name | Fuction |
---|---|
CoreResourceDictionary | A base class which extens the ResourceDictionary class |
ResourceDictionaryEx | A feature-rich ResourceDictionary |
ThemeResourceDictionary | Root for theme resources |
SharedResourceDictionary | Reuseable resources |
PlaceholderResourceDictionary | A placeholder |
SourceResourceDictionary | The root für XAML resources |
MergedResourceDictionary | The root for merged resources |
LookupResourceDictionary | Lookups for an other ResourceDictionary defined as resource |
FlatResourceDictionary | Flattens all contained resources into one ResourceDictionary |
OverrideDefaultStylesResourceDictionary | Generates Styles |
designed to:
- create maintainable structured themes
- avoid DynamicResource references
- fixes few issues from ResourceDictionary
Usage
<SourceResourceDictionary
<ResourceDictionary.MergedDictionary>
<SharedResourceDictionary Source="shared.xaml
<MergedResourceDictionary Name="Brushes">
<SolidColorBrush x:Key="Acme.Control.Border" Color="Gree"/>
...
</MergedResourceDictionary>
<LookupResourceDictionary ResourceKey="Acme.Brushes.Overides"/>
<MergedResourceDictionary Name="Styles">
<Style x:Key="Acme.ControlStyle" TargetType="Control">
...
</Style>
</MergedResourceDictionary
<OverrideDefaultStylesResourceDictionary>
<Style TargetType="Control" BasedOn="{StaticResource Acme.ControlStyle}"/>
</OverrideDefaultStylesResourceDictionary>
</ResourceDictionary.MergedDictionary>
</SourceResourceDictionary>
ThemeLoader
A loader for themes.
You can load any resource dictionary. RegisterTheme is otional.
App.xaml.cs / App.xaml
public partial class App : Application {
public App() {
// optional
ThemeLoader.RegisterTheme("Aero2Dark.NormalColor", "/KsWare.Presentation.Themes.Aero2Dark;component/Resources/Aero2Dark.NormalColor.xaml");
ThemeLoader.RegisterTheme("Aero2Dark","Aero2Dark.NormalColor") // alias
ThemeLoader.RegisterTheme("Aero", "/PresentationFramework.Aero;component/themes/Aero.NormalColor.xaml");
}
<Application
...
ThemeLoader.Source="/KsWare.Presentation.Themes.Aero2Dark;component/Resources/Aero2Dark.NormalColor.xaml"
>
MainWindow.cs / MainWindow.xaml.cs
public MainWindow() {
// optional
ThemeLoader.RegisterTheme("Aero2Dark.NormalColor", "/KsWare.Presentation.Themes.Aero2Dark;component/Resources/Aero2Dark.NormalColor.xaml");
ThemeLoader.RegisterTheme("Aero2Dark","Aero2Dark.NormalColor") // alias
ThemeLoader.RegisterTheme("Aero", "/PresentationFramework.Aero;component/themes/Aero.NormalColor.xaml");
InitializeComponent();
}
<Window
...
ThemeLoader.Source="Aero2Dark" >
<Grid ThemeLoader.Source="Aero">
</Grid>
<Grid ThemeLoader.Source="/PresentationFramework.Luna;component/themes/Luna.Metallic.xaml">
</Grid>
</Window>
License
© 2024 by KsWare. All rights reserved.
Licensed under KsWare Open Commercial License.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0-windows7.0 is compatible. net7.0-windows was computed. net8.0-windows was computed. net8.0-windows7.0 is compatible. |
.NET Framework | net462 is compatible. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 is compatible. net481 was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
.NETFramework 4.6.2
- System.ValueTuple (>= 4.5.0)
-
.NETFramework 4.8
- No dependencies.
-
net6.0-windows7.0
- No dependencies.
-
net8.0-windows7.0
- No dependencies.
NuGet packages (1)
Showing the top 1 NuGet packages that depend on KsWare.Presentation.Resources.Core:
Package | Downloads |
---|---|
KsWare.Presentation.Themes.Aero2Dark
A dark theme based on Aero2 |
GitHub repositories
This package is not used by any popular GitHub repositories.