Files
Better-Seewo/Manager/MainWindow.xaml

93 lines
5.6 KiB
Plaintext
Raw Normal View History

<Window x:Class="BetterSeewoManager.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Better-Seewo 管理器"
Width="960" Height="600"
MinWidth="800" MinHeight="500"
WindowStartupLocation="CenterScreen"
Background="{StaticResource BackgroundBrush}"
FontFamily="{StaticResource DefaultFont}"
Foreground="{StaticResource TextPrimaryBrush}">
<Window.Resources>
<BooleanToVisibilityConverter x:Key="BoolToVis"/>
<Style x:Key="TabRadioButton" TargetType="RadioButton">
<Setter Property="Background" Value="Transparent"/>
<Setter Property="Foreground" Value="{StaticResource TextSecondaryBrush}"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="Padding" Value="16,10"/>
<Setter Property="BorderThickness" Value="3,0,0,0"/>
<Setter Property="BorderBrush" Value="Transparent"/>
<Setter Property="Cursor" Value="Hand"/>
<Setter Property="GroupName" Value="Tabs"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="RadioButton">
<Border x:Name="border" Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"
Padding="{TemplateBinding Padding}">
<ContentPresenter HorizontalAlignment="Left" VerticalAlignment="Center"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsChecked" Value="True">
<Setter TargetName="border" Property="Background" Value="{StaticResource CardBrush}"/>
<Setter Property="Foreground" Value="{StaticResource TextPrimaryBrush}"/>
<Setter Property="BorderBrush" Value="{StaticResource AccentBrush}"/>
</Trigger>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="border" Property="Background" Value="{StaticResource CardBrush}"/>
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</Window.Resources>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="56"/>
<RowDefinition Height="*"/>
<RowDefinition Height="32"/>
</Grid.RowDefinitions>
<Border Grid.Row="0" Background="{StaticResource SurfaceBrush}" BorderBrush="{StaticResource BorderBrush}" BorderThickness="0,0,0,1">
<Grid Margin="16,0">
<StackPanel Orientation="Horizontal" VerticalAlignment="Center">
<TextBlock Text="Better-Seewo" FontSize="18" FontWeight="SemiBold" Foreground="{StaticResource AccentBrush}" VerticalAlignment="Center"/>
<TextBlock Text=" 管理器" FontSize="14" Foreground="{StaticResource TextSecondaryBrush}" VerticalAlignment="Center" Margin="8,0,0,0"/>
</StackPanel>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center">
<TextBlock Text="v2.0.0" FontSize="11" Foreground="{StaticResource TextSecondaryBrush}" VerticalAlignment="Center" Margin="0,0,12,0"/>
<Button x:Name="BtnThemeToggle" Content="🌙" Width="28" Height="28" FontSize="14"
Background="Transparent" Foreground="{StaticResource TextPrimaryBrush}" BorderThickness="0"
Cursor="Hand" Click="BtnThemeToggle_Click"/>
</StackPanel>
</Grid>
</Border>
<Grid Grid.Row="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="160"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Border Grid.Column="0" Background="{StaticResource SurfaceBrush}" BorderBrush="{StaticResource BorderBrush}" BorderThickness="0,0,1,0">
<StackPanel x:Name="TabPanel" Margin="0,8">
<RadioButton x:Name="TabInstall" Content="📦 安装" IsChecked="True" Click="Tab_Click" Style="{StaticResource TabRadioButton}" Tag="InstallPage"/>
<RadioButton x:Name="TabInk" Content="✏️ 墨迹" Click="Tab_Click" Style="{StaticResource TabRadioButton}" Tag="InkPage"/>
<RadioButton x:Name="TabConvert" Content="🔄 转换" Click="Tab_Click" Style="{StaticResource TabRadioButton}" Tag="ConvertPage"/>
<RadioButton x:Name="TabTouch" Content="👆 触摸" Click="Tab_Click" Style="{StaticResource TabRadioButton}" Tag="TouchPage"/>
<RadioButton x:Name="TabActivate" Content="🔑 激活" Click="Tab_Click" Style="{StaticResource TabRadioButton}" Tag="ActivatePage"/>
</StackPanel>
</Border>
<Frame x:Name="ContentFrame" Grid.Column="1" NavigationUIVisibility="Hidden"/>
</Grid>
<Border Grid.Row="2" Background="{StaticResource SurfaceBrush}" BorderBrush="{StaticResource BorderBrush}" BorderThickness="0,1,0,0">
<TextBlock x:Name="StatusText" Text="就绪" FontSize="11" Foreground="{StaticResource TextSecondaryBrush}" Margin="12,0" VerticalAlignment="Center"/>
</Border>
</Grid>
</Window>