Fr Translation (#7297)
[opentx.git] / sound / recorder / MainWindow.xaml
blob7e88e25dd625a346d2feb748320dc38faaeebbe8
1 
2 <Window x:Class="OpenTXrecorder.MainWindow"
3         xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
4         xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
5         Title="OpenTX Recorder" 
6         Height="440" 
7         MinWidth="840"
8         MaxWidth="840"
9         ResizeMode="CanResizeWithGrip" SizeToContent="Width" Icon="/OpenTXrecorder;component/icon.ico" MinHeight="450">
11     
12     <Window.Resources> 
13         <DataTemplate x:Key="imagePlay">
14             <Image x:Name="ThePlayImage" />
15             <DataTemplate.Triggers>
16                 <DataTrigger Binding="{Binding Path=fileExists}" Value="true">
17                     <Setter TargetName="ThePlayImage" Property="Source" Value="/OpenTXrecorder;component/play.png" />
18                 </DataTrigger>
19             </DataTemplate.Triggers>
20         </DataTemplate>
21     </Window.Resources>
23     <Grid VerticalAlignment="Stretch" >
24         <Grid.ColumnDefinitions>
25             <ColumnDefinition Width="Auto" />
26             <ColumnDefinition Width="*"/>
27         </Grid.ColumnDefinitions>
28         <Grid Grid.Row="0" Grid.Column="0" VerticalAlignment="Stretch">
30             <ListView Name="lvSentences" 
31                       SelectionMode="Single" 
32                       MouseDoubleClick="play" 
33                       VerticalAlignment="Stretch" 
34                       ItemsSource="{Binding sentences, Mode=TwoWay}"
35                       IsSynchronizedWithCurrentItem="True"
36                       >
37                 <ListView.View>
38                     <GridView>
39                         <GridView.Columns>
40                             <GridViewColumn Header="File Name" Width="90"  DisplayMemberBinding="{Binding fileName}" />
41                             <GridViewColumn Header="Description" Width="190" DisplayMemberBinding="{Binding description}" />
42                             <GridViewColumn Header="Voice" Width="190" DisplayMemberBinding="{Binding voiceString}" />
43                             <GridViewColumn Width="30" CellTemplate="{StaticResource imagePlay}" />
44                         </GridView.Columns>
45                     </GridView>
46                 </ListView.View>
47             </ListView>
48         </Grid>
50         <StackPanel Grid.Row="0" Grid.Column="1">
51             <TextBlock Text="Settings" Margin="5,0,0,0" FontSize="18"   />
53             <StackPanel Orientation="Vertical" HorizontalAlignment="Left" Margin="10,0,0,0">
54                 <StackPanel Orientation="Horizontal">
55                     <Label Content="Language" Width="75"   />
56                     <ComboBox Name="cbLanguages"
57                               DisplayMemberPath="lName"
58                               SelectedValuePath="sName"
59                               SelectionChanged="switchLanguage"
60                               Width="200" Height="23"  
61                               ItemsSource="{Binding languages, Mode=TwoWay}" />
62                 </StackPanel>
63             </StackPanel>
64             <Separator Height="5" />
65             <TextBlock Text="Sentence" Margin="5,0,0,0" FontSize="18"   />
66             <Grid Margin="10,0,0,0" DataContext="{Binding ElementName=lvSentences, Path=SelectedItem}" Width="Auto">
67                 <Grid.ColumnDefinitions>
68                     <ColumnDefinition Width="75" />
69                     <ColumnDefinition Width="*"/>
70                 </Grid.ColumnDefinitions>
71                 <Grid.RowDefinitions>
72                     <RowDefinition />
73                     <RowDefinition />
74                     <RowDefinition />
75                     <RowDefinition />
76                     <RowDefinition />
77                 </Grid.RowDefinitions>
79                 <TextBlock Text="File Name" VerticalAlignment="Center" HorizontalAlignment="Left" Grid.Row="0" Grid.Column="0"  Margin="0,5,0,0"   />
80                 <TextBox   Text="{Binding Path=fileName}" Grid.Row="0" Grid.Column="1" Margin=" 0,0,10,0" />
81                 <TextBlock Text="Description" VerticalAlignment="Center" HorizontalAlignment="Left" Grid.Row="1" Grid.Column="0"  Margin="0,5,0,0"   />
82                 <TextBox   Text="{Binding Path=description}" Grid.Row="1" Grid.Column="1" Margin=" 0,0,10,0"/>
83                 <TextBlock Text="Sentence" Grid.Row="2" Grid.Column="0" Margin="0,5,0,0"   />
84                 <TextBox   Text="{Binding Path=voiceString}" Grid.Row="2" Grid.Column="1"  Margin="0,0,10,0"/>
85             </Grid>
86             <Separator Height="5" Margin="0,5,0,0" />
88             <StackPanel Orientation="Horizontal" Margin="0,0,0,0">
89                 <TextBlock Text="Speed Up" Width="70" Margin="10,10,0,0"   />
90                 <Slider Name="speedSlider" 
91                         Value="0"
92                         Minimum="0" 
93                         Maximum="17" 
94                         TickPlacement="BottomRight" 
95                         TickFrequency="1" 
96                         IsSnapToTickEnabled="True"
97                         Width="170" 
98                         Margin="10,10,10,0" ToolTip="Increase speech speed" />
99                 <TextBlock Text="{Binding ElementName=speedSlider, Path=Value}" Width="40" Margin="0,10,0,0"/>
100                 <TextBlock Text="Voice Rate" Width="70" Margin="10,10,0,0"   />
101             </StackPanel>
103             <StackPanel Orientation="Horizontal" Margin="0,0,0,0">
104                 <TextBlock Text="Cut Level" Width="70" Margin="10,10,0,0"   />
105                 <Slider Name="noiceLevelSlider" 
106                         Value="800"
107                         Minimum="0" 
108                         Maximum="4000" 
109                         TickPlacement="BottomRight" 
110                         TickFrequency="100" 
111                         IsSnapToTickEnabled="True"
112                         Width="170" 
113                         Margin="10,10,10,0" ToolTip="Set Cut Level as low as possible" />
114                 <TextBlock Text="{Binding ElementName=noiceLevelSlider, Path=Value}" Width="40" Margin="0,10,0,0"/>
115                 <TextBlock Text="Voice Rate" Width="70" Margin="10,10,0,0"   />
116             </StackPanel>
117             <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Margin="0,5,0,0">
118                 <Button Content="New Sentence" Width="120" Height="32" Name="buttonAddItem" Click="addSentence"/>
119                 <Button Name="btnRecord" ToolTip="Start recording" Click="record"  Margin="20,0,0,0" >
120                     <Image Height="32" Source="/OpenTXrecorder;component/record.png"/>
121                 </Button>
122                 <Button Name="btnStop" ToolTip="Stop recording"  Click="stop"  Margin="5,0,0,0" >
123                     <Image Height="32" Source="/OpenTXrecorder;component/stop.png" />
124                 </Button>
125                 <Button Name="btnPlay" ToolTip="Play Sentence"  Click="play"  Margin="30,0,0,0" >
126                     <Image Height="32" Source="/OpenTXrecorder;component/play.png"  />
127                 </Button>
128             </StackPanel>
129             <Separator Height="5" />
130             <Label Content="RECORDING"  Name="lblRecording" HorizontalAlignment="Center" Foreground="Red" FontSize="24" FontWeight="Black" Visibility="Hidden" />
131         </StackPanel>
132         <Image Grid.Row="0" Grid.Column="1"  Name="openTXLogo"  Height="48"  MouseLeftButtonDown="about" HorizontalAlignment="Right" Cursor="Hand" Margin="0,0,0,0" Source="/OpenTXrecorder;component/recorder_logo.png" Stretch="Uniform" VerticalAlignment="Bottom" />
134     </Grid>
136 </Window>