-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathScriptEditWindow.xaml
More file actions
91 lines (83 loc) · 5.12 KB
/
ScriptEditWindow.xaml
File metadata and controls
91 lines (83 loc) · 5.12 KB
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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
<Window x:Class="PresentationPrompter.ScriptEditWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="编辑脚本"
Icon="提示.png"
Width="700" Height="520"
WindowStartupLocation="CenterOwner"
ResizeMode="CanResize"
ShowInTaskbar="False"
MinWidth="500" MinHeight="350">
<DockPanel Margin="12">
<!-- Top: script title -->
<DockPanel DockPanel.Dock="Top" Margin="0,0,0,8">
<TextBlock Text="脚本标题" FontSize="13" FontFamily="Microsoft YaHei"
VerticalAlignment="Center" Margin="0,0,8,0"/>
<TextBox x:Name="TitleBox" FontSize="13" FontFamily="Microsoft YaHei" Padding="4,3"/>
</DockPanel>
<!-- Bottom: Save / SaveAs / OK / Cancel -->
<StackPanel DockPanel.Dock="Bottom" Orientation="Horizontal"
HorizontalAlignment="Right" Margin="0,10,0,0">
<Button Content="保存" Width="56" Height="28" FontSize="12"
FontFamily="Microsoft YaHei" Click="SaveFile_Click"/>
<Button Content="另存为" Width="56" Height="28" Margin="6,0,0,0" FontSize="12"
FontFamily="Microsoft YaHei" Click="SaveAs_Click"/>
<Button Content="确定" Width="56" Height="28" Margin="12,0,0,0" FontSize="12"
FontFamily="Microsoft YaHei" Click="OK_Click" IsDefault="True"/>
<Button Content="取消" Width="56" Height="28" Margin="6,0,0,0" FontSize="12"
FontFamily="Microsoft YaHei" Click="Cancel_Click" IsCancel="True"/>
</StackPanel>
<!-- Main area: left list + right detail -->
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="200" MinWidth="150"/>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<!-- Left: step list -->
<DockPanel Grid.Column="0" Margin="0,0,8,0">
<!-- List controls -->
<StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Margin="0,0,0,6">
<Button Content="前插" Width="36" Height="22" FontSize="11"
FontFamily="Microsoft YaHei" Click="InsertBefore_Click" ToolTip="在选中项之前插入"/>
<Button Content="后插" Width="36" Height="22" Margin="4,0,0,0" FontSize="11"
FontFamily="Microsoft YaHei" Click="InsertAfter_Click" ToolTip="在选中项之后插入"/>
<Button Content="删除" Width="36" Height="22" Margin="4,0,0,0" FontSize="11"
FontFamily="Microsoft YaHei" Click="RemoveStep_Click"/>
<Button Content="▲" Width="22" Height="22" Margin="6,0,0,0" FontSize="11"
ToolTip="上移" Click="MoveUp_Click"/>
<Button Content="▼" Width="22" Height="22" Margin="2,0,0,0" FontSize="11"
ToolTip="下移" Click="MoveDown_Click"/>
</StackPanel>
<ListBox x:Name="StepListBox"
SelectionChanged="StepListBox_SelectionChanged"
FontFamily="Microsoft YaHei" FontSize="12"/>
</DockPanel>
<!-- Right: step detail editor -->
<StackPanel Grid.Column="1" x:Name="DetailPanel">
<TextBlock Text="步骤内容" FontSize="13" FontFamily="Microsoft YaHei" Margin="0,0,0,4"/>
<TextBox x:Name="DetailTextBox" Height="70" FontSize="12"
FontFamily="Microsoft YaHei" TextWrapping="Wrap"
AcceptsReturn="True" VerticalScrollBarVisibility="Auto"
Padding="4,3"/>
<TextBlock Text="命令行" FontSize="13" FontFamily="Microsoft YaHei" Margin="0,10,0,4"/>
<TextBox x:Name="DetailCommandBox" FontSize="12"
FontFamily="Consolas" Padding="4,3"/>
<StackPanel Orientation="Horizontal" Margin="0,10,0,0">
<CheckBox x:Name="DetailAutoRun" Content="自动执行"
FontSize="12" FontFamily="Microsoft YaHei"
VerticalAlignment="Center"/>
<TextBlock Text=" 延迟(ms)" FontSize="12" FontFamily="Microsoft YaHei"
VerticalAlignment="Center" Margin="16,0,6,0"/>
<TextBox x:Name="DetailDelay" Width="60" FontSize="12"
FontFamily="Microsoft YaHei" TextAlignment="Center"
Padding="4,3" Text="0"/>
<Button Content="测试执行" Width="64" Height="22" Margin="12,0,0,0" FontSize="11"
FontFamily="Microsoft YaHei" Click="TestRun_Click"/>
</StackPanel>
<TextBlock Text="可用变量: {step} {title} {stepCount}"
FontSize="11" Foreground="#999" FontFamily="Microsoft YaHei"
Margin="0,8,0,0"/>
</StackPanel>
</Grid>
</DockPanel>
</Window>