Repository navigation
Expand file tree
/
Copy pathPostProcessingWindow.xaml
More file actions
88 lines (80 loc) · 5.59 KB
/
Copy pathPostProcessingWindow.xaml
File metadata and controls
88 lines (80 loc) · 5.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
<Window x:Class="WhisperTyper.PostProcessingWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="Post-Processing Settings" Height="500" Width="600"
Background="#0E0B16" Foreground="#F3F0FC" WindowStartupLocation="CenterOwner"
ResizeMode="NoResize" WindowStyle="None" AllowsTransparency="True">
<Window.Resources>
<!-- Re-using styles from MainWindow for consistency -->
<Style x:Key="ModernButton" TargetType="Button">
<Setter Property="Background" Value="#8B5CF6"/>
<Setter Property="Foreground" Value="#FFFFFF"/>
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="Height" Value="32"/>
<Setter Property="Padding" Value="15,5"/>
<Setter Property="FontWeight" Value="SemiBold"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="border" Background="{TemplateBinding Background}" CornerRadius="6">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" Margin="{TemplateBinding Padding}"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True"><Setter TargetName="border" Property="Background" Value="#A78BFA"/><Setter Property="Cursor" Value="Hand"/></Trigger>
<Trigger Property="IsPressed" Value="True"><Setter TargetName="border" Property="Background" Value="#7C3AED"/></Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style x:Key="SecondaryButton" TargetType="Button" BasedOn="{StaticResource ModernButton}">
<Setter Property="Background" Value="#2D283E"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border x:Name="border" Background="{TemplateBinding Background}" BorderBrush="#3B2A66" BorderThickness="1" CornerRadius="6">
<ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" Margin="{TemplateBinding Padding}"/>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True"><Setter TargetName="border" Property="Background" Value="#3B2A66"/><Setter Property="Cursor" Value="Hand"/></Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</Window.Resources>
<Border BorderBrush="#3B2A66" BorderThickness="1" CornerRadius="12" Background="#0E0B16">
<Grid Margin="20">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<StackPanel Grid.Row="0" Margin="0,0,0,20">
<TextBlock Text="LLM Post-Processing" FontSize="20" FontWeight="Bold" Foreground="#FFFFFF"/>
<TextBlock Text="Refine transcription using Ollama or LM Studio" FontSize="11" Foreground="#9E9AA8"/>
</StackPanel>
<ScrollViewer Grid.Row="1" VerticalScrollBarVisibility="Auto">
<StackPanel>
<CheckBox x:Name="ChkEnabled" Content="Enable LLM Post-Processing" Foreground="#FFFFFF" Margin="0,0,0,15" FontSize="12" FontWeight="SemiBold"/>
<TextBlock Text="LLM Provider" FontSize="11" Foreground="#9E9AA8" Margin="0,0,0,5"/>
<ComboBox x:Name="ComboProvider" Height="32" Margin="0,0,0,15" SelectionChanged="ComboProvider_SelectionChanged">
<ComboBoxItem Content="Use Default"/>
<ComboBoxItem Content="Ollama"/>
<ComboBoxItem Content="LM Studio (OpenAI Compatible)"/>
</ComboBox>
<TextBlock Text="API Endpoint" FontSize="11" Foreground="#9E9AA8" Margin="0,0,0,5"/>
<TextBox x:Name="TxtEndpoint" Background="#161127" Foreground="#FFFFFF" BorderBrush="#3B2A66" BorderThickness="1" Height="32" Padding="8,5" Margin="0,0,0,15"/>
<TextBlock Text="Model Name" FontSize="11" Foreground="#9E9AA8" Margin="0,0,0,5"/>
<TextBox x:Name="TxtModel" Background="#161127" Foreground="#FFFFFF" BorderBrush="#3B2A66" BorderThickness="1" Height="32" Padding="8,5" Margin="0,0,0,15"/>
<TextBlock Text="Custom Prompt (use {text} for transcription)" FontSize="11" Foreground="#9E9AA8" Margin="0,0,0,5"/>
<TextBox x:Name="TxtPrompt" Background="#161127" Foreground="#FFFFFF" BorderBrush="#3B2A66" BorderThickness="1" Height="100" Padding="8,5" TextWrapping="Wrap" AcceptsReturn="True" Margin="0,0,0,15"/>
</StackPanel>
</ScrollViewer>
<StackPanel Grid.Row="2" Orientation="Horizontal" HorizontalAlignment="Right" Margin="0,10,0,0">
<Button Content="Cancel" Click="BtnCancel_Click" Style="{StaticResource SecondaryButton}" Margin="0,0,10,0" Width="100"/>
<Button Content="Save" Click="BtnSave_Click" Style="{StaticResource ModernButton}" Width="100"/>
</StackPanel>
</Grid>
</Border>
</Window>