Skip to content

Commit

Permalink
Rename keyboard layout to input language
Browse files Browse the repository at this point in the history
  • Loading branch information
dremin committed Feb 20, 2024
1 parent e039dd3 commit fd65a55
Show file tree
Hide file tree
Showing 25 changed files with 56 additions and 56 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<UserControl x:Class="RetroBar.Controls.KeyboardLayout"
<UserControl x:Class="RetroBar.Controls.InputLanguage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:converters="clr-namespace:RetroBar.Converters"
Expand All @@ -20,7 +20,7 @@
RelativeSource="{RelativeSource Mode=FindAncestor, AncestorType=Window}" />
</DockPanel.Dock>
</Thumb>
<TextBlock Style="{DynamicResource KeyboardLayout}"
<TextBlock Style="{DynamicResource InputLanguage}"
Text="{Binding Path=LocaleIdentifierProperty, Converter={StaticResource cultureInfoToLocaleNameConverter}, ConverterParameter=TwoLetterIsoLanguageName, Mode=OneWay}">
</TextBlock>
</DockPanel>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@

namespace RetroBar.Controls
{
public partial class KeyboardLayout : UserControl
public partial class InputLanguage : UserControl
{
public static DependencyProperty LocaleIdentifierProperty = DependencyProperty.Register("LocaleIdentifierProperty", typeof(CultureInfo), typeof(KeyboardLayout));
public static DependencyProperty LocaleIdentifierProperty = DependencyProperty.Register("LocaleIdentifierProperty", typeof(CultureInfo), typeof(InputLanguage));

public CultureInfo LocaleIdentifier
{
Expand All @@ -22,7 +22,7 @@ public CultureInfo LocaleIdentifier

private bool _isLoaded;

public KeyboardLayout()
public InputLanguage()
{
InitializeComponent();
DataContext = this;
Expand All @@ -33,7 +33,7 @@ public KeyboardLayout()

private void Initialize()
{
if (Settings.Instance.ShowKeyboardLayout)
if (Settings.Instance.ShowInputLanguage)
{
StartWatch();
}
Expand Down Expand Up @@ -74,9 +74,9 @@ private void StopWatch()

private void Settings_PropertyChanged(object sender, System.ComponentModel.PropertyChangedEventArgs e)
{
if (e.PropertyName == "ShowKeyboardLayout")
if (e.PropertyName == "ShowInputLanguage")
{
if (Settings.Instance.ShowKeyboardLayout)
if (Settings.Instance.ShowInputLanguage)
{
StartWatch();
}
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Languages/English.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<s:String x:Key="allow_font_smoothing">_Allow font smoothing</s:String>
<s:String x:Key="collapse_tray_icons">Collapse _notification area icons</s:String>
<s:String x:Key="customize">_Customize...</s:String>
<s:String x:Key="show_keyboard_layout">Show the keyboard _layout</s:String>
<s:String x:Key="show_input_language">Show the input _language</s:String>
<s:String x:Key="show_clock">Show the cloc_k</s:String>
<s:String x:Key="show_multi_mon">Show on _multiple displays</s:String>
<s:String x:Key="show_quick_launch">Show _Quick Launch</s:String>
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Languages/Türkçe.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<s:String x:Key="allow_font_smoothing">_Yazı tipi yumuşatmaya izin ver</s:String>
<s:String x:Key="collapse_tray_icons">Bildirim _alanı simgelerini daralt</s:String>
<s:String x:Key="customize">Ö_zelleştir...</s:String>
<s:String x:Key="show_keyboard_layout">_Klavye düzenini göster</s:String>
<s:String x:Key="show_input_language">_Klavye düzenini göster</s:String>
<s:String x:Key="show_clock">_Saati göster</s:String>
<s:String x:Key="show_multi_mon">Birden çok _ekranda göster</s:String>
<s:String x:Key="show_quick_launch">_Hızlı Başlat'ı Göster</s:String>
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Languages/hrvatski.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<s:String x:Key="allow_font_smoothing">_Dopusti izglađivanje fonta</s:String>
<s:String x:Key="collapse_tray_icons">Sakriji neaktivne ikone</s:String>
<s:String x:Key="customize">Prilagod_i...</s:String>
<s:String x:Key="show_keyboard_layout">Prikaži raspored _tipkovnice</s:String>
<s:String x:Key="show_input_language">Prikaži raspored _tipkovnice</s:String>
<s:String x:Key="show_clock">Prikaži _sat</s:String>
<s:String x:Key="show_multi_mon">Prikaži _na više zaslona</s:String>
<s:String x:Key="show_quick_launch">Prika_ži brzo pokretanje</s:String>
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Languages/srpski.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<s:String x:Key="allow_font_smoothing">Dozvoli izglađivanje _fontova</s:String>
<s:String x:Key="collapse_tray_icons">Skupi _ikonice u sistemskoj paleti</s:String>
<s:String x:Key="customize">Prilago_di...</s:String>
<s:String x:Key="show_keyboard_layout">Prikaži raspored _tastature</s:String>
<s:String x:Key="show_input_language">Prikaži raspored _tastature</s:String>
<s:String x:Key="show_clock">Prikaži _sat</s:String>
<s:String x:Key="show_multi_mon">Prikaži na _više ekrana</s:String>
<s:String x:Key="show_quick_launch">Prikaži _brzo pokretanje</s:String>
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Languages/русский.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<s:String x:Key="allow_font_smoothing">Пр_именять сглаживание шрифтов</s:String>
<s:String x:Key="collapse_tray_icons">Скр_ывать неиспользуемые значки</s:String>
<s:String x:Key="customize">_Настроить...</s:String>
<s:String x:Key="show_keyboard_layout">Отображать раскладку _клавиатуры</s:String>
<s:String x:Key="show_input_language">Отображать раскладку _клавиатуры</s:String>
<s:String x:Key="show_clock">Отображать _часы</s:String>
<s:String x:Key="show_multi_mon">Показывать на н_ескольких дисплеях</s:String>
<s:String x:Key="show_quick_launch">Отображать панель _быстого запуска</s:String>
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Languages/српски.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<s:String x:Key="allow_font_smoothing">Дозволи изглађивање _фонтова</s:String>
<s:String x:Key="collapse_tray_icons">Скупи _иконице у системској палети</s:String>
<s:String x:Key="customize">Прилаго_ди...</s:String>
<s:String x:Key="show_keyboard_layout">Прикажи распоред _тастатуре</s:String>
<s:String x:Key="show_input_language">Прикажи распоред _тастатуре</s:String>
<s:String x:Key="show_clock">Прикажи _сат</s:String>
<s:String x:Key="show_multi_mon">Прикажи на _више екрана</s:String>
<s:String x:Key="show_quick_launch">Прикажи _брзо покретање</s:String>
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Languages/українська.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<s:String x:Key="allow_font_smoothing">Згладжування шрифту</s:String>
<s:String x:Key="collapse_tray_icons">Згорнути іконки панелі сповіщень</s:String>
<s:String x:Key="customize">Змінити...</s:String>
<s:String x:Key="show_keyboard_layout">Показати розкладку _клавіатури</s:String>
<s:String x:Key="show_input_language">Показати розкладку _клавіатури</s:String>
<s:String x:Key="show_clock">Показати годинник</s:String>
<s:String x:Key="show_multi_mon">Показати на усіх дисплеях</s:String>
<s:String x:Key="show_quick_launch">Показати ікони швидкого запуску</s:String>
Expand Down
10 changes: 5 additions & 5 deletions RetroBar/PropertiesWindow.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -267,19 +267,19 @@
<controls:Clock VerticalAlignment="Center" />
</StackPanel>
</GroupBox>
<controls:KeyboardLayout VerticalAlignment="Stretch" DockPanel.Dock="Right" />
<controls:InputLanguage VerticalAlignment="Stretch" DockPanel.Dock="Right" />
<StackPanel></StackPanel>
</DockPanel>
</ContentControl>
</Border>
<CheckBox x:Name="cbShowKeyboardLayout"
IsChecked="{Binding Source={x:Static Settings:Settings.Instance}, Path=ShowKeyboardLayout, UpdateSourceTrigger=PropertyChanged}">
<Label Content="{DynamicResource show_keyboard_layout}" />
</CheckBox>
<CheckBox x:Name="cbShowClock"
IsChecked="{Binding Source={x:Static Settings:Settings.Instance}, Path=ShowClock, UpdateSourceTrigger=PropertyChanged}">
<Label Content="{DynamicResource show_clock}" />
</CheckBox>
<CheckBox x:Name="cbShowInputLanguage"
IsChecked="{Binding Source={x:Static Settings:Settings.Instance}, Path=ShowInputLanguage, UpdateSourceTrigger=PropertyChanged}">
<Label Content="{DynamicResource show_input_language}" />
</CheckBox>
<CheckBox x:Name="cbShowDesktopButton"
IsChecked="{Binding Source={x:Static Settings:Settings.Instance}, Path=ShowDesktopButton, UpdateSourceTrigger=PropertyChanged}">
<Label Content="{DynamicResource add_show_desktop_button}" />
Expand Down
4 changes: 2 additions & 2 deletions RetroBar/Taskbar.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -102,15 +102,15 @@
PreviewMouseRightButtonUp="Clock_PreviewMouseRightButtonUp" />
</StackPanel>
</GroupBox>
<controls:KeyboardLayout VerticalAlignment="Stretch"
<controls:InputLanguage VerticalAlignment="Stretch"
HorizontalAlignment="Stretch">
<DockPanel.Dock>
<Binding Converter="{StaticResource dockOrientationConverter}"
ConverterParameter="trailing"
Path="Orientation"
RelativeSource="{RelativeSource Mode=FindAncestor, AncestorType=Window}" />
</DockPanel.Dock>
</controls:KeyboardLayout>
</controls:InputLanguage>
<controls:TaskList VerticalAlignment="Stretch"
Host="{Binding RelativeSource={RelativeSource Mode=FindAncestor, AncestorType=Window}}"
Tasks="{Binding Tasks}"></controls:TaskList>
Expand Down
10 changes: 5 additions & 5 deletions RetroBar/Themes/System.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
<SolidColorBrush x:Key="ButtonForeground" Color="{x:Static SystemColors.ControlTextColor}" />
<SolidColorBrush x:Key="ButtonFlashingForeground" Color="{x:Static SystemColors.HighlightTextColor}" />
<SolidColorBrush x:Key="ClockForeground" Color="{x:Static SystemColors.ControlTextColor}" />
<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="{x:Static SystemColors.HighlightTextColor}" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="{x:Static SystemColors.HighlightColor}" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="{x:Static SystemColors.HighlightTextColor}" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="{x:Static SystemColors.HighlightColor}" />

<SolidColorBrush x:Key="ToolTipBackground" Color="{x:Static SystemColors.InfoColor}" />
<SolidColorBrush x:Key="ToolTipForeground" Color="{x:Static SystemColors.InfoTextColor}" />
Expand Down Expand Up @@ -845,12 +845,12 @@
</ControlTemplate>

<Style TargetType="TextBlock"
x:Key="KeyboardLayout"
x:Key="InputLanguage"
BasedOn="{StaticResource GlobalFonts}">
<Setter Property="Foreground"
Value="{DynamicResource KeyboardLayoutForeground}" />
Value="{DynamicResource InputLanguageForeground}" />
<Setter Property="Background"
Value="{DynamicResource KeyboardLayoutBackground}"/>
Value="{DynamicResource InputLanguageBackground}"/>
<Setter Property="MinWidth"
Value="16"/>
<Setter Property="Height"
Expand Down
4 changes: 2 additions & 2 deletions RetroBar/Themes/Watercolor.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@
<SolidColorBrush x:Key="ButtonPressedForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ClockForeground" Color="#000000" />

<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#316ac5" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="#ffffff" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#316ac5" />

<SolidColorBrush x:Key="ToolTipBackground" Color="#FFFFE1" />
<SolidColorBrush x:Key="ToolTipForeground" Color="#000000" />
Expand Down
4 changes: 2 additions & 2 deletions RetroBar/Themes/Windows 2000.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
<SolidColorBrush x:Key="ButtonFlashingForeground" Color="#FFFFFF" />
<SolidColorBrush x:Key="ClockForeground" Color="#000000" />

<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#0A246A" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="#ffffff" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#0A246A" />

<SolidColorBrush x:Key="ToolTipBackground" Color="#FFFFE1" />
<SolidColorBrush x:Key="ToolTipForeground" Color="#000000" />
Expand Down
4 changes: 2 additions & 2 deletions RetroBar/Themes/Windows 95-98.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
<SolidColorBrush x:Key="ButtonFlashingForeground" Color="#FFFFFF" />
<SolidColorBrush x:Key="ClockForeground" Color="#000000" />

<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#000080" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="#ffffff" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#000080" />

<SolidColorBrush x:Key="ToolTipBackground" Color="#FFFFE1" />
<SolidColorBrush x:Key="ToolTipForeground" Color="#000000" />
Expand Down
8 changes: 4 additions & 4 deletions RetroBar/Themes/Windows Longhorn Aero.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -337,8 +337,8 @@
<SolidColorBrush x:Key="ButtonPressedForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ButtonFlashingForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ClockForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="Transparent" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="#ffffff" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="Transparent" />

<SolidColorBrush x:Key="ToolTipBackground" Color="#f4f4f4" />
<SolidColorBrush x:Key="ToolTipForeground" Color="#00025c" />
Expand Down Expand Up @@ -1196,8 +1196,8 @@
</Style>

<Style TargetType="TextBlock"
x:Key="KeyboardLayout"
BasedOn="{StaticResource KeyboardLayout}">
x:Key="InputLanguage"
BasedOn="{StaticResource InputLanguage}">
<Setter Property="Effect"
Value="{StaticResource ForegroundShadow}" />
</Style>
Expand Down
8 changes: 4 additions & 4 deletions RetroBar/Themes/Windows Vista Aero.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -278,8 +278,8 @@
<SolidColorBrush x:Key="ButtonPressedForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ButtonFlashingForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ClockForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="Transparent" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="#ffffff" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="Transparent" />

<LinearGradientBrush x:Key="ShowDesktopButtonBorderHorizontal"
StartPoint="0,0"
Expand Down Expand Up @@ -1364,8 +1364,8 @@
</Style>

<Style TargetType="TextBlock"
x:Key="KeyboardLayout"
BasedOn="{StaticResource KeyboardLayout}">
x:Key="InputLanguage"
BasedOn="{StaticResource InputLanguage}">
<Setter Property="Margin"
Value="0,-2,0,0" />
</Style>
Expand Down
4 changes: 2 additions & 2 deletions RetroBar/Themes/Windows XP Blue.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -348,8 +348,8 @@
<SolidColorBrush x:Key="ButtonPressedForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ButtonFlashingForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ClockForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#316ac5" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="#ffffff" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#316ac5" />

<SolidColorBrush x:Key="ToolTipBackground" Color="#FFFFE1" />
<SolidColorBrush x:Key="ToolTipForeground" Color="#000000" />
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Themes/Windows XP Embedded Style.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@
</LinearGradientBrush>

<SolidColorBrush x:Key="ClockForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#3e9de8" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#3e9de8" />

<BitmapImage x:Key="StartButtonImage"
UriSource="../Resources/startxpembeddedbutton.png" />
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Themes/Windows XP Olive Green.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -388,5 +388,5 @@
<SolidColorBrush x:Key="ButtonActiveForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ButtonPressedForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ClockForeground" Color="#41400a" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#93a070" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#93a070" />
</ResourceDictionary>
2 changes: 1 addition & 1 deletion RetroBar/Themes/Windows XP Royale Noir.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@
Opacity="1" />

<SolidColorBrush x:Key="ClockForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#5e80bc" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#5e80bc" />

<BitmapImage x:Key="StartButtonImage"
UriSource="../Resources/startnoir.png" />
Expand Down
2 changes: 1 addition & 1 deletion RetroBar/Themes/Windows XP Royale.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,7 @@
</LinearGradientBrush>

<SolidColorBrush x:Key="ClockForeground" Color="#000000" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#335ea8" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#335ea8" />

<BitmapImage x:Key="StartButtonImage"
UriSource="../Resources/startxproyalebutton.png" />
Expand Down
4 changes: 2 additions & 2 deletions RetroBar/Themes/Windows XP Silver.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -790,6 +790,6 @@
<SolidColorBrush x:Key="ButtonActiveForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ButtonPressedForeground" Color="#ffffff" />
<SolidColorBrush x:Key="ClockForeground" Color="#000000" />
<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="#000000" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#b2b4bf" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="#000000" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#b2b4bf" />
</ResourceDictionary>
4 changes: 2 additions & 2 deletions RetroBar/Themes/Windows XP Zune Style.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -450,8 +450,8 @@
</LinearGradientBrush>

<SolidColorBrush x:Key="ClockForeground" Color="#ffffff" />
<SolidColorBrush x:Key="KeyboardLayoutForeground" Color="#000000" />
<SolidColorBrush x:Key="KeyboardLayoutBackground" Color="#bebebe" />
<SolidColorBrush x:Key="InputLanguageForeground" Color="#000000" />
<SolidColorBrush x:Key="InputLanguageBackground" Color="#bebebe" />

<BitmapImage x:Key="StartButtonImage"
UriSource="../Resources/startxpzunebutton.png" />
Expand Down
10 changes: 5 additions & 5 deletions RetroBar/Utilities/Settings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -87,18 +87,18 @@ public string Theme
}
}

private bool _showKeyboardLayout = false;
public bool ShowKeyboardLayout
private bool _showInputLanguage = false;
public bool ShowInputLanguage
{
get
{
return _showKeyboardLayout;
return _showInputLanguage;
}
set
{
if (_showKeyboardLayout != value)
if (_showInputLanguage != value)
{
_showKeyboardLayout = value;
_showInputLanguage = value;
OnPropertyChanged();
}
}
Expand Down

0 comments on commit fd65a55

Please sign in to comment.