sourcegit/src/Views/Launcher.xaml

70 lines
3.6 KiB
Text
Raw Normal View History

2021-04-29 05:05:55 -07:00
<Window x:Class="SourceGit.Views.Launcher"
x:Name="me"
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:controls="clr-namespace:SourceGit.Views.Controls"
xmlns:widgets="clr-namespace:SourceGit.Views.Widgets"
xmlns:models="clr-namespace:SourceGit.Models"
mc:Ignorable="d"
2021-05-17 01:47:56 -07:00
TextOptions.TextFormattingMode="Display"
TextOptions.TextRenderingMode="ClearType"
2021-05-26 01:03:05 -07:00
RenderOptions.ClearTypeHint="Enabled"
UseLayoutRounding="True"
WindowStartupLocation="CenterScreen"
2021-05-17 01:47:56 -07:00
MinWidth="1280" MinHeight="720"
Title="{StaticResource Text.About.Title}"
2021-04-29 05:05:55 -07:00
Width="{Binding Source={x:Static models:Preference.Instance}, Path=Window.Width, Mode=TwoWay}"
Height="{Binding Source={x:Static models:Preference.Instance}, Path=Window.Height, Mode=TwoWay}">
<WindowChrome.WindowChrome>
<WindowChrome UseAeroCaptionButtons="False" CornerRadius="0" CaptionHeight="28" ResizeBorderThickness="1"/>
</WindowChrome.WindowChrome>
<controls:WindowBorder>
<controls:DragDropAdornerLayer>
<Grid.RowDefinitions>
<RowDefinition Height="28"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<!-- Titlebar -->
<Grid Grid.Row="0" Background="{StaticResource Brush.TitleBar}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="200"/>
</Grid.ColumnDefinitions>
<!-- Bottom border -->
<Rectangle Grid.Column="0" Grid.ColumnSpan="2" Fill="{StaticResource Brush.Border0}" Height="1" VerticalAlignment="Bottom"/>
<!-- Tabs -->
<widgets:PageTabBar
Grid.Column="0"
x:Name="tabs"
TabAdd="OnTabAdding"
TabSelected="OnTabSelected"
TabClosed="OnTabClosed"/>
<!-- Right controls -->
<StackPanel Grid.Column="1" Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Top" Height="27" WindowChrome.IsHitTestVisibleInChrome="True">
<controls:IconButton Click="OpenPreference" Width="28" Padding="6" Icon="{StaticResource Icon.Preference}" ToolTip="{StaticResource Text.Launcher.Preference}"/>
<controls:IconButton Click="OpenAbout" Width="28" Padding="6" Icon="{StaticResource Icon.Help}" ToolTip="{StaticResource Text.Launcher.About}"/>
<controls:IconButton Click="Minimize" Width="28" Padding="8" Icon="{StaticResource Icon.Minimize}" HoverBackground="#40000000" Opacity="1"/>
<controls:IconButton Click="MaximizeOrRestore" Width="28" Padding="8" Icon="{StaticResource Icon.Maximize}" HoverBackground="#40000000" Opacity="1"/>
<controls:IconButton Click="Quit" Width="28" Padding="8" Icon="{StaticResource Icon.Close}" HoverBackground="Red" Opacity="1"/>
</StackPanel>
</Grid>
<!-- Contents -->
<controls:PageContainer x:Name="container" Grid.Row="1"/>
<!-- Alerts -->
<widgets:Exceptions
Grid.Row="1"
HorizontalAlignment="Right" VerticalAlignment="Top"
Width="330" Height="Auto"/>
</controls:DragDropAdornerLayer>
</controls:WindowBorder>
</Window>