Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/SockTuner/App.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
<Style x:Key="AppWindowStyle" TargetType="Window">
<Setter Property="Background" Value="{StaticResource PageBrush}"/>
<Setter Property="Foreground" Value="{StaticResource TextBrush}"/>
<Setter Property="FontFamily" Value="Segoe UI"/>
<Setter Property="FontFamily" Value="Segoe UI, Microsoft YaHei UI, Segoe UI Emoji"/>
<Setter Property="FontSize" Value="13"/>
<Setter Property="TextOptions.TextFormattingMode" Value="Display"/>
<Setter Property="UseLayoutRounding" Value="True"/>
Expand Down
4 changes: 4 additions & 0 deletions src/SockTuner/App.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ protected override void OnStartup(StartupEventArgs e)
return;
}

// Before the window is built: UiTranslator rewrites what XAML produced, so the language
// has to be settled first. The console modes above stay English — they answer a terminal.
Loc.Use(AppPreferences.Load().Language);

MainWindow = new MainWindow();
MainWindow.Show();
}
Expand Down
3,177 changes: 3,177 additions & 0 deletions src/SockTuner/Assets/i18n/translations.json

Large diffs are not rendered by default.

22 changes: 16 additions & 6 deletions src/SockTuner/MainWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -138,17 +138,17 @@
<Border Style="{StaticResource Card}" Margin="0,0,12,0">
<StackPanel>
<TextBlock Text="System baseline" FontSize="18" FontWeight="SemiBold"/>
<TextBlock Text="Current read-only system facts. No setting is changed during discovery." Foreground="{StaticResource MutedTextBrush}" Margin="0,5,0,18"/>
<TextBlock Text="Current read-only system facts. No setting is changed during discovery." Foreground="{StaticResource MutedTextBrush}" TextWrapping="Wrap" Margin="0,5,0,18"/>
<Grid>
<Grid.ColumnDefinitions><ColumnDefinition Width="150"/><ColumnDefinition/></Grid.ColumnDefinitions>
<Grid.ColumnDefinitions><ColumnDefinition Width="Auto" MinWidth="150"/><ColumnDefinition/></Grid.ColumnDefinitions>
<Grid.RowDefinitions><RowDefinition/><RowDefinition/><RowDefinition/><RowDefinition/></Grid.RowDefinitions>
<TextBlock Text="Operating system" Foreground="{StaticResource MutedTextBrush}" Margin="0,5"/>
<TextBlock Text="Operating system" Foreground="{StaticResource MutedTextBrush}" Margin="0,5,16,5"/>
<TextBlock x:Name="OsText" Grid.Column="1" Text="Loading…" Margin="0,5"/>
<TextBlock Grid.Row="1" Text="Build" Foreground="{StaticResource MutedTextBrush}" Margin="0,5"/>
<TextBlock Grid.Row="1" Text="Build" Foreground="{StaticResource MutedTextBrush}" Margin="0,5,16,5"/>
<TextBlock x:Name="BuildText" Grid.Row="1" Grid.Column="1" Text="—" Margin="0,5"/>
<TextBlock Grid.Row="2" Text="Computer" Foreground="{StaticResource MutedTextBrush}" Margin="0,5"/>
<TextBlock Grid.Row="2" Text="Computer" Foreground="{StaticResource MutedTextBrush}" Margin="0,5,16,5"/>
<TextBlock x:Name="MachineText" Grid.Row="2" Grid.Column="1" Text="—" Margin="0,5"/>
<TextBlock Grid.Row="3" Text="Captured" Foreground="{StaticResource MutedTextBrush}" Margin="0,5"/>
<TextBlock Grid.Row="3" Text="Captured" Foreground="{StaticResource MutedTextBrush}" Margin="0,5,16,5"/>
<TextBlock x:Name="CapturedText" Grid.Row="3" Grid.Column="1" Text="—" Margin="0,5"/>
</Grid>
</StackPanel>
Expand Down Expand Up @@ -1294,6 +1294,16 @@

<TabItem Header="Preferences">
<StackPanel Margin="0,20,0,0" HorizontalAlignment="Stretch">
<TextBlock Text="Language" FontSize="22" FontWeight="SemiBold"/>
<TextBlock Text="Interface language. Measurements, findings and log entries stay in English."
Foreground="{StaticResource MutedTextBrush}" TextWrapping="Wrap" Margin="0,6,0,16"/>
<StackPanel Orientation="Horizontal" MaxWidth="620" HorizontalAlignment="Left" Margin="0,0,0,26">
<TextBlock Text="Display language" VerticalAlignment="Center" Margin="0,0,12,0"/>
<ComboBox x:Name="LanguageComboBox" Width="200"
SelectionChanged="Language_SelectionChanged"
AutomationProperties.Name="Display language"/>
</StackPanel>

<TextBlock Text="Local retention" FontSize="22" FontWeight="SemiBold"/>
<TextBlock Text="SockTuner keeps the current log plus one rotated file. Choose the maximum size of each file."
Foreground="{StaticResource MutedTextBrush}" TextWrapping="Wrap" Margin="0,6,0,16"/>
Expand Down
Loading