|
10 | 10 | xmlns:controls="clr-namespace:Rubberduck.UI.Controls"
|
11 | 11 | xmlns:themes="clr-namespace:Microsoft.Windows.Themes;assembly=PresentationFramework.Aero"
|
12 | 12 | mc:Ignorable="d"
|
13 |
| - d:DesignWidth="500" |
| 13 | + d:DesignWidth="700" |
14 | 14 | d:DataContext="{d:DesignInstance {x:Type settings:InspectionSettingsViewModel}, IsDesignTimeCreatable=False}">
|
15 | 15 | <UserControl.Resources>
|
16 | 16 | <converters:CodeInspectionSeverityEnumToTextConverter x:Key="CodeInspectionSeverityEnumToText" />
|
|
19 | 19 |
|
20 | 20 | <BitmapImage x:Key="AddImage" UriSource="pack://application:,,,/Rubberduck.Resources;component/Icons/Fugue/plus-circle.png" />
|
21 | 21 | <BitmapImage x:Key="DeleteImage" UriSource="pack://application:,,,/Rubberduck.Resources;component/Icons/Fugue/cross-script.png" />
|
22 |
| - |
| 22 | + |
23 | 23 | <LinearGradientBrush x:Key="{x:Static SystemColors.HighlightBrushKey}" EndPoint="0,1" StartPoint="0,0">
|
24 | 24 | <GradientStop Color="#FFD9F4FF" Offset="0"/>
|
25 | 25 | <GradientStop Color="#FF9BDDFB" Offset="1"/>
|
|
30 | 30 | </LinearGradientBrush>
|
31 | 31 | <SolidColorBrush x:Key="{x:Static SystemColors.HighlightTextBrushKey}" Color="Black" />
|
32 | 32 | <SolidColorBrush x:Key="{x:Static SystemColors.ControlTextBrushKey}" Color="Black" />
|
33 |
| - |
| 33 | + |
34 | 34 | <ObjectDataProvider x:Key="Severities"
|
35 | 35 | MethodName="GetValues"
|
36 | 36 | ObjectType="{x:Type core:Enum}">
|
|
255 | 255 | </DataTrigger>
|
256 | 256 | </Style.Triggers>
|
257 | 257 | </Style>
|
| 258 | + <Style x:Key="HeaderBackground" TargetType="Label"> |
| 259 | + <Setter Property="HorizontalContentAlignment" Value="Stretch"/> |
| 260 | + <Setter Property="Background" Value="DarkGray"/> |
| 261 | + </Style> |
| 262 | + <Style x:Key="HeaderText" TargetType="Label"> |
| 263 | + <Setter Property="Foreground" Value="White"/> |
| 264 | + <Setter Property="FontWeight" Value="SemiBold"/> |
| 265 | + </Style> |
| 266 | + <Style x:Key="BorderHeader" TargetType="Border"> |
| 267 | + <Setter Property="Background" Value="DarkGray"/> |
| 268 | + <Setter Property="CornerRadius" Value="5"/> |
| 269 | + </Style> |
258 | 270 | </UserControl.Resources>
|
259 | 271 | <Grid>
|
260 | 272 | <ScrollViewer>
|
261 | 273 | <StackPanel Margin="5,5,5,0" ScrollViewer.VerticalScrollBarVisibility="Auto">
|
262 |
| - <Label Background="DarkGray" |
263 |
| - HorizontalContentAlignment="Stretch" |
| 274 | + <Border Style="{StaticResource BorderHeader}" |
264 | 275 | Margin="0,5,0,5">
|
265 |
| - <Label.Style> |
266 |
| - <Style> |
267 |
| - <Style.Resources> |
268 |
| - <Style TargetType="{x:Type Border}"> |
269 |
| - <Setter Property="CornerRadius" Value="5"/> |
270 |
| - </Style> |
271 |
| - </Style.Resources> |
272 |
| - </Style> |
273 |
| - </Label.Style> |
274 |
| - <DockPanel Background="DarkGray" FlowDirection="LeftToRight"> |
| 276 | + <DockPanel FlowDirection="LeftToRight"> |
275 | 277 | <StackPanel Orientation="Horizontal" DockPanel.Dock="Left">
|
276 |
| - <Label Foreground="White" |
277 |
| - FontWeight="SemiBold" |
| 278 | + <Label Style="{StaticResource HeaderText}" |
278 | 279 | Content="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=CodeInspectionSettings_InspectionSeveritySettingsLabel}">
|
279 | 280 | </Label>
|
| 281 | + <StackPanel Orientation="Horizontal" HorizontalAlignment="Stretch"> |
| 282 | + <Label Content="-"/> |
| 283 | + <Label Style="{StaticResource HeaderText}" |
| 284 | + Content="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=InspectionSettings_FilterDescription}" /> |
| 285 | + <TextBox MinWidth="125" |
| 286 | + Text="{Binding InspectionSettingsDescriptionFilter, UpdateSourceTrigger=PropertyChanged}" |
| 287 | + HorizontalAlignment="Stretch" /> |
| 288 | + <Border Width="10" /> |
| 289 | + <Label Style="{StaticResource HeaderText}" |
| 290 | + Content="Severity:" /> |
| 291 | + <CheckBox IsChecked="{Binding AreInspectionsFilteredBySeverity, UpdateSourceTrigger=PropertyChanged}" /> |
| 292 | + <StackPanel Orientation="Horizontal"> |
| 293 | + <ComboBox Width="100" |
| 294 | + IsEnabled="{Binding AreInspectionsFilteredBySeverity}" |
| 295 | + ItemsSource="{Binding InspectionSettingsSeverityFilter}"> |
| 296 | + <!--, UpdateSourceTrigger=PropertyChanged--> |
| 297 | + </ComboBox> |
| 298 | + </StackPanel> |
| 299 | + </StackPanel> |
280 | 300 | </StackPanel>
|
281 |
| - <StackPanel Orientation="Horizontal" DockPanel.Dock="Right" HorizontalAlignment="Left"> |
| 301 | + <StackPanel Orientation="Horizontal" DockPanel.Dock="Right" HorizontalAlignment="Left" |
| 302 | + Margin="10,0,0,0"> |
282 | 303 | <controls:LinkButton
|
283 | 304 | Margin="2"
|
284 | 305 | Command="{Binding ImportButtonCommand}"
|
|
288 | 309 | Command="{Binding ExportButtonCommand}"
|
289 | 310 | Content="{Resx ResxName=Rubberduck.Resources.Settings.SettingsUI, Key=ExportPageSettingsButton}"/>
|
290 | 311 | </StackPanel>
|
291 |
| - <StackPanel Orientation="Horizontal" DockPanel.Dock="Right" HorizontalAlignment="Stretch"> |
292 |
| - <Label Foreground="White" |
293 |
| - FontWeight="SemiBold" |
294 |
| - Content="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=InspectionSettings_FilterDescription}" /> |
295 |
| - <TextBox MinWidth="125" |
296 |
| - Text="{Binding InspectionSettingsFilter, UpdateSourceTrigger=PropertyChanged}" |
297 |
| - HorizontalAlignment="Stretch" /> |
298 |
| - </StackPanel> |
299 | 312 | </DockPanel>
|
300 |
| - </Label> |
| 313 | + </Border> |
301 | 314 | <Border BorderBrush="DarkGray" BorderThickness="1" CornerRadius="2">
|
302 | 315 | <controls:GroupingGrid ItemsSource="{Binding InspectionSettings}"
|
303 | 316 | AutoGenerateColumns="False"
|
|
344 | 357 | </controls:GroupingGrid.Columns>
|
345 | 358 | </controls:GroupingGrid>
|
346 | 359 | </Border>
|
347 |
| - <Label Background="DarkGray" |
348 |
| - Foreground="White" |
349 |
| - FontWeight="SemiBold" |
350 |
| - Content="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=CodeInspectionSettings_Misc}" |
351 |
| - Margin="0,15,0,5"> |
352 |
| - <Label.Style> |
353 |
| - <Style> |
354 |
| - <Style.Resources> |
355 |
| - <Style TargetType="{x:Type Border}"> |
356 |
| - <Setter Property="CornerRadius" Value="5"/> |
357 |
| - </Style> |
358 |
| - </Style.Resources> |
359 |
| - </Style> |
360 |
| - </Label.Style> |
361 |
| - </Label> |
| 360 | + |
| 361 | + <Border Style="{StaticResource BorderHeader}" |
| 362 | + Margin="0,15,0,5"> |
| 363 | + <Label Style="{StaticResource HeaderText}" |
| 364 | + Content="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=CodeInspectionSettings_Misc}"> |
| 365 | + </Label> |
| 366 | + </Border> |
| 367 | + |
362 | 368 | <StackPanel>
|
363 | 369 | <CheckBox IsChecked="{Binding RunInspectionsOnSuccessfulParse}"
|
364 | 370 | Content="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=CodeInspectionSettings_Misc_RunInspectionsOnSuccessfulParse}" />
|
365 | 371 | </StackPanel>
|
366 | 372 |
|
367 |
| - <Label Background="DarkGray" |
368 |
| - Foreground="White" |
369 |
| - FontWeight="SemiBold" |
370 |
| - Content="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=CodeInspectionSettings_WhitelistedIdentifiersLabel}" |
371 |
| - Margin="0,15,0,5"> |
372 |
| - <Label.Style> |
373 |
| - <Style> |
374 |
| - <Style.Resources> |
375 |
| - <Style TargetType="{x:Type Border}"> |
376 |
| - <Setter Property="CornerRadius" Value="5"/> |
377 |
| - </Style> |
378 |
| - </Style.Resources> |
379 |
| - </Style> |
380 |
| - </Label.Style> |
381 |
| - </Label> |
| 373 | + <Border Style="{StaticResource BorderHeader}" |
| 374 | + Margin="0,15,0,5"> |
| 375 | + <Label Style="{StaticResource HeaderText}" |
| 376 | + Content="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=CodeInspectionSettings_WhitelistedIdentifiersLabel}" /> |
| 377 | + </Border> |
| 378 | + |
382 | 379 | <TextBlock Text="{Resx ResxName=Rubberduck.Resources.RubberduckUI, Key=CodeInspectionSettings_WhitelistedIdentifiersDescription}" />
|
383 | 380 | <ToolBarTray IsLocked="True"
|
384 | 381 | Background="Transparent">
|
|
0 commit comments