| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- <Window x:Class="LocalizationTool.Views.AddEntryWindow"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- Title="新增词条" Height="520" Width="540"
- WindowStartupLocation="CenterOwner"
- Background="#F5F6FA">
- <Grid Margin="24">
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto"/>
- <RowDefinition Height="*"/>
- <RowDefinition Height="Auto"/>
- </Grid.RowDefinitions>
- <TextBlock Text="新增词条" FontSize="16" FontWeight="Bold" Foreground="#333" Margin="0,0,0,12"/>
- <ScrollViewer Grid.Row="1" VerticalScrollBarVisibility="Auto">
- <StackPanel>
- <TextBlock Text="中文原文(key)*" FontSize="12" Foreground="#666" Margin="0,0,0,6"/>
- <TextBox Height="32" VerticalContentAlignment="Center" Style="{StaticResource TextBoxExtend}"
- Text="{Binding Key, UpdateSourceTrigger=PropertyChanged}"/>
- <TextBlock Text="各语言译文(可留空 = 缺译,之后用“仅翻译缺译”补)" FontSize="12"
- Foreground="#666" Margin="0,18,0,6"/>
- <ItemsControl ItemsSource="{Binding Fields}">
- <ItemsControl.ItemTemplate>
- <DataTemplate>
- <StackPanel Margin="0,0,0,10">
- <TextBlock Text="{Binding Label}" FontSize="12" Foreground="#666" Margin="0,0,0,4"/>
- <TextBox Height="30" VerticalContentAlignment="Center" Style="{StaticResource TextBoxExtend}"
- Text="{Binding Value, UpdateSourceTrigger=PropertyChanged}"/>
- </StackPanel>
- </DataTemplate>
- </ItemsControl.ItemTemplate>
- </ItemsControl>
- <TextBlock Text="(当前没有加载目标语言,仅新增中文源词条)" FontSize="11" Foreground="#999"
- Visibility="{Binding HasNoFields, Converter={StaticResource BoolToVis}}" Margin="0,4,0,0"/>
- </StackPanel>
- </ScrollViewer>
- <StackPanel Grid.Row="2" Orientation="Horizontal" HorizontalAlignment="Right" Margin="0,18,0,0">
- <Button Content="确定" Width="88" Style="{StaticResource ButtonPrimary}"
- Command="{Binding ConfirmCommand}" Margin="0,0,10,0"/>
- <Button Content="取消" Width="88" Style="{StaticResource ButtonDefault}"
- Command="{Binding CancelCommand}"/>
- </StackPanel>
- </Grid>
- </Window>
|