Files
ShrlAlgoToolkit/NeuWPF/NeuWPFTest/ControlTestWindow.xaml
2025-08-12 23:08:54 +08:00

72 lines
2.7 KiB
XML

<Window
Height="600"
Icon="/Resources/Images/SyminUI.png"
Title="Custom Control Test"
Width="800"
d:Height="1200"
d:SizeToContent="WidthAndHeight"
mc:Ignorable="d"
x:Class="NeuWPFTest.ControlTestWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:lu="https://github.com/ShrlAlgo/NeuWPF"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<!-- 主窗口背景色,这是拟态风格的基础 -->
<Window.Resources>
<!--<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="pack://application:,,,/NeuWPFTest;component/ButtonStyles.xaml" />
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>-->
</Window.Resources>
<!--<lu:WindowAssist.TitleBar>
<Menu>
<MenuItem Header="Help">
<MenuItem Header="About" />
</MenuItem>
</Menu>
</lu:WindowAssist.TitleBar>-->
<Grid>
<ScrollViewer
Grid.Column="0"
Grid.ColumnSpan="2"
Grid.Row="1">
<lu:StackPanel Background="{DynamicResource BackgroundLayoutBrush}" Spacing="10">
<lu:PropertyField
Grid.Row="0"
Margin="6,0"
PropertyName="属性"
PropertyValue="123" />
<lu:PropertyField
Grid.Row="1"
Margin="6,0"
PropertyName="属性x"
PropertyValue="154" />
<TreeView Grid.Row="3" x:Name="OldTreeView">
<TreeView.ItemTemplate>
<DataTemplate>
<TextBlock Text="{Binding ItemName}" />
</DataTemplate>
</TreeView.ItemTemplate>
</TreeView>
<TreeViewItem Grid.Row="4" Header="TreeItem" />
<ItemsControl Grid.Row="5" x:Name="testItemsControl" />
<lu:StackPanel
Grid.Row="6"
HorizontalAlignment="Center"
Margin="20"
Spacing="100">
<Button
Content="Button"
Height="100"
Style="{StaticResource NeuMorphicButtonStyle}"
Width="200" />
</lu:StackPanel>
</lu:StackPanel>
</ScrollViewer>
</Grid>
</Window>