blob: 1a0a0a5b6cc137e3015c31cf7bd0de6e184a85be (
plain)
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
|
<UserControl xmlns="https://github.com/avaloniaui"
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"
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:Class="UVtools.WPF.Controls.Tools.ToolScriptingControl">
<StackPanel Orientation="Vertical">
<Grid RowDefinitions="Auto"
ColumnDefinitions="Auto,10,500,5,Auto">
<TextBlock Grid.Row="0" Grid.Column="0"
Text="Script file:"
VerticalAlignment="Center"/>
<TextBox Grid.Row="0" Grid.Column="2"
IsReadOnly="True"
Text="{Binding Operation.FilePath}" />
<StackPanel Grid.Row="0" Grid.Column="4"
Orientation="Horizontal" Spacing="1">
<Button
ToolTip.Tip="Loads an script file"
VerticalAlignment="Center"
Command="{Binding LoadScript}">
<Image Source="/Assets/Icons/file-import-16x16.png" />
</Button>
<Button
IsEnabled="{Binding Operation.HaveFile}"
ToolTip.Tip="Reloads the script"
VerticalAlignment="Center"
Command="{Binding ReloadScript}">
<Image Source="/Assets/Icons/refresh-16x16.png" />
</Button>
<Button
IsEnabled="{Binding Operation.HaveFile}"
ToolTip.Tip="Open the script folder"
VerticalAlignment="Center"
Command="{Binding OpenScriptFolder}">
<Image Source="/Assets/Icons/open-16x16.png" />
</Button>
<Button
IsEnabled="{Binding Operation.HaveFile}"
ToolTip.Tip="Open the script file"
VerticalAlignment="Center"
Command="{Binding OpenScriptFile}">
<Image Source="/Assets/Icons/file-code-16x16.png" />
</Button>
</StackPanel>
</Grid>
<StackPanel
Name="ScriptConfigurationPanel"
IsVisible="{Binding Operation.CanExecute}"
Margin="0,10" Spacing="5"/>
<Grid
Name="ScriptVariablesGrid"
IsVisible="{Binding Operation.CanExecute}"
ColumnDefinitions="Auto,10,Auto,5,Auto">
</Grid>
</StackPanel>
</UserControl>
|