JD2022-TU1/main/tools/modules/JD.Rosetta.Module.OptionsGrid/ExportOptionsPropertyGrid.xaml

41 lines
2.4 KiB
XML

<UserControl x:Class="JD.Rosetta.Module.OptionsGrid.ExportOptionsPropertyGrid"
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:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:grids="http://schemas.actiprosoftware.com/winfx/xaml/grids"
xmlns:lib="clr-namespace:System;assembly=mscorlib"
xmlns:optionsGrid="clr-namespace:JD.Rosetta.Module.OptionsGrid"
mc:Ignorable="d"
d:DesignHeight="450" d:DesignWidth="800">
<UserControl.Resources>
<optionsGrid:ObjectToTypeConverter x:Key="objectToTypeConverter"/>
</UserControl.Resources>
<!-- Needed to be in another assembly and not directly in JD.Rosetta.Module so that it could have a style in JD.Rosetta.Module -->
<grids:PropertyGrid x:Name="OptionsGrid"
CollectionPropertyDisplayMode="Expandable"
CanSummaryAutoSize="True"
CanColumnsResize="True"
AreNestedCategoriesSupported="True"
AreCategoriesAutoExpanded="False"
IsSummaryVisible="False"
IsCategorized="False"
SummaryHeight="63">
<grids:PropertyGrid.NameContainerStyle>
<Style TargetType="{x:Type grids:TreeListViewItemCell}">
<!--Display full description on name so that we don't need to show the summary -->
<Setter Property="ToolTip" Value="{Binding Description}"/>
</Style>
</grids:PropertyGrid.NameContainerStyle>
<grids:PropertyGrid.ValueContainerStyle>
<Style TargetType="{x:Type grids:TreeListViewItemCell}">
<Style.Triggers>
<!-- Display full text on comboboxes so no need to show them fully -->
<DataTrigger Binding="{Binding Value, Converter={StaticResource objectToTypeConverter}}" Value="{x:Type lib:String}">
<Setter Property="ToolTip" Value="{Binding Value}"/>
</DataTrigger>
</Style.Triggers>
</Style>
</grids:PropertyGrid.ValueContainerStyle>
</grids:PropertyGrid>
</UserControl>