-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathImport.xaml
65 lines (64 loc) · 3.46 KB
/
Import.xaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<Window x:Class="SylverInk.Import"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:SylverInk"
mc:Ignorable="d"
d:DataContext="{d:DesignInstance Type=local:ContextSettings}"
Background="{Binding MenuBackground}" Foreground="{Binding MenuForeground}" Height="525" MinHeight="325" MinWidth="250" MouseLeftButtonDown="Drag" ResizeMode="CanResize" Title="Sylver Ink: Import" Width="350">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<StackPanel>
<Label Content="File to import" FontStyle="Italic" HorizontalAlignment="Right" Margin="0,20,30,0"/>
<Grid Margin="15,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button Click="Open_Click" Content="..." Height="20" HorizontalAlignment="Right" Margin="5,5,5,5" Width="20"/>
<TextBox Grid.Column="1" IsReadOnly="True" Margin="5,5,5,5" Text="{Binding ImportTarget}" TextChanged="Target_TextChanged"/>
</Grid>
<Grid Margin="0,25,0,0">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<Button Click="Finalize_Click" Content="Import" IsEnabled="{Binding ReadyToFinalize}" x:Name="DoImport"/>
<Button Click="CloseClick" Content="Close" Grid.Column="1"/>
</Grid>
</StackPanel>
<Grid HorizontalAlignment="Center" Margin="0,20" Grid.Row="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
<ColumnDefinition Width="Auto"/>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition Height="10"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Label Content="Adaptive notes:"/>
<CheckBox Grid.Column="1" IsChecked="False" Checked="AdaptiveChecked" HorizontalAlignment="Center" Unchecked="AdaptiveChecked" VerticalAlignment="Center" x:Name="AdaptiveCheckBox"/>
<Label Grid.Column="2" Content="(?)" Foreground="{Binding AccentForeground}" ToolTip="Attempt to automatically detect boundaries between notes."/>
<Label Content="Line tolerance:" Grid.Row="2"/>
<StackPanel Grid.Column="1" HorizontalAlignment="Center" Orientation="Horizontal" Grid.Row="2" x:Name="LTPanel">
<Button Click="LineToleranceChanged" Content="-" Width="20" x:Name="LTLess"/>
<TextBox HorizontalContentAlignment="Center" IsReadOnly="True" Text="{Binding LineTolerance}" Width="20"/>
<Button Click="LineToleranceChanged" Content="+" Width="20" x:Name="LTMore"/>
</StackPanel>
<Label Grid.Column="2" Content="(?)" Foreground="{Binding AccentForeground}" Grid.Row="2" ToolTip="The number of blank lines to look for when separating the file into different notes."/>
</Grid>
<Border BorderBrush="{Binding MenuForeground}" BorderThickness="1" Grid.Row="2" Margin="20,5,20,20">
<TextBlock Background="{Binding ListBackground}" FontFamily="{Binding MainFontFamily}" FontSize="{Binding MainFontSize}" Foreground="{Binding ListForeground}" Text="{Binding ImportData}" TextWrapping="WrapWithOverflow"/>
</Border>
</Grid>
</Window>