mirror of
https://github.com/holgerb83/ModernWpfPlayground.git
synced 2025-04-19 23:03:49 +02:00
198 lines
8.6 KiB
XML
198 lines
8.6 KiB
XML
<Window
|
|
x:Class="ModernWpfPlayground.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:local="clr-namespace:ModernWpfPlayground"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:ui="http://schemas.modernwpf.com/2019"
|
|
x:Name="Window"
|
|
Title="TaBEA 3.0.0"
|
|
Width="800"
|
|
Height="450"
|
|
ui:TitleBar.ExtendViewIntoTitleBar="True"
|
|
ui:WindowHelper.UseModernWindowStyle="True"
|
|
mc:Ignorable="d">
|
|
<Window.Resources>
|
|
<local:PixelsToGridLengthConverter x:Key="PixelsToGridLength" />
|
|
</Window.Resources>
|
|
<DockPanel>
|
|
<!-- TitleBar -->
|
|
<Grid
|
|
Height="{Binding ElementName=Window, Path=(ui:TitleBar.Height)}"
|
|
Background="#DDDDDD"
|
|
DockPanel.Dock="Top">
|
|
<Grid.Style>
|
|
<Style TargetType="Grid">
|
|
<Setter Property="TextElement.Foreground" Value="{DynamicResource SystemControlForegroundBaseHighBrush}" />
|
|
<Style.Triggers>
|
|
<DataTrigger Binding="{Binding IsActive, ElementName=Window}" Value="False">
|
|
<Setter Property="TextElement.Foreground" Value="{DynamicResource SystemControlDisabledBaseMediumLowBrush}" />
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</Grid.Style>
|
|
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="{Binding ElementName=Window, Path=(ui:TitleBar.SystemOverlayLeftInset), Converter={StaticResource PixelsToGridLength}}" />
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition />
|
|
</Grid.ColumnDefinitions>
|
|
<Menu
|
|
Grid.Column="1"
|
|
Height="{Binding ElementName=Window, Path=(ui:TitleBar.Height)}"
|
|
Margin="0"
|
|
Padding="0"
|
|
WindowChrome.IsHitTestVisibleInChrome="True">
|
|
<Menu.Resources>
|
|
<Style BasedOn="{StaticResource {x:Type MenuItem}}" TargetType="MenuItem">
|
|
<Style.Triggers>
|
|
<Trigger Property="Role" Value="TopLevelHeader">
|
|
<Setter Property="Height" Value="{Binding ElementName=Window, Path=(ui:TitleBar.Height)}" />
|
|
</Trigger>
|
|
<DataTrigger Binding="{Binding IsActive, ElementName=Window}" Value="False">
|
|
<Setter Property="TextElement.Foreground" Value="{DynamicResource SystemControlDisabledBaseMediumLowBrush}" />
|
|
</DataTrigger>
|
|
</Style.Triggers>
|
|
</Style>
|
|
</Menu.Resources>
|
|
<MenuItem Header="File">
|
|
<MenuItem Header="New" />
|
|
<MenuItem Header="Open" />
|
|
<Separator />
|
|
<MenuItem Header="Close" />
|
|
</MenuItem>
|
|
<MenuItem Header="Edit">
|
|
<MenuItem Header="Copy" />
|
|
<MenuItem Header="Cut" />
|
|
<MenuItem Header="Paste" />
|
|
</MenuItem>
|
|
<MenuItem Header="Help">
|
|
<MenuItem Header="?" />
|
|
<Separator />
|
|
<MenuItem Header="Info" />
|
|
</MenuItem>
|
|
</Menu>
|
|
<!-- Horizontally centered title -->
|
|
<TextBlock
|
|
Grid.Column="0"
|
|
Grid.ColumnSpan="3"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center"
|
|
FontSize="13"
|
|
Text="{Binding ElementName=Window, Path=Title}" />
|
|
</Grid>
|
|
<!-- Footer -->
|
|
<Grid
|
|
Height="24"
|
|
Background="DarkGreen"
|
|
DockPanel.Dock="Bottom">
|
|
<Grid.Resources>
|
|
<Style TargetType="TextBlock">
|
|
<Setter Property="Foreground" Value="White" />
|
|
<Setter Property="Margin" Value="10,0" />
|
|
<Setter Property="VerticalAlignment" Value="Center" />
|
|
</Style>
|
|
</Grid.Resources>
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition />
|
|
</Grid.ColumnDefinitions>
|
|
<TextBlock Grid.Column="0" Text="Holger Börchers" />
|
|
<TextBlock Grid.Column="1" Text="|" />
|
|
<TextBlock Grid.Column="2" Text="SQL-SRV\SQLEXPRESS" />
|
|
<TextBlock
|
|
Grid.Column="3"
|
|
HorizontalAlignment="Right"
|
|
Text="BlaBlaBla" />
|
|
</Grid>
|
|
<!-- Content -->
|
|
<Grid Row="1">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="40" />
|
|
<ColumnDefinition Width="Auto" />
|
|
<ColumnDefinition Width="4" />
|
|
<ColumnDefinition />
|
|
</Grid.ColumnDefinitions>
|
|
<Border
|
|
Grid.Column="0"
|
|
Background="#2C2C2C"
|
|
BorderThickness="0">
|
|
<StackPanel HorizontalAlignment="Center">
|
|
<TextBlock
|
|
Margin="0,10"
|
|
Cursor="Hand"
|
|
FontSize="20"
|
|
Foreground="#F4F4F4"
|
|
Text="Dummy active">
|
|
<TextBlock.LayoutTransform>
|
|
<RotateTransform Angle="270" />
|
|
</TextBlock.LayoutTransform>
|
|
</TextBlock>
|
|
<TextBlock
|
|
Margin="0,10"
|
|
Cursor="Hand"
|
|
FontSize="20"
|
|
Foreground="#808080"
|
|
Text="Dummy inactive">
|
|
<TextBlock.LayoutTransform>
|
|
<RotateTransform Angle="270" />
|
|
</TextBlock.LayoutTransform>
|
|
</TextBlock>
|
|
</StackPanel>
|
|
</Border>
|
|
<TreeView
|
|
Grid.Column="1"
|
|
MinWidth="180"
|
|
Background="#F3F3F3"
|
|
BorderThickness="0">
|
|
<TreeViewItem Header="Root">
|
|
<TreeViewItem Header="Child1" />
|
|
<TreeViewItem Header="Child2" />
|
|
<TreeViewItem Header="Child3" />
|
|
</TreeViewItem>
|
|
</TreeView>
|
|
<GridSplitter
|
|
Grid.Column="2"
|
|
Width="4"
|
|
Background="Transparent" />
|
|
<Grid Grid.Column="3">
|
|
<Grid.ColumnDefinitions>
|
|
<ColumnDefinition Width="200" />
|
|
<ColumnDefinition />
|
|
<ColumnDefinition />
|
|
</Grid.ColumnDefinitions>
|
|
<StackPanel Margin="10" Orientation="Vertical">
|
|
<StackPanel.Resources>
|
|
<Style BasedOn="{StaticResource {x:Type Button}}" TargetType="Button">
|
|
<Setter Property="HorizontalAlignment" Value="Stretch" />
|
|
<Setter Property="Margin" Value="5" />
|
|
</Style>
|
|
</StackPanel.Resources>
|
|
<Button HorizontalAlignment="Stretch" Content="New" />
|
|
<Button HorizontalAlignment="Stretch" Content="Open" />
|
|
<Separator />
|
|
<Button HorizontalAlignment="Stretch" Content="Open catalog" />
|
|
</StackPanel>
|
|
<StackPanel Grid.Column="1" Grid.ColumnSpan="2">
|
|
<TextBlock Margin="0,10" FontSize="24" TextWrapping="Wrap">
|
|
<Run FontWeight="Bold" Text="T" /><Run Text="ower" />
|
|
<Run FontWeight="Bold" Text="a" /><Run Text="nd" />
|
|
<Run FontWeight="Bold" Text="B" /><Run Text="asement" />
|
|
<Run FontWeight="Bold" Text="E" /><Run Text="ngineering" />
|
|
<Run FontWeight="Bold" Text="A" /><Run Text="pplication" />
|
|
</TextBlock>
|
|
<TabControl>
|
|
<TabItem Header="Bolt" />
|
|
<TabItem Header="General" />
|
|
</TabControl>
|
|
</StackPanel>
|
|
</Grid>
|
|
</Grid>
|
|
</DockPanel>
|
|
|
|
</Window>
|
|
|