parent
d8cda510a7
commit
579661b6f1
@ -0,0 +1,39 @@
|
|||||||
|
<UserControl x:Class="STranslate.View.UserControlInput"
|
||||||
|
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:STranslate.View"
|
||||||
|
mc:Ignorable="d"
|
||||||
|
d:DesignHeight="450" d:DesignWidth="800">
|
||||||
|
<!--输入框-->
|
||||||
|
<Border x:Name="BorderInput"
|
||||||
|
Style="{DynamicResource BorderInOutputStyle}">
|
||||||
|
<Grid>
|
||||||
|
<TextBox x:Name="TextBoxInput"
|
||||||
|
Style="{DynamicResource TextBoxInputStyle}"
|
||||||
|
Text="{Binding InputTxt,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged}">
|
||||||
|
<TextBox.InputBindings>
|
||||||
|
<KeyBinding Command="{Binding TranslateCmd}" Key="Enter" />
|
||||||
|
</TextBox.InputBindings>
|
||||||
|
</TextBox>
|
||||||
|
<StackPanel Orientation="Horizontal"
|
||||||
|
Margin="10,5"
|
||||||
|
VerticalAlignment="Bottom">
|
||||||
|
<Button Template="{DynamicResource ButtonTemplate}"
|
||||||
|
Visibility="{Binding InputTxt,Converter={StaticResource String2VisibilityConverter}}"
|
||||||
|
Command="{Binding CopyInputCmd}"/>
|
||||||
|
<Border Style="{DynamicResource LanguageMarkBorderStyle}"
|
||||||
|
Visibility="{Binding IdentifyLanguage,Converter={StaticResource String2VisibilityConverter}}">
|
||||||
|
<StackPanel Margin="5,2"
|
||||||
|
Orientation="Horizontal">
|
||||||
|
<TextBlock Text="识别为 "
|
||||||
|
Style="{DynamicResource LanguageMarkTextBlockStyle}"/>
|
||||||
|
<TextBlock Text="{Binding IdentifyLanguage}"
|
||||||
|
Foreground="#af67c1"/>
|
||||||
|
</StackPanel>
|
||||||
|
</Border>
|
||||||
|
</StackPanel>
|
||||||
|
</Grid>
|
||||||
|
</Border>
|
||||||
|
</UserControl>
|
Loading…
Reference in new issue