-
-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/iNKORE-NET/UI.WPF.Modern
- Loading branch information
Showing
12 changed files
with
126 additions
and
0 deletions.
There are no files selected for viewing
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<Application x:Class="TransparentNavigationViewExample.App" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:local="clr-namespace:TransparentNavigationViewExample" | ||
xmlns:ui="http://schemas.inkore.net/lib/ui/wpf/modern" | ||
StartupUri="MainWindow.xaml"> | ||
<Application.Resources> | ||
<ResourceDictionary> | ||
<ResourceDictionary.MergedDictionaries> | ||
<ui:ThemeResources/> | ||
<ui:XamlControlsResources/> | ||
</ResourceDictionary.MergedDictionaries> | ||
</ResourceDictionary> | ||
</Application.Resources> | ||
</Application> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
using System.Configuration; | ||
using System.Data; | ||
using System.Windows; | ||
|
||
namespace TransparentNavigationViewExample | ||
{ | ||
/// <summary> | ||
/// Interaction logic for App.xaml | ||
/// </summary> | ||
public partial class App : Application | ||
{ | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
using System.Windows; | ||
|
||
[assembly: ThemeInfo( | ||
ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located | ||
//(used if a resource is not found in the page, | ||
// or application resource dictionaries) | ||
ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located | ||
//(used if a resource is not found in the page, | ||
// app, or any theme specific resource dictionaries) | ||
)] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<Window x:Class="TransparentNavigationViewExample.MainWindow" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
xmlns:ui="http://schemas.inkore.net/lib/ui/wpf/modern" | ||
xmlns:local="clr-namespace:TransparentNavigationViewExample" | ||
mc:Ignorable="d" | ||
ui:WindowHelper.UseModernWindowStyle="True" ui:WindowHelper.SystemBackdropType="Mica" | ||
ui:TitleBar.Height="36" | ||
Title="MainWindow" Height="450" Width="800"> | ||
|
||
<!--This is the key part of this sample--> | ||
<Window.Resources> | ||
<Thickness x:Key="NavigationViewContentMargin">0,0,0,0</Thickness> | ||
<CornerRadius x:Key="NavigationViewContentGridCornerRadius">8,0,0,8</CornerRadius> | ||
<Thickness x:Key="NavigationViewContentGridBorderThickness">1</Thickness> | ||
<SolidColorBrush x:Key="NavigationViewContentBackground" Color="Transparent" /> | ||
<SolidColorBrush x:Key="NavigationViewContentGridBorderBrush" Color="Transparent" /> | ||
<SolidColorBrush x:Key="NavigationViewExpandedPaneBackground" Color="Transparent" /> | ||
</Window.Resources> | ||
<!--End of the key part--> | ||
|
||
<Grid> | ||
<ui:NavigationView IsPaneOpen="False" PaneDisplayMode="Auto"> | ||
|
||
<ui:NavigationView.MenuItems> | ||
<ui:NavigationViewItem Content="Home"> | ||
<ui:NavigationViewItem.Icon> | ||
<ui:FontIcon Icon="{x:Static ui:SegoeFluentIcons.Home}"/> | ||
</ui:NavigationViewItem.Icon> | ||
</ui:NavigationViewItem> | ||
<ui:NavigationViewItem Content="Library"> | ||
<ui:NavigationViewItem.Icon> | ||
<ui:FontIcon Icon="{x:Static ui:SegoeFluentIcons.Library}"/> | ||
</ui:NavigationViewItem.Icon> | ||
</ui:NavigationViewItem> | ||
|
||
</ui:NavigationView.MenuItems> | ||
|
||
<Grid> | ||
<Rectangle Stroke="Gray" StrokeDashArray="5 5" StrokeDashCap="Round" StrokeEndLineCap="Round" StrokeStartLineCap="Round" StrokeThickness="2"/> | ||
<TextBlock Text="Content Area" HorizontalAlignment="Center" VerticalAlignment="Center"/> | ||
</Grid> | ||
</ui:NavigationView> | ||
</Grid> | ||
</Window> |
24 changes: 24 additions & 0 deletions
24
samples/TransparentNavigationViewExample/MainWindow.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
using System.Text; | ||
using System.Windows; | ||
using System.Windows.Controls; | ||
using System.Windows.Data; | ||
using System.Windows.Documents; | ||
using System.Windows.Input; | ||
using System.Windows.Media; | ||
using System.Windows.Media.Imaging; | ||
using System.Windows.Navigation; | ||
using System.Windows.Shapes; | ||
|
||
namespace TransparentNavigationViewExample | ||
{ | ||
/// <summary> | ||
/// Interaction logic for MainWindow.xaml | ||
/// </summary> | ||
public partial class MainWindow : Window | ||
{ | ||
public MainWindow() | ||
{ | ||
InitializeComponent(); | ||
} | ||
} | ||
} |
16 changes: 16 additions & 0 deletions
16
samples/TransparentNavigationViewExample/TransparentNavigationViewExample.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<OutputType>WinExe</OutputType> | ||
<TargetFramework>net6.0-windows10.0.18362.0</TargetFramework> | ||
<Nullable>enable</Nullable> | ||
<ImplicitUsings>enable</ImplicitUsings> | ||
<UseWPF>true</UseWPF> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="iNKORE.UI.WPF" Version="1.2.4" /> | ||
<PackageReference Include="iNKORE.UI.WPF.Modern" Version="0.9.28" /> | ||
</ItemGroup> | ||
|
||
</Project> |