Dialog added, TreeView added and so on...
This commit is contained in:
parent
ffbdb06fa5
commit
12b3d0c7fb
@ -4,6 +4,13 @@
|
||||
xmlns:local="clr-namespace:MaterialModernWPF"
|
||||
StartupUri="MainWindow.xaml">
|
||||
<Application.Resources>
|
||||
|
||||
<ResourceDictionary>
|
||||
<ResourceDictionary.MergedDictionaries>
|
||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Light.xaml" />
|
||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Defaults.xaml" />
|
||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Primary/MaterialDesignColor.Indigo.xaml" />
|
||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Accent/MaterialDesignColor.Lime.xaml" />
|
||||
</ResourceDictionary.MergedDictionaries>
|
||||
</ResourceDictionary>
|
||||
</Application.Resources>
|
||||
</Application>
|
||||
|
@ -5,40 +5,58 @@
|
||||
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:modern="http://modernwpf"
|
||||
x:Name="theWindow"
|
||||
Title="Chrome With 3rd Party Material Theme"
|
||||
xmlns:system="clr-namespace:System;assembly=mscorlib"
|
||||
x:Name="Window"
|
||||
Title="Material Design In XAML Toolkit"
|
||||
Width="920"
|
||||
Height="600"
|
||||
modern:UIHooks.AutoDpiScale="True"
|
||||
Background="{DynamicResource MaterialDesignPaper}"
|
||||
FontFamily="pack://application:,,,/MaterialDesignThemes.Wpf;component/Resources/Roboto/#Roboto"
|
||||
Icon="airballoon.ico"
|
||||
ResizeMode="CanResizeWithGrip"
|
||||
TextElement.Foreground="{DynamicResource MaterialDesignBody}"
|
||||
mc:Ignorable="d">
|
||||
<Window.Resources>
|
||||
<ResourceDictionary>
|
||||
<ResourceDictionary.MergedDictionaries>
|
||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Light.xaml" />
|
||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignThemes.Wpf;component/Themes/MaterialDesignTheme.Defaults.xaml" />
|
||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Primary/MaterialDesignColor.Indigo.xaml" />
|
||||
<ResourceDictionary Source="pack://application:,,,/MaterialDesignColors;component/Themes/Recommended/Accent/MaterialDesignColor.Lime.xaml" />
|
||||
</ResourceDictionary.MergedDictionaries>
|
||||
</ResourceDictionary>
|
||||
|
||||
</Window.Resources>
|
||||
<modern:Chrome.Chrome>
|
||||
<modern:Chrome ActiveBorderBrush="{StaticResource PrimaryHueDarkBrush}" />
|
||||
</modern:Chrome.Chrome>
|
||||
<materialDesign:DialogHost Identifier="RootDialog">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
<modern:TitleBar x:Name="titleBar"
|
||||
Grid.Row="0"
|
||||
Background="{StaticResource PrimaryHueDarkBrush}"
|
||||
ShowIcon="False" />
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto" />
|
||||
<RowDefinition Height="*" />
|
||||
</Grid.RowDefinitions>
|
||||
<modern:TitleBar Grid.Row="0"
|
||||
Background="{StaticResource PrimaryHueDarkBrush}"
|
||||
ShowTitle="False" />
|
||||
<materialDesign:DialogHost Grid.Row="1" Identifier="RootDialog">
|
||||
<materialDesign:DialogHost.DialogContent>
|
||||
<StackPanel Margin="16">
|
||||
<TextBlock>Tell me your name:</TextBlock>
|
||||
<TextBox x:Name="FruitTextBox"
|
||||
Margin="0 8 0 0"
|
||||
HorizontalAlignment="Stretch" />
|
||||
<StackPanel HorizontalAlignment="Right" Orientation="Horizontal">
|
||||
<Button Margin="0 8 8 0"
|
||||
Command="materialDesign:DialogHost.CloseDialogCommand"
|
||||
IsDefault="True"
|
||||
Style="{StaticResource MaterialDesignFlatButton}">
|
||||
<Button.CommandParameter>
|
||||
<system:Boolean>True</system:Boolean>
|
||||
</Button.CommandParameter>
|
||||
ACCEPT
|
||||
</Button>
|
||||
<Button Margin="0 8 8 0"
|
||||
Command="materialDesign:DialogHost.CloseDialogCommand"
|
||||
IsCancel="True"
|
||||
Style="{StaticResource MaterialDesignFlatButton}">
|
||||
<Button.CommandParameter>
|
||||
<system:Boolean>False</system:Boolean>
|
||||
</Button.CommandParameter>
|
||||
CANCEL
|
||||
</Button>
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
</materialDesign:DialogHost.DialogContent>
|
||||
<materialDesign:DrawerHost Grid.Row="1" IsLeftDrawerOpen="{Binding ElementName=MenuToggleButton, Path=IsChecked}">
|
||||
<materialDesign:DrawerHost.LeftDrawerContent>
|
||||
<DockPanel MinWidth="212">
|
||||
@ -49,21 +67,23 @@
|
||||
Path=IsChecked,
|
||||
Mode=TwoWay}"
|
||||
Style="{StaticResource MaterialDesignHamburgerToggleButton}" />
|
||||
<Grid>
|
||||
<Button>Hello World</Button>
|
||||
</Grid>
|
||||
<TreeView>
|
||||
<TreeViewItem Header="Item1" IsExpanded="True">
|
||||
<TreeViewItem Header="Item1" />
|
||||
<TreeViewItem Header="Item2" />
|
||||
<TreeViewItem Header="Item3" />
|
||||
</TreeViewItem>
|
||||
<TreeViewItem Header="Item2" />
|
||||
<TreeViewItem Header="Item3" />
|
||||
<TreeViewItem Header="Item4" />
|
||||
</TreeView>
|
||||
</DockPanel>
|
||||
</materialDesign:DrawerHost.LeftDrawerContent>
|
||||
<DockPanel>
|
||||
|
||||
|
||||
<materialDesign:ColorZone materialDesign:ShadowAssist.ShadowDepth="Depth2"
|
||||
DockPanel.Dock="Top"
|
||||
Mode="PrimaryMid"
|
||||
Padding="16">
|
||||
|
||||
|
||||
|
||||
<DockPanel>
|
||||
<ToggleButton x:Name="MenuToggleButton"
|
||||
IsChecked="False"
|
||||
@ -72,20 +92,17 @@
|
||||
PlacementMode="BottomAndAlignRightEdges"
|
||||
StaysOpen="False">
|
||||
<StackPanel>
|
||||
<Button Content="Hello World" />
|
||||
<Button Content="Nice Popup" />
|
||||
<Button Content="Goodbye" />
|
||||
<Button Command="{x:Static materialDesign:DialogHost.OpenDialogCommand}" Content="Info" />
|
||||
</StackPanel>
|
||||
</materialDesign:PopupBox>
|
||||
<TextBlock HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
FontSize="22">
|
||||
Material Design In XAML Toolkit
|
||||
</TextBlock>
|
||||
FontSize="22"
|
||||
Text="{Binding Title,
|
||||
ElementName=Window}" />
|
||||
</DockPanel>
|
||||
|
||||
</materialDesign:ColorZone>
|
||||
<StackPanel Grid.Row="1" Margin="8">
|
||||
<StackPanel Margin="8">
|
||||
<TextBlock Text="This window demonstrates using core Chrome + external theming lib (ButchersBoy)." TextWrapping="Wrap" />
|
||||
<Button Content="Hello Button" />
|
||||
<ComboBox>
|
||||
@ -98,6 +115,6 @@
|
||||
</StackPanel>
|
||||
</DockPanel>
|
||||
</materialDesign:DrawerHost>
|
||||
</Grid>
|
||||
</materialDesign:DialogHost>
|
||||
</Window>
|
||||
</materialDesign:DialogHost>
|
||||
</Grid>
|
||||
</Window>
|
@ -34,9 +34,12 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<ApplicationIcon>airballoon.ico</ApplicationIcon>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="MaterialDesignColors, Version=1.1.2.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\MaterialDesignColors.1.1.2\lib\net45\MaterialDesignColors.dll</HintPath>
|
||||
<Reference Include="MaterialDesignColors, Version=1.1.3.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<HintPath>..\packages\MaterialDesignColors.1.1.3\lib\net45\MaterialDesignColors.dll</HintPath>
|
||||
<Private>True</Private>
|
||||
</Reference>
|
||||
<Reference Include="MaterialDesignThemes.Wpf, Version=2.0.0.638, Culture=neutral, processorArchitecture=MSIL">
|
||||
@ -108,6 +111,9 @@
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="airballoon.ico" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
|
BIN
MaterialModernWPF/airballoon.ico
Normal file
BIN
MaterialModernWPF/airballoon.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 24 KiB |
@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<packages>
|
||||
<package id="MaterialDesignColors" version="1.1.2" targetFramework="net452" />
|
||||
<package id="MaterialDesignColors" version="1.1.3" targetFramework="net452" />
|
||||
<package id="MaterialDesignThemes" version="2.0.0.638" targetFramework="net452" />
|
||||
<package id="ModernWpf.Core" version="2.0.0-alpha94" targetFramework="net452" />
|
||||
</packages>
|
Loading…
x
Reference in New Issue
Block a user