0fb5c04deb
This reverts commit fbfac18ca0.
222 lines
19 KiB
XML
222 lines
19 KiB
XML
<UserControl x:Class="Ink_Canvas.Windows.SettingsViews.LuckyRandomPanel"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
xmlns:local="clr-namespace:Ink_Canvas.Windows.SettingsViews"
|
|
xmlns:ui="http://schemas.inkore.net/lib/ui/wpf/modern"
|
|
mc:Ignorable="d"
|
|
d:DesignHeight="950" d:DesignWidth="640">
|
|
<UserControl.Resources>
|
|
<ResourceDictionary>
|
|
<ResourceDictionary.MergedDictionaries>
|
|
<ResourceDictionary Source="ComboBoxStyles.xaml"/>
|
|
</ResourceDictionary.MergedDictionaries>
|
|
<!-- 开关样式模板 -->
|
|
<Style x:Key="ToggleSwitchStyle" TargetType="Border">
|
|
<Setter Property="Width" Value="48"/>
|
|
<Setter Property="Height" Value="25"/>
|
|
<Setter Property="CornerRadius" Value="12"/>
|
|
<Setter Property="Padding" Value="3,0"/>
|
|
<Setter Property="Cursor" Value="Hand"/>
|
|
<Setter Property="VerticalAlignment" Value="Center"/>
|
|
<Setter Property="HorizontalAlignment" Value="Right"/>
|
|
<Setter Property="Margin" Value="0,0,15,0"/>
|
|
</Style>
|
|
</ResourceDictionary>
|
|
</UserControl.Resources>
|
|
<ScrollViewer ScrollChanged="ScrollViewerEx_ScrollChanged" IsManipulationEnabled="True" Name="ScrollViewerEx" IsDeferredScrollingEnabled="True" VerticalScrollBarVisibility="Visible" HorizontalScrollBarVisibility="Disabled" IsTabStop="False" TabIndex="-1" Margin="0,0,2,2">
|
|
<StackPanel Margin="60,12,60,24">
|
|
<!-- 基本设置 -->
|
|
<Border BorderBrush="#e6e6e6" BorderThickness="1.25,1.25,1.25,4" CornerRadius="8">
|
|
<StackPanel Orientation="Vertical" Margin="18,18,18,18">
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="显示修改随机点名名单的按钮" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="在随机点名窗口中显示修改名单的按钮" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<Border x:Name="ToggleSwitchDisplayRandWindowNamesInputBtn" Style="{StaticResource ToggleSwitchStyle}" Background="#3584e4" Tag="DisplayRandWindowNamesInputBtn" MouseLeftButtonDown="ToggleSwitch_Click">
|
|
<Border Width="19" Height="19" Background="White" CornerRadius="10" HorizontalAlignment="Right" VerticalAlignment="Center">
|
|
<Border.Effect>
|
|
<DropShadowEffect BlurRadius="4" Direction="-45" Color="Black" Opacity="0.3" ShadowDepth="0"/>
|
|
</Border.Effect>
|
|
</Border>
|
|
</Border>
|
|
</Grid>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="启用随机抽和单次抽按钮" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="在随机点名窗口中显示随机抽和单次抽按钮" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<Border x:Name="ToggleSwitchShowRandomAndSingleDraw" Style="{StaticResource ToggleSwitchStyle}" Background="#3584e4" Tag="ShowRandomAndSingleDraw" MouseLeftButtonDown="ToggleSwitch_Click">
|
|
<Border Width="19" Height="19" Background="White" CornerRadius="10" HorizontalAlignment="Right" VerticalAlignment="Center">
|
|
<Border.Effect>
|
|
<DropShadowEffect BlurRadius="4" Direction="-45" Color="Black" Opacity="0.3" ShadowDepth="0"/>
|
|
</Border.Effect>
|
|
</Border>
|
|
</Border>
|
|
</Grid>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="启用快抽悬浮按钮" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="启用快速抽人的悬浮按钮" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<Border x:Name="ToggleSwitchEnableQuickDraw" Style="{StaticResource ToggleSwitchStyle}" Background="#3584e4" Tag="EnableQuickDraw" MouseLeftButtonDown="ToggleSwitch_Click">
|
|
<Border Width="19" Height="19" Background="White" CornerRadius="10" HorizontalAlignment="Right" VerticalAlignment="Center">
|
|
<Border.Effect>
|
|
<DropShadowEffect BlurRadius="4" Direction="-45" Color="Black" Opacity="0.3" ShadowDepth="0"/>
|
|
</Border.Effect>
|
|
</Border>
|
|
</Border>
|
|
</Grid>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="直接调用外部点名" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="使用外部点名工具代替内置点名功能" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<Border x:Name="ToggleSwitchExternalCaller" Style="{StaticResource ToggleSwitchStyle}" Background="#e1e1e1" Tag="ExternalCaller" MouseLeftButtonDown="ToggleSwitch_Click">
|
|
<Border Width="19" Height="19" Background="White" CornerRadius="10" HorizontalAlignment="Left" VerticalAlignment="Center">
|
|
<Border.Effect>
|
|
<DropShadowEffect BlurRadius="4" Direction="-45" Color="Black" Opacity="0.3" ShadowDepth="0"/>
|
|
</Border.Effect>
|
|
</Border>
|
|
</Border>
|
|
</Grid>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<StackPanel Orientation="Vertical">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Top" HorizontalAlignment="Left" Margin="0,8,0,12">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="点名类型" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" TextWrapping="Wrap" Text="选择外部点名工具的类型" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<WrapPanel Orientation="Horizontal" Margin="0,0,0,8">
|
|
<Border x:Name="ExternalCallerTypeClassIslandBorder" Padding="13,7" CornerRadius="8" Background="#e1e1e1" Cursor="Hand" Tag="ExternalCallerType_ClassIsland" Margin="0,0,8,8" MouseLeftButtonDown="OptionButton_Click">
|
|
<TextBlock Foreground="#2e3436" FontSize="14" FontWeight="Bold" Text="ClassIsland点名"/>
|
|
</Border>
|
|
<Border x:Name="ExternalCallerTypeSecRandomBorder" Padding="13,7" CornerRadius="8" Cursor="Hand" Tag="ExternalCallerType_SecRandom" Margin="0,0,8,8" MouseLeftButtonDown="OptionButton_Click">
|
|
<TextBlock Foreground="#2e3436" FontSize="14" Text="SecRandom点名"/>
|
|
</Border>
|
|
<Border x:Name="ExternalCallerTypeNamePickerBorder" Padding="13,7" CornerRadius="8" Cursor="Hand" Tag="ExternalCallerType_NamePicker" Margin="0,0,8,8" MouseLeftButtonDown="OptionButton_Click">
|
|
<TextBlock Foreground="#2e3436" FontSize="14" Text="NamePicker点名"/>
|
|
</Border>
|
|
</WrapPanel>
|
|
</StackPanel>
|
|
</StackPanel>
|
|
</Border>
|
|
|
|
<!-- 窗口设置 -->
|
|
<Border Margin="0,25,0,0" BorderBrush="#e6e6e6" BorderThickness="1.25,1.25,1.25,4" CornerRadius="8">
|
|
<StackPanel Orientation="Vertical" Margin="18,18,18,18">
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="单次抽人窗口关闭延迟" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="设置单次抽人窗口自动关闭的延迟时间" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,15,0">
|
|
<Slider x:Name="RandWindowOnceCloseLatencySlider" Width="150" Minimum="0.5" Maximum="8" Value="2.5" TickFrequency="0.1" IsSnapToTickEnabled="True" ValueChanged="RandWindowOnceCloseLatencySlider_ValueChanged"/>
|
|
<TextBlock x:Name="RandWindowOnceCloseLatencyText" Text="2.5s" VerticalAlignment="Center" FontSize="14" Margin="12,0,0,0" Foreground="#2e3436"/>
|
|
</StackPanel>
|
|
</Grid>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="单次随机点名人数上限" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="设置单次随机点名最多抽取的人数" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,15,0">
|
|
<Slider x:Name="RandWindowOnceMaxStudentsSlider" Width="150" Minimum="0" Maximum="20" Value="10" TickFrequency="1" IsSnapToTickEnabled="True" ValueChanged="RandWindowOnceMaxStudentsSlider_ValueChanged"/>
|
|
<TextBlock x:Name="RandWindowOnceMaxStudentsText" Text="10" VerticalAlignment="Center" FontSize="14" Margin="12,0,0,0" Foreground="#2e3436"/>
|
|
</StackPanel>
|
|
</Grid>
|
|
</StackPanel>
|
|
</Border>
|
|
|
|
<!-- 新点名UI设置 -->
|
|
<Border Margin="0,25,0,0" BorderBrush="#e6e6e6" BorderThickness="1.25,1.25,1.25,4" CornerRadius="8">
|
|
<StackPanel Orientation="Vertical" Margin="18,18,18,18">
|
|
<TextBlock Text="新点名UI设置" FontWeight="Bold" Foreground="#2e3436" FontSize="18" Margin="0,0,0,12"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="启用新点名UI" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="使用新的点名界面设计" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<Border x:Name="ToggleSwitchUseNewRollCallUI" Style="{StaticResource ToggleSwitchStyle}" Background="#3584e4" Tag="UseNewRollCallUI" MouseLeftButtonDown="ToggleSwitch_Click">
|
|
<Border Width="19" Height="19" Background="White" CornerRadius="10" HorizontalAlignment="Right" VerticalAlignment="Center">
|
|
<Border.Effect>
|
|
<DropShadowEffect BlurRadius="4" Direction="-45" Color="Black" Opacity="0.3" ShadowDepth="0"/>
|
|
</Border.Effect>
|
|
</Border>
|
|
</Border>
|
|
</Grid>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="启用机器学习避免重复" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="使用机器学习算法避免重复抽取相同的人" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<Border x:Name="ToggleSwitchEnableMLAvoidance" Style="{StaticResource ToggleSwitchStyle}" Background="#3584e4" Tag="EnableMLAvoidance" MouseLeftButtonDown="ToggleSwitch_Click">
|
|
<Border Width="19" Height="19" Background="White" CornerRadius="10" HorizontalAlignment="Right" VerticalAlignment="Center">
|
|
<Border.Effect>
|
|
<DropShadowEffect BlurRadius="4" Direction="-45" Color="Black" Opacity="0.3" ShadowDepth="0"/>
|
|
</Border.Effect>
|
|
</Border>
|
|
</Border>
|
|
</Grid>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="避免重复历史记录数量" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="设置用于避免重复的历史记录数量" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,15,0">
|
|
<Slider x:Name="MLAvoidanceHistorySlider" Width="150" Minimum="5" Maximum="50" Value="50" TickFrequency="5" IsSnapToTickEnabled="True" ValueChanged="MLAvoidanceHistorySlider_ValueChanged"/>
|
|
<TextBlock x:Name="MLAvoidanceHistoryText" Text="50" VerticalAlignment="Center" FontSize="14" Margin="12,0,0,0" Foreground="#2e3436"/>
|
|
</StackPanel>
|
|
</Grid>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Vertical" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="避免重复权重" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="设置机器学习算法避免重复的权重" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,15,0">
|
|
<Slider x:Name="MLAvoidanceWeightSlider" Width="150" Minimum="0.1" Maximum="1.0" Value="1.0" TickFrequency="0.1" IsSnapToTickEnabled="True" ValueChanged="MLAvoidanceWeightSlider_ValueChanged"/>
|
|
<TextBlock x:Name="MLAvoidanceWeightText" Text="100%" VerticalAlignment="Center" FontSize="14" Margin="12,0,0,0" Foreground="#2e3436" FontFamily="Consolas"/>
|
|
</StackPanel>
|
|
</Grid>
|
|
<TextBlock Text="机器学习算法会分析最近的点名历史,智能避免重复选择相同人员"
|
|
TextWrapping="Wrap" Foreground="#9a9996" FontSize="11" Margin="0,8,0,0"/>
|
|
</StackPanel>
|
|
</Border>
|
|
|
|
<!-- 背景设置 -->
|
|
<Border Margin="0,25,0,0" BorderBrush="#e6e6e6" BorderThickness="1.25,1.25,1.25,4" CornerRadius="8">
|
|
<StackPanel Orientation="Vertical" Margin="18,18,18,18">
|
|
<TextBlock Text="点名窗口背景设置(仅老版点名UI有效)" FontWeight="Bold" Foreground="#2e3436" FontSize="18" Margin="0,0,0,12"/>
|
|
<StackPanel Margin="18,8,18,8">
|
|
<StackPanel Orientation="Vertical" Margin="0,0,0,12">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="背景选择" HorizontalAlignment="Left"/>
|
|
<TextBlock Foreground="#9a9996" FontSize="11" Margin="0,3.5,0,0" Text="选择点名窗口的背景" HorizontalAlignment="Left"/>
|
|
</StackPanel>
|
|
<WrapPanel Orientation="Horizontal">
|
|
<Border x:Name="PickNameBackgroundDefaultBorder" Padding="13,7" CornerRadius="8" Background="#e1e1e1" Cursor="Hand" Tag="PickNameBackground_Default" Margin="0,0,8,8" MouseLeftButtonDown="OptionButton_Click">
|
|
<TextBlock Foreground="#2e3436" FontSize="14" FontWeight="Bold" Text="默认背景"/>
|
|
</Border>
|
|
</WrapPanel>
|
|
</StackPanel>
|
|
<Border Height="1" Background="#ebebeb" Margin="0,8,0,8"/>
|
|
<Grid Height="54">
|
|
<StackPanel Orientation="Horizontal" VerticalAlignment="Center" HorizontalAlignment="Left">
|
|
<TextBlock Foreground="#2e3436" FontSize="14.5" Text="自定义背景" HorizontalAlignment="Left" Margin="0,0,12,0"/>
|
|
<Button x:Name="ButtonAddCustomBackground" Content="上传" Padding="10,3"/>
|
|
<Button x:Name="ButtonManageBackgrounds" Content="管理" Padding="10,3" Margin="5,0,0,0"/>
|
|
</StackPanel>
|
|
</Grid>
|
|
</StackPanel>
|
|
</Border>
|
|
</StackPanel>
|
|
</ScrollViewer>
|
|
</UserControl>
|