aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/Tango.Stubs/Views/StubsView.xaml
blob: 00dc806e3007474e0067d92834ae285d939bc1bf (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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
<UserControl x:Class="Tango.Stubs.Views.StubsView"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:mahapps="http://metro.mahapps.com/winfx/xaml/controls"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:views="clr-namespace:Tango.Stubs.Views"
             xmlns:fa="http://schemas.fontawesome.io/icons/"
             xmlns:local="clr-namespace:Tango.Stubs.Views"
             xmlns:vm="clr-namespace:Tango.Stubs.ViewModels"
             xmlns:System="clr-namespace:System;assembly=mscorlib"
             xmlns:converters="clr-namespace:Tango.SharedUI.Converters;assembly=Tango.SharedUI"
             xmlns:controls="clr-namespace:Tango.SharedUI.Controls;assembly=Tango.SharedUI"
             xmlns:localControls="clr-namespace:Tango.Stubs.Controls"
             xmlns:transport="clr-namespace:Tango.Transport.Adapters;assembly=Tango.Transport"
             mc:Ignorable="d" 
             d:DesignHeight="720" d:DesignWidth="1280" Background="#202020" Foreground="Gainsboro" d:DataContext="{d:DesignInstance Type=vm:StubsViewVM, IsDesignTimeCreatable=False}">



    <UserControl.InputBindings>
        <KeyBinding Key="S" Modifiers="Control" Command="{Binding SaveCommand}"/>
        <KeyBinding Key="S" Modifiers="Ctrl+Shift" Command="{Binding SaveAsCommand}"/>
        <KeyBinding Key="F6" Command="{Binding BuildCommand}"/>
    </UserControl.InputBindings>

    <UserControl.Resources>

        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <!-- MahApps.Metro resource dictionaries. Make sure that all file names are Case Sensitive! -->
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Controls.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Fonts.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Colors.xaml" />

                <!-- Accent and AppTheme setting -->

                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/Accents/BaseDark.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/FlatButton.xaml" />

                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/VS/Colors.xaml" />
                <ResourceDictionary Source="pack://application:,,,/MahApps.Metro;component/Styles/VS/Styles.xaml" />

                <ResourceDictionary>
                    <ObjectDataProvider x:Key="baudRates" MethodName="GetValues"
                            ObjectType="{x:Type System:Enum}">
                        <ObjectDataProvider.MethodParameters>
                            <x:Type TypeName="transport:UsbSerialBaudRates"/>
                        </ObjectDataProvider.MethodParameters>
                    </ObjectDataProvider>

                    <BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter"></BooleanToVisibilityConverter>
                    <converters:EnumToDescriptionConverter x:Key="EnumToDescriptionConverter" />
                    <Style BasedOn="{StaticResource MetroTabItem}" TargetType="{x:Type TabItem}">
                        <Style.Triggers>
                            <DataTrigger Binding="{Binding RelativeSource={RelativeSource Self},Path=IsSelected}" Value="True">
                                <Setter Property="Background" Value="#007ACC"></Setter>
                            </DataTrigger>
                        </Style.Triggers>
                        <Setter Property="mahapps:ControlsHelper.HeaderFontSize" Value="12"></Setter>
                        <Setter Property="HeaderTemplate">
                            <Setter.Value>
                                <DataTemplate>
                                    <Border>
                                        <StackPanel Orientation="Horizontal">
                                            <mahapps:ProgressRing Width="5" Height="5" Margin="0 0 5 0" Foreground="White" Visibility="{Binding IsRunning,Converter={StaticResource BooleanToVisibilityConverter}}"></mahapps:ProgressRing>
                                            <TextBlock Text="{Binding Title}" ToolTip="{Binding File}" Foreground="Gainsboro" VerticalAlignment="Center"></TextBlock>
                                            <Button Command="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.CloseTabCommand}" CommandParameter="{Binding}" Margin="5 0 0 0" Cursor="Hand" Width="24" Height="24" VerticalAlignment="Center" Style="{DynamicResource MetroCircleButtonStyle}" mahapps:ButtonHelper.PreserveTextCase="True" BorderThickness="0">
                                                <StackPanel Orientation="Horizontal">
                                                    <fa:ImageAwesome Width="10" Height="10" Icon="Close" Foreground="Gainsboro"></fa:ImageAwesome>
                                                </StackPanel>
                                            </Button>
                                        </StackPanel>
                                    </Border>
                                </DataTemplate>
                            </Setter.Value>
                        </Setter>
                        <Setter Property="ContentTemplate">
                            <Setter.Value>
                                <DataTemplate>
                                    <Grid Background="#181818">
                                        <Grid.RowDefinitions>
                                            <RowDefinition Height="1*" />
                                            <RowDefinition Height="Auto" />
                                        </Grid.RowDefinitions>
                                        <localControls:ScriptEditorControl Text="{Binding Code,Mode=TwoWay}" InsertSnippetCommand="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.InsertSnippetCommand,Mode=TwoWay}" SaveCommand="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.SaveCommand}" HighlightTypes="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.HighlightTypes}" IntellisenseTypes="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.IntellisenseTypes}" RunCommand="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.RunCommand}" StopCommand="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.StopCommand}" />

                                        <Grid Grid.Row="1">
                                            <Grid.Style>
                                                <Style TargetType="Grid">
                                                    <Setter Property="Visibility" Value="Visible"></Setter>
                                                    <Style.Triggers>
                                                        <DataTrigger Binding="{Binding Errors.Count}" Value="0">
                                                            <Setter Property="Visibility" Value="Collapsed"></Setter>
                                                        </DataTrigger>
                                                    </Style.Triggers>
                                                </Style>
                                            </Grid.Style>
                                            <Border BorderThickness="1" BorderBrush="#4B4B4B" Margin="10">
                                                <DataGrid ItemsSource="{Binding Errors}" AutoGenerateColumns="False" Focusable="False" IsReadOnly="True" CanUserAddRows="False" CanUserDeleteRows="False" CanUserReorderColumns="False" CanUserResizeColumns="False" CanUserSortColumns="False" HeadersVisibility="None">
                                                    <DataGrid.Columns>
                                                        <DataGridTemplateColumn Header="#" Width="50">
                                                            <DataGridTemplateColumn.CellTemplate>
                                                                <DataTemplate>
                                                                    <fa:ImageAwesome Icon="ExclamationTriangle" Width="16" Foreground="#FF5C5C" />
                                                                </DataTemplate>
                                                            </DataGridTemplateColumn.CellTemplate>
                                                        </DataGridTemplateColumn>
                                                        <DataGridTextColumn Header="ERROR" Binding="{Binding Error}" MinWidth="200"></DataGridTextColumn>
                                                        <DataGridTemplateColumn Header="FILE" MinWidth="200">
                                                            <DataGridTemplateColumn.CellTemplate>
                                                                <DataTemplate>
                                                                    <TextBlock><Run>'</Run><Run Text="{Binding File}"></Run><Run>'</Run></TextBlock>
                                                                </DataTemplate>
                                                            </DataGridTemplateColumn.CellTemplate>
                                                        </DataGridTemplateColumn>
                                                        <DataGridTemplateColumn Header="POSITION">
                                                            <DataGridTemplateColumn.CellTemplate>
                                                                <DataTemplate>
                                                                    <TextBlock><Run>(</Run><Run Text="{Binding Line}"></Run><Run>,</Run><Run Text="{Binding Character}"></Run><Run>)</Run></TextBlock>
                                                                </DataTemplate>
                                                            </DataGridTemplateColumn.CellTemplate>
                                                        </DataGridTemplateColumn>
                                                    </DataGrid.Columns>
                                                </DataGrid>
                                            </Border>
                                        </Grid>
                                    </Grid>
                                </DataTemplate>
                            </Setter.Value>
                        </Setter>
                    </Style>
                </ResourceDictionary>
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </UserControl.Resources>
    <UserControl.Style>
        <Style TargetType="UserControl">
            <Style.Triggers>
                <DataTrigger Binding="{Binding IsRunning}" Value="True">
                    <Setter Property="Cursor" Value="AppStarting"></Setter>
                </DataTrigger>
            </Style.Triggers>
        </Style>
    </UserControl.Style>
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="1*"/>
        </Grid.RowDefinitions>

        <Grid>
            <Menu IsMainMenu="True" BorderThickness="0" Padding="0 8">
                <MenuItem Header="File">
                    <MenuItem Header="New" Command="{Binding NewCommand}">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="FileOutline" Width="12" Foreground="Gainsboro" Margin="2" />
                        </MenuItem.Icon>
                    </MenuItem>
                    <Separator/>
                    <MenuItem Header="Open" MinWidth="150" Command="{Binding OpenCommand}">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="FolderOutline" Width="12" Foreground="Gainsboro" Margin="2" />
                        </MenuItem.Icon>
                    </MenuItem>
                    <Separator/>
                    <MenuItem Header="Save" Command="{Binding SaveCommand}" InputGestureText="Ctrl+S">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Save" Width="12" Foreground="Gainsboro" Margin="2" />
                        </MenuItem.Icon>
                    </MenuItem>
                    <MenuItem Header="Save as" Command="{Binding SaveAsCommand}" InputGestureText="Ctrl+Shift+S">
                        <MenuItem.Icon>
                            <Grid>
                                <fa:ImageAwesome Icon="Save" Width="10" Foreground="Gainsboro" Margin="2" />
                                <fa:ImageAwesome Icon="Save" Width="10" Foreground="Gainsboro" Margin="2 -5 -5 2" />
                            </Grid>
                        </MenuItem.Icon>
                    </MenuItem>
                </MenuItem>
                <MenuItem Header="Edit">
                    <MenuItem Header="Cut" MinWidth="150" Command="Cut">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Cut" Width="12" Foreground="Gainsboro" Margin="2" />
                        </MenuItem.Icon>
                    </MenuItem>
                    <Separator/>
                    <MenuItem Header="Copy" Command="Copy">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Copy" Width="12" Foreground="Gainsboro" Margin="2" />
                        </MenuItem.Icon>
                    </MenuItem>
                    <MenuItem Header="Paste" Command="Paste">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Paste" Width="12" Foreground="Gainsboro" Margin="2" />
                        </MenuItem.Icon>
                    </MenuItem>
                    <Separator/>
                    <MenuItem Header="Undo" Command="Undo">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Undo" Width="12" Foreground="Gainsboro" Margin="2" />
                        </MenuItem.Icon>
                    </MenuItem>
                    <MenuItem Header="Redo" Command="Redo">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Repeat" Width="12" Foreground="Gainsboro" Margin="2" />
                        </MenuItem.Icon>
                    </MenuItem>
                </MenuItem>
                <MenuItem Header="Wizard" ItemsSource="{Binding CreateGroups}">
                    <MenuItem.ItemContainerStyle>
                        <Style TargetType="{x:Type MenuItem}">
                            <Setter Property="Padding" Value="2"></Setter>
                            <Setter Property="Command" Value="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.CreateItemCommand}" />
                            <Setter Property="CommandParameter" Value="{Binding}"></Setter>
                        </Style>
                    </MenuItem.ItemContainerStyle>
                    <MenuItem.ItemTemplate>
                        <HierarchicalDataTemplate DataType="{x:Type vm:CreateGroupVM}" ItemsSource="{Binding Path=Items}">
                            <TextBlock Text="{Binding Name}"/>
                        </HierarchicalDataTemplate>
                    </MenuItem.ItemTemplate>
                </MenuItem>
                <MenuItem Header="Examples" ItemsSource="{Binding Examples}">
                    <MenuItem.ItemContainerStyle>
                        <Style TargetType="{x:Type MenuItem}">
                            <Setter Property="Padding" Value="2"></Setter>
                            <Setter Property="Command" Value="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.CreateExampleCommand}" />
                            <Setter Property="CommandParameter" Value="{Binding}"></Setter>
                        </Style>
                    </MenuItem.ItemContainerStyle>
                    <MenuItem.ItemTemplate>
                        <DataTemplate>
                            <TextBlock Text="{Binding Name}" ToolTip="{Binding Code}"></TextBlock>
                        </DataTemplate>
                    </MenuItem.ItemTemplate>
                </MenuItem>
                <MenuItem Header="Debug">
                    <MenuItem Header="Build (F6)" MinWidth="150" Command="{Binding BuildCommand}" >
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Cog" Width="12" Margin="2">
                                <fa:ImageAwesome.Style>
                                    <Style TargetType="fa:ImageAwesome">
                                        <Setter Property="Foreground" Value="#EF8E29"></Setter>
                                        <Style.Triggers>
                                            <Trigger Property="IsEnabled" Value="False">
                                                <Setter Property="Foreground" Value="Gray"></Setter>
                                            </Trigger>
                                        </Style.Triggers>
                                    </Style>
                                </fa:ImageAwesome.Style>
                            </fa:ImageAwesome>
                        </MenuItem.Icon>
                    </MenuItem>
                    <MenuItem Header="Run (F5)" MinWidth="150" Command="{Binding RunCommand}" >
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Play" Width="12" Margin="2">
                                <fa:ImageAwesome.Style>
                                    <Style TargetType="fa:ImageAwesome">
                                        <Setter Property="Foreground" Value="#8DD28A"></Setter>
                                        <Style.Triggers>
                                            <Trigger Property="IsEnabled" Value="False">
                                                <Setter Property="Foreground" Value="Gray"></Setter>
                                            </Trigger>
                                        </Style.Triggers>
                                    </Style>
                                </fa:ImageAwesome.Style>
                            </fa:ImageAwesome>
                        </MenuItem.Icon>
                    </MenuItem>
                    <MenuItem Header="Stop" Command="{Binding StopCommand}" IsEnabled="False">
                        <MenuItem.Icon>
                            <fa:ImageAwesome Icon="Stop" Width="12" Margin="2">
                                <fa:ImageAwesome.Style>
                                    <Style TargetType="fa:ImageAwesome">
                                        <Setter Property="Foreground" Value="#F38B76"></Setter>
                                        <Style.Triggers>
                                            <Trigger Property="IsEnabled" Value="False">
                                                <Setter Property="Foreground" Value="Gray"></Setter>
                                            </Trigger>
                                        </Style.Triggers>
                                    </Style>
                                </fa:ImageAwesome.Style>
                            </fa:ImageAwesome>
                        </MenuItem.Icon>
                    </MenuItem>
                </MenuItem>
            </Menu>
        </Grid>

        <Grid Grid.Row="2">
            <Grid.ColumnDefinitions>
                <ColumnDefinition Width="1019*"/>
                <ColumnDefinition Width="220"/>
            </Grid.ColumnDefinitions>
            <Grid.RowDefinitions>
                <RowDefinition Height="1*"/>
                <RowDefinition Height="5"/>
                <RowDefinition Height="0.5*"/>
            </Grid.RowDefinitions>

            <Grid>
                <TabControl x:Name="tabControl" Margin="5" ItemsSource="{Binding CodeTabs}" SelectedItem="{Binding SelectedCodeTab}">

                </TabControl>

                <Grid HorizontalAlignment="Right" Margin="0 45 40 0" VerticalAlignment="Top" Visibility="{Binding IsRunning,Converter={StaticResource BooleanToVisibilityConverter}}">
                    <StackPanel Orientation="Horizontal">
                        <mahapps:ProgressRing Foreground="#007ACC" Width="20" Height="20"></mahapps:ProgressRing>
                        <TextBlock Text="Running..." FontStyle="Italic" Margin="10 0 0 0" FontSize="14" VerticalAlignment="Center"></TextBlock>
                    </StackPanel>
                </Grid>
            </Grid>

            <Grid Grid.Column="1" Grid.RowSpan="3">
                <Grid>
                    <Grid.RowDefinitions>
                        <RowDefinition Height="1*" />
                        <RowDefinition Height="Auto" />
                    </Grid.RowDefinitions>
                    <Grid Grid.Row="1" VerticalAlignment="Bottom" Height="25" Background="#007ACC"></Grid>
                    <DockPanel>
                        <GroupBox Header="COMMUNICATION PORT" VerticalAlignment="Top" DockPanel.Dock="Top" Margin="0 2 0 0" Visibility="{Binding DisplayConnectionPane,Converter={StaticResource BooleanToVisibilityConverter}}">
                            <StackPanel>
                                <ComboBox Margin="0 10 0 0" BorderThickness="0" ItemsSource="{Binding Ports}" Height="35" SelectedItem="{Binding SelectedPort}"></ComboBox>
                                <ComboBox Margin="0 10 0 0" BorderThickness="0" ItemsSource="{Binding Source={StaticResource baudRates}}" Height="35" SelectedItem="{Binding BaudRate}" SelectedIndex="0">
                                    <ComboBox.ItemTemplate>
                                        <DataTemplate>
                                            <TextBlock Text="{Binding Path=.,Converter={StaticResource EnumToDescriptionConverter}}" />
                                        </DataTemplate>
                                    </ComboBox.ItemTemplate>
                                </ComboBox>
                            </StackPanel>
                        </GroupBox>

                        <GroupBox Header="CONNECTION" DockPanel.Dock="Bottom" VerticalAlignment="Bottom" Margin="0 5 0 5" Visibility="{Binding DisplayConnectionPane,Converter={StaticResource BooleanToVisibilityConverter}}">
                            <StackPanel>
                                <Button Height="50" MinWidth="100" mahapps:ButtonHelper.PreserveTextCase="True" BorderThickness="0" Command="{Binding ToggleConnectionCommand}">
                                    <Button.Style>
                                        <Style TargetType="Button" BasedOn="{StaticResource AccentedSquareButtonStyle}">
                                            <Style.Triggers>
                                                <DataTrigger Binding="{Binding IsConnected}" Value="False">
                                                    <Setter Property="Content">
                                                        <Setter.Value>
                                                            <StackPanel Orientation="Horizontal">
                                                                <fa:ImageAwesome Icon="Link" Width="16"></fa:ImageAwesome>
                                                                <TextBlock VerticalAlignment="Center" Margin="10 0 10 0">CONNECT</TextBlock>
                                                            </StackPanel>
                                                        </Setter.Value>
                                                    </Setter>
                                                </DataTrigger>
                                                <DataTrigger Binding="{Binding IsConnected}" Value="True">
                                                    <Setter Property="Content">
                                                        <Setter.Value>
                                                            <StackPanel Orientation="Horizontal">
                                                                <fa:ImageAwesome Icon="Unlink" Width="16"></fa:ImageAwesome>
                                                                <TextBlock VerticalAlignment="Center" Margin="10 0 10 0">DISCONNECT</TextBlock>
                                                            </StackPanel>
                                                        </Setter.Value>
                                                    </Setter>
                                                </DataTrigger>
                                            </Style.Triggers>
                                        </Style>
                                    </Button.Style>
                                </Button>
                            </StackPanel>
                        </GroupBox>

                        <GroupBox Header="STUB SNIPPETS" Margin="0 10 0 0">
                            <Grid>
                                <ListBox BorderThickness="0" ItemsSource="{Binding StubSnippets}" HorizontalContentAlignment="Stretch" SelectedItem="{Binding SelectedStubSnippet}">
                                    <ListBox.ItemContainerStyle>
                                        <Style TargetType="ListBoxItem" BasedOn="{StaticResource {x:Type ListBoxItem}}">
                                            <Setter Property="Padding" Value="0"></Setter>
                                            <Setter Property="Margin" Value="0 2 0 2"></Setter>
                                            <Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter>
                                        </Style>
                                    </ListBox.ItemContainerStyle>
                                    <ListBox.ItemTemplate>
                                        <DataTemplate>
                                            <Border BorderThickness="1" BorderBrush="#007ACC" Padding="8" Background="Transparent">
                                                <Border.InputBindings>
                                                    <MouseBinding Gesture="LeftDoubleClick" Command="{Binding RelativeSource={RelativeSource AncestorType=UserControl},Path=DataContext.StubSnippetSelectedCommand}"/>
                                                </Border.InputBindings>
                                                <Grid>
                                                    <fa:ImageAwesome Icon="ArrowLeft" VerticalAlignment="Center" HorizontalAlignment="Left" Margin="5 0 0 0" Foreground="#007ACC" Width="16" Height="16"></fa:ImageAwesome>
                                                    <TextBlock VerticalAlignment="Center" FontSize="11" HorizontalAlignment="Center" Text="{Binding Name}"></TextBlock>
                                                </Grid>
                                            </Border>
                                        </DataTemplate>
                                    </ListBox.ItemTemplate>
                                </ListBox>
                            </Grid>
                        </GroupBox>
                    </DockPanel>
                </Grid>
            </Grid>

            <GridSplitter Margin="5 0 5 0" Grid.Row="1" Height="5" HorizontalAlignment="Stretch" VerticalAlignment="Center">
                <GridSplitter.Background>
                    <LinearGradientBrush>
                        <GradientStop/>
                        <GradientStop Color="#007ACC" Offset="0.5"/>
                        <GradientStop Offset="1"/>
                    </LinearGradientBrush>
                </GridSplitter.Background>
            </GridSplitter>

            <Grid Grid.Row="2">
                <Grid.RowDefinitions>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="25"/>
                </Grid.RowDefinitions>
                <GroupBox Header="Response">
                    <Grid Background="#151515">
                        <TextBox x:Name="txtLog" PreviewMouseDown="txtLog_PreviewMouseUp" FontFamily="Lucida Console" TextChanged="TextBox_TextChanged" Background="Transparent" BorderThickness="0" AcceptsReturn="True" VerticalScrollBarVisibility="Visible" Padding="5" IsReadOnly="True" TextWrapping="Wrap" FontSize="11" Foreground="Gainsboro"></TextBox>

                        <StackPanel Orientation="Horizontal" HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0 -32 -6 0">
                            <CheckBox VerticalAlignment="Center" Margin="0 0 20 0" IsChecked="{Binding AppendLogAuto}">Auto Logging</CheckBox>
                            <CheckBox x:Name="chkScroll" IsChecked="True" VerticalAlignment="Center" Margin="0 0 20 0">Scroll To End</CheckBox>
                            <Button Width="80" Height="25" Command="{Binding ClearCommand}">CLEAR</Button>
                        </StackPanel>
                    </Grid>
                </GroupBox>
                <StatusBar Background="#007ACC" Grid.Row="1">
                    <TextBlock Text="{Binding Status}"></TextBlock>
                </StatusBar>
            </Grid>
        </Grid>
    </Grid>
</UserControl>