fix(ui): make cut-off button labels and input hints readable (#10292)

* fix(ui): let update and backup buttons fit their labels

The update dialog gives its two buttons a fixed 100 px width, and the
backup view puts its buttons in a fixed 200 px grid column, so longer
labels are cut off, for example "Only Chec", "Check and" and "Backup
to remote (WebD" in English. Use MinWidth="100" for the update buttons
and an Auto column with MinWidth="200" for the backup buttons: short
labels keep their current size and long ones fit.

The "Automatic update interval (minutes)" label of the subscription
window is cut off the same way between the switch and the interval
field, so let it wrap.

* fix(ui): show cut-off input hints as tooltips

The hints of the previous and next proxy remarks fields in the
subscription window and of the server and log filters are wider than
their fields, so their end is cut off and there is no way to read it.
Show the same text as a tooltip, as the custom config socks port field
of the subscription window already does.

* fix(ui): let dialog buttons and backup labels fit longer translations

The Confirm and Cancel buttons of the editing and settings windows,
and the Reset button of the hotkey window, have a fixed 100 px width,
and the backup view puts its labels in a fixed 300 px column.
Translations longer than the English text are cut off there: the
Russian "Подтвердить" reads "Подтверди", and "Резервное копирование
на удалённый сервер (WebDAV)" loses its end. Use MinWidth="100" for
these buttons, as the message box already does with MinWidth="90",
and an Auto label column with MinWidth="300".
This commit is contained in:
Miheichev Aleksandr Sergeevich
2026-10-05 08:27:19 +00:00
committed by GitHub
parent 3187eeef79
commit 6152cab494
31 changed files with 90 additions and 76 deletions
@@ -24,12 +24,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -23,12 +23,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -24,12 +24,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -30,10 +30,11 @@
VerticalAlignment="Center"
Theme="{DynamicResource CardBorder}">
<Grid
Margin="{StaticResource Margin4}"
ColumnDefinitions="300,200"
RowDefinitions="Auto,Auto,Auto,Auto">
<Grid Margin="{StaticResource Margin4}" RowDefinitions="Auto,Auto,Auto,Auto">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" MinWidth="300" />
<ColumnDefinition Width="Auto" MinWidth="200" />
</Grid.ColumnDefinitions>
<TextBlock
Grid.Row="0"
Grid.Column="0"
@@ -79,10 +80,11 @@
Margin="{StaticResource Margin4}"
VerticalAlignment="Center"
Theme="{DynamicResource CardBorder}">
<Grid
Margin="{StaticResource Margin4}"
ColumnDefinitions="300,200"
RowDefinitions="Auto,Auto,Auto,Auto,Auto">
<Grid Margin="{StaticResource Margin4}" RowDefinitions="Auto,Auto,Auto,Auto,Auto">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" MinWidth="300" />
<ColumnDefinition Width="Auto" MinWidth="200" />
</Grid.ColumnDefinitions>
<StackPanel
Grid.Row="0"
Grid.Column="0"
@@ -37,13 +37,13 @@
<Button
x:Name="btnCheckOnly"
Width="100"
MinWidth="100"
Margin="{StaticResource Margin4}"
Content="{x:Static resx:ResUI.menuCheckOnly}" />
<Button
x:Name="btnCheckUpdate"
Width="100"
MinWidth="100"
Margin="{StaticResource Margin4}"
Content="{x:Static resx:ResUI.menuCheckAndUpdate}" />
</StackPanel>
@@ -24,12 +24,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -24,12 +24,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -23,17 +23,17 @@
Orientation="Horizontal">
<Button
x:Name="btnReset"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbReset}" />
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
+2 -1
View File
@@ -23,7 +23,8 @@
Width="200"
Margin="{StaticResource MarginLr8}"
VerticalContentAlignment="Center"
PlaceholderText="{x:Static resx:ResUI.MsgFilterTitle}" />
PlaceholderText="{x:Static resx:ResUI.MsgFilterTitle}"
ToolTip.Tip="{x:Static resx:ResUI.MsgFilterTitle}" />
<Button
x:Name="btnCopy"
@@ -23,12 +23,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -28,12 +28,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -72,7 +72,8 @@
Margin="{StaticResource MarginLr4}"
VerticalContentAlignment="Center"
Text="{Binding ServerFilter, Mode=TwoWay}"
PlaceholderText="{x:Static resx:ResUI.MsgServerTitle}" />
PlaceholderText="{x:Static resx:ResUI.MsgServerTitle}"
ToolTip.Tip="{x:Static resx:ResUI.MsgServerTitle}" />
</WrapPanel>
<!-- Profiles grid -->
@@ -66,7 +66,8 @@
Width="200"
Margin="{StaticResource MarginLr4}"
VerticalContentAlignment="Center"
PlaceholderText="{x:Static resx:ResUI.MsgServerTitle}" />
PlaceholderText="{x:Static resx:ResUI.MsgServerTitle}"
ToolTip.Tip="{x:Static resx:ResUI.MsgServerTitle}" />
<Button
x:Name="btnAutofitColumnWidth"
@@ -208,12 +208,12 @@
</StackPanel>
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -30,12 +30,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -22,12 +22,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -136,7 +136,8 @@
Margin="{StaticResource Margin4}"
HorizontalAlignment="Center"
VerticalAlignment="Center"
Text="{x:Static resx:ResUI.LvAutoUpdateInterval}" />
Text="{x:Static resx:ResUI.LvAutoUpdateInterval}"
TextWrapping="Wrap" />
</DockPanel>
<TextBlock
@@ -230,7 +231,8 @@
Grid.Column="1"
Margin="{StaticResource Margin4}"
VerticalAlignment="Center"
PlaceholderText="{x:Static resx:ResUI.LvPrevProfileTip}" />
PlaceholderText="{x:Static resx:ResUI.LvPrevProfileTip}"
ToolTip.Tip="{x:Static resx:ResUI.LvPrevProfileTip}" />
<Button
x:Name="btnSelectPrevProfile"
Grid.Row="10"
@@ -250,7 +252,8 @@
Grid.Column="1"
Margin="{StaticResource Margin4}"
VerticalAlignment="Center"
PlaceholderText="{x:Static resx:ResUI.LvPrevProfileTip}" />
PlaceholderText="{x:Static resx:ResUI.LvPrevProfileTip}"
ToolTip.Tip="{x:Static resx:ResUI.LvPrevProfileTip}" />
<Button
x:Name="btnSelectNextProfile"
Grid.Row="11"
@@ -20,12 +20,12 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLr8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="True" />
@@ -27,13 +27,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
+2 -2
View File
@@ -25,13 +25,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
+2 -2
View File
@@ -33,13 +33,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
@@ -40,8 +40,8 @@
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="300" />
<ColumnDefinition Width="200" />
<ColumnDefinition Width="Auto" MinWidth="300" />
<ColumnDefinition Width="Auto" MinWidth="200" />
</Grid.ColumnDefinitions>
<TextBlock
Grid.Row="0"
@@ -98,8 +98,8 @@
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="300" />
<ColumnDefinition Width="200" />
<ColumnDefinition Width="Auto" MinWidth="300" />
<ColumnDefinition Width="Auto" MinWidth="200" />
</Grid.ColumnDefinitions>
<StackPanel Orientation="Horizontal">
<TextBlock
+2 -2
View File
@@ -36,14 +36,14 @@
<Button
x:Name="btnCheckOnly"
Width="100"
MinWidth="100"
Margin="{StaticResource Margin8}"
Content="{x:Static resx:ResUI.menuCheckOnly}"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCheckUpdate"
Width="100"
MinWidth="100"
Margin="{StaticResource Margin8}"
Content="{x:Static resx:ResUI.menuCheckAndUpdate}"
IsDefault="True"
+2 -2
View File
@@ -25,13 +25,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
@@ -25,13 +25,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
@@ -25,19 +25,19 @@
Orientation="Horizontal">
<Button
x:Name="btnReset"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbReset}"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
+2 -1
View File
@@ -28,7 +28,8 @@
materialDesign:TextFieldAssist.HasClearButton="True"
AutomationProperties.Name="{x:Static resx:ResUI.MsgFilterTitle}"
IsEditable="True"
Style="{StaticResource DefComboBox}" />
Style="{StaticResource DefComboBox}"
ToolTip="{x:Static resx:ResUI.MsgFilterTitle}" />
<Button
x:Name="btnCopy"
Width="24"
+2 -2
View File
@@ -32,13 +32,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
@@ -30,13 +30,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
@@ -77,7 +77,8 @@
materialDesign:HintAssist.Hint="{x:Static resx:ResUI.MsgServerTitle}"
materialDesign:TextFieldAssist.HasClearButton="True"
AutomationProperties.Name="{x:Static resx:ResUI.MsgServerTitle}"
Style="{StaticResource DefTextBox}" />
Style="{StaticResource DefTextBox}"
ToolTip="{x:Static resx:ResUI.MsgServerTitle}" />
</WrapPanel>
<DataGrid
x:Name="lstProfiles"
+2 -1
View File
@@ -65,7 +65,8 @@
materialDesign:HintAssist.Hint="{x:Static resx:ResUI.MsgServerTitle}"
materialDesign:TextFieldAssist.HasClearButton="True"
AutomationProperties.Name="{x:Static resx:ResUI.MsgServerTitle}"
Style="{StaticResource DefTextBox}" />
Style="{StaticResource DefTextBox}"
ToolTip="{x:Static resx:ResUI.MsgServerTitle}" />
<Button
x:Name="btnAutofitColumnWidth"
@@ -237,13 +237,13 @@
</StackPanel>
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
@@ -74,13 +74,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
+8 -5
View File
@@ -32,13 +32,13 @@
Orientation="Horizontal">
<Button
x:Name="btnSave"
Width="100"
MinWidth="100"
Content="{x:Static resx:ResUI.TbConfirm}"
IsDefault="True"
Style="{StaticResource DefButton}" />
<Button
x:Name="btnCancel"
Width="100"
MinWidth="100"
Margin="{StaticResource MarginLeftRight8}"
Content="{x:Static resx:ResUI.TbCancel}"
IsCancel="true"
@@ -174,7 +174,8 @@
HorizontalAlignment="Center"
VerticalAlignment="Center"
Style="{StaticResource ToolbarTextBlock}"
Text="{x:Static resx:ResUI.LvAutoUpdateInterval}" />
Text="{x:Static resx:ResUI.LvAutoUpdateInterval}"
TextWrapping="Wrap" />
</DockPanel>
<TextBlock
@@ -282,7 +283,8 @@
VerticalAlignment="Center"
materialDesign:HintAssist.Hint="{x:Static resx:ResUI.LvPrevProfileTip}"
AcceptsReturn="True"
Style="{StaticResource MyOutlinedTextBox}" />
Style="{StaticResource MyOutlinedTextBox}"
ToolTip="{x:Static resx:ResUI.LvPrevProfileTip}" />
<Button
x:Name="btnSelectPrevProfile"
Grid.Row="10"
@@ -307,7 +309,8 @@
VerticalAlignment="Center"
materialDesign:HintAssist.Hint="{x:Static resx:ResUI.LvPrevProfileTip}"
AcceptsReturn="True"
Style="{StaticResource MyOutlinedTextBox}" />
Style="{StaticResource MyOutlinedTextBox}"
ToolTip="{x:Static resx:ResUI.LvPrevProfileTip}" />
<Button
x:Name="btnSelectNextProfile"
Grid.Row="11"