diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Aero/AssemblyVersionInfo.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Aero/AssemblyVersionInfo.cs
index ce1db48a..693b6601 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Aero/AssemblyVersionInfo.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Aero/AssemblyVersionInfo.cs
@@ -21,7 +21,7 @@
internal static class _XceedVersionInfo
{
[System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )]
- public const string BaseVersion = "2.3";
+ public const string BaseVersion = "2.4";
[System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )]
public const string Version = BaseVersion +
".0.0";
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Metro/AssemblyVersionInfo.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Metro/AssemblyVersionInfo.cs
index ce1db48a..693b6601 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Metro/AssemblyVersionInfo.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Metro/AssemblyVersionInfo.cs
@@ -21,7 +21,7 @@
internal static class _XceedVersionInfo
{
[System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )]
- public const string BaseVersion = "2.3";
+ public const string BaseVersion = "2.4";
[System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )]
public const string Version = BaseVersion +
".0.0";
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Metro/Theme.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Metro/Theme.xaml
index 2ee472f8..51fbe329 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Metro/Theme.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.AvalonDock.Themes.Metro/Theme.xaml
@@ -54,19 +54,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
@@ -2768,7 +2805,7 @@
Value="-1">
+ the ColumnManagerRow -->
@@ -2936,7 +2973,6 @@
Value="{StaticResource tableflowViewGroupNavigationButtonTemplate}" />
-
@@ -3038,7 +3074,6 @@
Value="{StaticResource connectionStateErrorGlyph}" />
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/Resources/Aero2.normalcolor.Controls.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/Resources/Aero2.normalcolor.Controls.xaml
new file mode 100644
index 00000000..ad565c3e
--- /dev/null
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/Resources/Aero2.normalcolor.Controls.xaml
@@ -0,0 +1,2177 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/Resources/Aero2.normalcolor.Resources.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/Resources/Aero2.normalcolor.Resources.xaml
index 5d1ef1c9..e67ffca5 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/Resources/Aero2.normalcolor.Resources.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/Resources/Aero2.normalcolor.Resources.xaml
@@ -21,29 +21,29 @@
-
-
-
-
+
+
-
-
-
-
+
-
-
+ xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup">
-
+
-
-
+
+
-
-
+
+
-
+
-
-
+
-
-
-
-
+
-
-
-
-
-
-
-
+
+
+
-
-
+
-
-
-
-
-
-
-
+
+
+
-
-
+
-
-
-
-
-
-
-
+
+
+
-
-
+
-
-
-
-
-
-
-
+
+
+
-
-
+
-
-
-
-
-
-
-
+
+
+
-
-
+
-
-
-
-
-
-
-
+
+
+
-
-
+
-
-
-
-
-
-
-
-
+
+
+
-
-
+
-
-
-
-
-
-
-
+
+
+
-
-
+
-
-
-
-
-
-
+
+
+
-
-
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/TableView.Aero2.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/TableView.Aero2.normalcolor.xaml
new file mode 100644
index 00000000..8300c726
--- /dev/null
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/TableView.Aero2.normalcolor.xaml
@@ -0,0 +1,45 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/TableflowView.Aero2.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/TableflowView.Aero2.normalcolor.xaml
index cfe830f3..ac126581 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/TableflowView.Aero2.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Aero2/TableflowView.Aero2.normalcolor.xaml
@@ -20,124 +20,132 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
-
+
+
-
-
+
+
-
-
+
+
+
+
+
-
+
-
-
-
-
-
+
+
+
- Segoe UI
- 12
+ Segoe UI
+ 12
-
-
-
+
+
+
-
-
+
-
-
-
+
-
-
+
-
-
-
-
+
-
-
-
+
-
-
+
-
-
-
-
-
+
+
+
+
+
+
+
-
-
-
-
-
-
+
-
-
-
+
+
+
-
-
-
-
+
-
-
-
-
+
+
+
+
-
-
+
+
-
-
-
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
+
-
-
+
-
-
-
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
-
-
+
-
-
-
+
-
-
-
-
-
+
-
-
-
-
+
+
+
-
-
-
-
+
-
-
-
-
+
+
+
-
-
-
+
-
-
-
-
+
+
+
-
-
-
-
+
+
-
-
-
+
+
-
-
+
-
-
+
-
-
+
-
-
+
-
-
+
+
-
-
+
-
+
-
+
-
-
-
+
-
+
-
+
-
-
+
+
+ Background="{TemplateBinding Background}"
+ BorderBrush="{TemplateBinding BorderBrush}"
+ BorderThickness="{TemplateBinding BorderThickness}">
+ HorizontalAlignment="Left"
+ VerticalAlignment="Stretch"
+ Width="1"
+ Margin="0,2,0,2" />
+ HorizontalAlignment="Right"
+ VerticalAlignment="Stretch"
+ Width="1"
+ Margin="0,2,0,2" />
+ DockPanel.Dock="Right">
+ BorderBrush="{StaticResource defaultForegroundBrush}"
+ BorderThickness="1,0,0,0"
+ Margin="0,4,0,4"
+ Background="Transparent"
+ Visibility="Collapsed">
+ BorderBrush="LightGray"
+ BorderThickness="1,0,0,0"
+ Margin="0,0,0,0"
+ Background="Transparent"
+ Visibility="Collapsed">
+ Background="{TemplateBinding Background}"
+ Margin="1,0,1,0" />
-
+ Focusable="False"
+ VerticalAlignment="Stretch"
+ Visibility="Collapsed"
+ Margin="2,0,0,0"
+ Opacity="0.5" />
@@ -431,24 +439,25 @@
+ HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
+ VerticalAlignment="{TemplateBinding VerticalContentAlignment}">
+
+ Grid.Column="0" />
+ We explicitely set its Content property to Null to prevent the XAML parser
+ from implicitely setting it to its TemplatedParent's Content. -->
+ Grid.Column="1"
+ Content="{x:Null}"
+ ContentTemplate="{x:Null}" />
@@ -459,15 +468,15 @@
+ Style="{StaticResource invisibleThumbStyle}"
+ Width="6"
+ HorizontalAlignment="Left" />
+ Style="{StaticResource invisibleThumbStyle}"
+ Width="6"
+ HorizontalAlignment="Right" />
@@ -477,123 +486,132 @@
+ Binding="{Binding ElementName=toggleButton, Path=Visibility}" />
+ Property="Margin"
+ Value="16,0,0,0" />
+
+
+
+
+
+
+ Value="True">
+ Property="Margin"
+ Value="0,0,1,0" />
+ Value="True">
+ Property="Background"
+ Value="{StaticResource columnManagerCellPressedBackgroundBrush}" />
+ Value="True" />
+ Value="False" />
+ Property="Background"
+ Value="{StaticResource columnManagerCellMouseOverBackgroundBrush}" />
+ Value="Ascending">
+ Property="ContentPresenter.ContentTemplate"
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).AscendingSortGlyph}" />
+ Property="Margin"
+ Value="6,0,0,0" />
+ Value="Descending">
+ Property="ContentPresenter.ContentTemplate"
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).DescendingSortGlyph}" />
-
+ Property="Margin"
+ Value="6,0,0,0" />
+ Value="True" />
+ Value="False" />
+ Property="IsEnabled"
+ Value="False" />
+ Value="True" />
+ Value="False" />
+ Property="IsEnabled"
+ Value="False" />
+ Value="False">
+ Property="IsEnabled"
+ Value="False" />
+ Property="IsEnabled"
+ Value="False" />
+ Value="False">
+ Value="Collapsed" />
@@ -603,186 +621,186 @@
-
-
-
-
+
+
-
-
+
-
-
-
-
+
+
-
+
-
-
-
-
-
+
-
-
-
-
+
-
-
+
+
-
-
-
-
-
-
+
-
+
-
+
-
+
-
-
-
-
+
-
-
+
+
-
-
+
-
-
-
-
-
-
+
+
+
+
-
-
-
-
-
+
-
-
-
-
+
-
-
+
+
-
-
-
+
-
-
-
+
+
-
-
-
+
-
-
+
-
-
-
+
+
-
-
-
-
-
-
+
-
+
-
-
+
-
-
+
-
-
+
-
-
-
-
+
+
+
+
-
-
+
-
-
-
-
+
+
+
-
-
-
-
-
-
+
+
+
-
-
-
+
-
-
+
+
-
-
+
-
-
-
+
+
-
-
-
-
-
-
+
-
+
-
-
+
-
-
-
-
-
-
-
+
+
+
+
+
-
-
+
-
-
-
+
+
-
+
-
-
-
-
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
-
+
-
-
-
-
+
+
+
+
-
-
+
-
-
+
-
+
-
+
-
-
-
+
-
-
-
-
+
-
-
-
-
+
+
+
+
-
-
-
+
-
-
+
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
-
-
+
-
-
-
+
+
+
-
-
+
-
-
+
-
-
-
+
+
+
-
-
+
+
-
-
+
-
-
+
-
-
+
-
-
+
-
-
+
+
-
-
+
-
-
+
-
-
+
-
-
+
-
-
+
-
-
+
+
-
-
+
+
+
-
-
+
-
-
+
-
-
+
+
+
-
-
+
-
-
+
-
-
-
-
-
+
-
-
-
+
+
+
-
+
-
-
-
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/Resources/Classic.Resources.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/Resources/Classic.Resources.xaml
index b6d63dc4..1b85cdb9 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/Resources/Classic.Resources.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/Resources/Classic.Resources.xaml
@@ -17,12 +17,12 @@
+ xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup">
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/Resources/Classic.systemcolor.Graphics.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/Resources/Classic.systemcolor.Graphics.xaml
index 2b23bfdd..cfb5dcd3 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/Resources/Classic.systemcolor.Graphics.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/Resources/Classic.systemcolor.Graphics.xaml
@@ -15,12 +15,12 @@
**********************************************************************************-->
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup">
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/TableView.Classic.systemcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/TableView.Classic.systemcolor.xaml
index f095316d..3e8f4719 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/TableView.Classic.systemcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/TableView.Classic.systemcolor.xaml
@@ -19,19 +19,18 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
@@ -124,6 +123,8 @@
+
+
@@ -180,7 +181,6 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
@@ -198,6 +198,7 @@
+
@@ -693,7 +694,7 @@
-
+
@@ -799,7 +800,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -810,11 +811,14 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -822,7 +826,7 @@
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -912,18 +916,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -959,7 +972,10 @@
Value="{StaticResource cellPadding}" />
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.CellHorizontalContentAlignment, FallbackValue=Stretch}" />
+
+
@@ -1048,6 +1064,18 @@
+
+
+
+
+
+
+
+
@@ -1178,7 +1206,7 @@
Value="-1">
+ the ColumnManagerRow -->
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/TableflowView.Classic.systemcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/TableflowView.Classic.systemcolor.xaml
index 8460e0b5..f2aa192d 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/TableflowView.Classic.systemcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Classic/TableflowView.Classic.systemcolor.xaml
@@ -19,19 +19,18 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
@@ -302,6 +301,8 @@
+
+
@@ -310,7 +311,6 @@
-
-
@@ -377,11 +376,12 @@
+
-
-
+
-
-
-
+
+
+
-
-
+
-
-
-
+
+
+
@@ -460,7 +461,6 @@
-
@@ -683,7 +683,6 @@
TargetType="local:HierarchicalGroupByItem">
-
-
+
@@ -1065,7 +1064,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1076,17 +1075,20 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1176,18 +1178,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1223,7 +1234,10 @@
Value="{StaticResource cellPadding}" />
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.CellHorizontalContentAlignment, FallbackValue=Left}" />
+
+
@@ -1304,7 +1318,6 @@
-
@@ -1317,6 +1330,18 @@
+
+
+
+
+
+
+
+
@@ -1370,7 +1395,6 @@
-
@@ -1462,7 +1486,7 @@
Value="-1">
+ the ColumnManagerRow -->
@@ -1738,7 +1762,6 @@
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Common/Common.Resources.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Common/Common.Resources.xaml
index e950e273..8ae3a994 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Common/Common.Resources.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Common/Common.Resources.xaml
@@ -21,6 +21,8 @@
xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
xmlns:scm="clr-namespace:System.ComponentModel;assembly=WindowsBase">
+
+
@@ -92,12 +94,19 @@
-
-
-
+
+
+
+
+
+
+
+
+
+
@@ -126,14 +135,23 @@
-
-
-
-
+
+
+
+
+
+
+
+
+
+
@@ -158,10 +176,20 @@
-
-
+
+
+
+
+
+
+
+
+
+
-
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Common/TableView.GridElementTemplates.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Common/TableView.GridElementTemplates.xaml
index ca151164..4f83ac82 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Common/TableView.GridElementTemplates.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Common/TableView.GridElementTemplates.xaml
@@ -22,7 +22,7 @@
xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
+
@@ -579,6 +580,9 @@
+
+
+
@@ -634,7 +638,6 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
@@ -660,7 +663,6 @@
-
@@ -682,7 +684,6 @@
Width="6"
HorizontalAlignment="Right" />
-
@@ -982,8 +983,8 @@
Property="Focusable"
Value="False" />
-
+
@@ -604,6 +606,8 @@
+
+
@@ -662,7 +666,6 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
@@ -688,7 +691,6 @@
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Controls/TableViewScrollViewer.generic.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Controls/TableViewScrollViewer.generic.xaml
index 65c12801..3cbf1aa0 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Controls/TableViewScrollViewer.generic.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Controls/TableViewScrollViewer.generic.xaml
@@ -26,7 +26,7 @@
Value="Visible" />
+ Value="{Binding HorizontalScrollBarVisibilityHint, RelativeSource={RelativeSource Self}}" />
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/Resources/TableView.Luna.Graphics.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/Resources/TableView.Luna.Graphics.xaml
index 0347f042..e3cccaf6 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/Resources/TableView.Luna.Graphics.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/Resources/TableView.Luna.Graphics.xaml
@@ -16,12 +16,13 @@
+ xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
+ xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup">
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.homestead.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.homestead.xaml
index 3a5e2aa3..6bdc4de0 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.homestead.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.homestead.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -271,6 +270,8 @@
+
+
@@ -313,7 +314,6 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
@@ -333,6 +333,7 @@
+
@@ -991,7 +992,7 @@
-
+
@@ -1096,7 +1097,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1107,11 +1108,14 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1119,7 +1123,7 @@
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1209,18 +1213,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1255,6 +1268,12 @@
+
+
+
+
@@ -1336,6 +1355,18 @@
+
+
+
+
+
+
+
+
@@ -1467,7 +1498,7 @@
Value="-1">
+ the ColumnManagerRow -->
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.metallic.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.metallic.xaml
index 82ac72e5..81dff704 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.metallic.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.metallic.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters">
-
+
-
+
-
+
-
+
@@ -415,6 +414,7 @@
+
@@ -457,7 +457,6 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
@@ -476,6 +475,7 @@
+
@@ -1277,7 +1277,7 @@
-
+
@@ -1382,7 +1382,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1393,11 +1393,14 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1405,7 +1408,7 @@
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1495,18 +1498,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1540,11 +1552,18 @@
+
+
+
+
+
@@ -1621,6 +1640,18 @@
+
+
+
+
+
+
+
+
@@ -1751,7 +1782,7 @@
Value="-1">
+ the ColumnManagerRow -->
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.normalcolor.xaml
index dd59b194..9868cab5 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableView.Luna.normalcolor.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -419,6 +418,8 @@
+
+
@@ -462,7 +463,6 @@
Focusable="False"
Visibility="Collapsed"
Margin="2,0,0,0" />
-
@@ -483,6 +483,7 @@
+
@@ -1280,7 +1281,7 @@
-
+
@@ -1384,7 +1385,7 @@
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1395,11 +1396,14 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1407,7 +1411,7 @@
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1496,18 +1500,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1542,6 +1555,12 @@
+
+
+
+
@@ -1623,6 +1642,18 @@
+
+
+
+
+
+
+
+
@@ -1756,7 +1787,7 @@
Value="-1">
+ the ColumnManagerRow -->
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.homestead.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.homestead.xaml
index f827c1a6..8710f1aa 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.homestead.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.homestead.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -495,6 +494,8 @@
+
+
@@ -537,12 +538,10 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
-
+
-
-
+
-
-
-
+
+
+
-
-
-
-
-
+
+
+
-
+
@@ -1326,7 +1325,7 @@
-
+
@@ -1431,7 +1430,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1442,17 +1441,20 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1542,18 +1544,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1588,6 +1599,12 @@
+
+
+
+
@@ -1669,6 +1686,18 @@
+
+
+
+
+
+
+
+
@@ -1721,7 +1750,6 @@
-
@@ -1814,7 +1842,7 @@
Value="-1">
+ the ColumnManagerRow -->
@@ -1857,7 +1885,6 @@
-
@@ -2086,7 +2113,6 @@
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.metallic.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.metallic.xaml
index 303e4e46..69e3c257 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.metallic.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.metallic.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters">
-
+
-
+
-
+
-
+
@@ -639,6 +638,7 @@
+
@@ -681,7 +681,6 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
@@ -700,11 +699,12 @@
+
-
-
+
+ Property="Margin"
+ Value="18,0,0,0" />
@@ -1609,7 +1607,7 @@
-
+
@@ -1714,7 +1712,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1725,17 +1723,20 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1764,6 +1765,7 @@
BasedOn="{StaticResource tableflowViewLunaMetallicRowStyle}">
+
@@ -1825,18 +1827,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1871,6 +1882,12 @@
+
+
+
+
@@ -1955,6 +1972,18 @@
+
+
+
+
+
+
+
+
@@ -2005,7 +2034,6 @@
-
@@ -2097,7 +2125,7 @@
Value="-1">
+ the ColumnManagerRow -->
@@ -2137,11 +2165,9 @@
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.normalcolor.xaml
index 2e9e40c8..abf88b76 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Luna/TableflowView.Luna.normalcolor.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -642,6 +641,8 @@
+
+
@@ -686,10 +687,8 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
-
@@ -708,11 +707,12 @@
+
-
-
+
@@ -1610,7 +1610,7 @@
-
+
@@ -1714,7 +1714,7 @@
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1725,17 +1725,20 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1824,18 +1827,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1870,6 +1882,12 @@
+
+
+
+
@@ -1951,6 +1969,18 @@
+
+
+
+
+
+
+
+
@@ -2007,7 +2037,6 @@
-
@@ -2099,7 +2128,7 @@
Value="-1">
+ the ColumnManagerRow -->
@@ -2142,7 +2171,6 @@
-
@@ -2371,7 +2399,6 @@
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/Resources/TableView.Royale.Graphics.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/Resources/TableView.Royale.Graphics.xaml
index 3a857c9f..65d5fa30 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/Resources/TableView.Royale.Graphics.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/Resources/TableView.Royale.Graphics.xaml
@@ -16,12 +16,13 @@
+ xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
+ xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup">
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/TableView.Royale.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/TableView.Royale.normalcolor.xaml
index d8033381..f2ae1df3 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/TableView.Royale.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/TableView.Royale.normalcolor.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -397,6 +396,8 @@
+
+
@@ -437,7 +438,6 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
@@ -456,6 +456,7 @@
+
@@ -1246,7 +1247,7 @@
-
+
@@ -1351,7 +1352,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1362,11 +1363,14 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1374,7 +1378,7 @@
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1464,18 +1468,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1510,6 +1523,12 @@
+
+
+
+
@@ -1591,6 +1610,18 @@
+
+
+
+
+
+
+
+
@@ -1721,7 +1752,7 @@
Value="-1">
+ the ColumnManagerRow -->
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/TableflowView.Royale.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/TableflowView.Royale.normalcolor.xaml
index 203ef8d7..d17e8839 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/TableflowView.Royale.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Royale/TableflowView.Royale.normalcolor.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -617,10 +616,11 @@
-
+
+
@@ -661,7 +661,6 @@
Visibility="Collapsed"
Margin="2,0,0,0"
Opacity="0.5" />
-
@@ -680,11 +679,12 @@
+
-
-
+
-
+
@@ -1682,7 +1681,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1693,17 +1692,20 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1793,18 +1795,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1839,6 +1850,12 @@
+
+
+
+
@@ -1920,6 +1937,18 @@
+
+
+
+
+
+
+
+
@@ -1973,7 +2002,6 @@
-
@@ -2065,7 +2093,7 @@
Value="-1">
+ the ColumnManagerRow -->
@@ -2178,7 +2206,6 @@
-
@@ -2337,7 +2364,6 @@
-
@@ -2402,7 +2428,6 @@
TargetType="local:DetailIndicator"
BasedOn="{StaticResource tableflowViewRoyaleNormalColorDetailIndicatorStyle}" />
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/Resources/TableView.Windows7.Graphics.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/Resources/TableView.Windows7.Graphics.xaml
index cc58d12d..a3250856 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/Resources/TableView.Windows7.Graphics.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/Resources/TableView.Windows7.Graphics.xaml
@@ -17,15 +17,15 @@
+ xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup">
-
+
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/Resources/Windows7.Controls.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/Resources/Windows7.Controls.xaml
index f9617b1b..1540eb3d 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/Resources/Windows7.Controls.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/Resources/Windows7.Controls.xaml
@@ -17,12 +17,13 @@
+ xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
+ xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup">
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/TableView.Windows7.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/TableView.Windows7.xaml
index 52ce2918..b0a3d3eb 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/TableView.Windows7.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/TableView.Windows7.xaml
@@ -20,22 +20,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -314,11 +313,10 @@
+
+
-
-
-
-
+
+
+
-
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -2025,11 +2024,14 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -2127,15 +2129,24 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -2173,6 +2184,12 @@
+
+
+
+
@@ -2251,6 +2268,18 @@
+
+
+
+
+
+
+
+
@@ -2371,7 +2400,7 @@
Value="-1">
+ the ColumnManagerRow -->
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/TableflowView.Windows7.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/TableflowView.Windows7.xaml
index 2a9c291b..fd2b5f2b 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/TableflowView.Windows7.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Windows7/TableflowView.Windows7.xaml
@@ -20,22 +20,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -541,11 +540,10 @@
+
+
-
-
-
-
+
+
+
+
+
+
+
+
+
@@ -1736,7 +1745,6 @@
-
@@ -1837,7 +1845,6 @@
-
@@ -2244,7 +2251,7 @@
-
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -2388,11 +2395,14 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -2488,15 +2498,24 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -2534,6 +2553,12 @@
+
+
+
+
@@ -2612,6 +2637,18 @@
+
+
+
+
+
+
+
+
@@ -2744,7 +2781,7 @@
Value="-1">
+ the ColumnManagerRow -->
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/Resources/TableView.Zune.Graphics.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/Resources/TableView.Zune.Graphics.xaml
index d04e009c..78b5a5c9 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/Resources/TableView.Zune.Graphics.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/Resources/TableView.Zune.Graphics.xaml
@@ -16,12 +16,13 @@
+ xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
+ xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup">
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/TableView.Zune.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/TableView.Zune.normalcolor.xaml
index 8cf416ef..82fb9ba0 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/TableView.Zune.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/TableView.Zune.normalcolor.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -364,6 +363,8 @@
+
+
@@ -425,6 +426,7 @@
+
@@ -1064,7 +1066,7 @@
-
+
@@ -1169,7 +1171,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1180,11 +1182,14 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1192,7 +1197,7 @@
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1282,18 +1287,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1328,6 +1342,12 @@
+
+
+
+
@@ -1409,6 +1429,18 @@
+
+
+
+
+
+
+
+
@@ -1540,7 +1572,7 @@
Value="-1">
+ the ColumnManagerRow -->
@@ -1653,7 +1685,6 @@
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/TableflowView.Zune.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/TableflowView.Zune.normalcolor.xaml
index 80822a0e..012793a7 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/TableflowView.Zune.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/Zune/TableflowView.Zune.normalcolor.xaml
@@ -19,22 +19,21 @@
xmlns:local="clr-namespace:Xceed.Wpf.DataGrid"
xmlns:conv="clr-namespace:Xceed.Wpf.DataGrid.Converters"
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
- xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views"
- xmlns:utils="clr-namespace:Xceed.Utils.Wpf.Markup">
+ xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
+
-
+
-
+
-
+
@@ -574,6 +573,8 @@
+
+
@@ -615,7 +616,6 @@
Focusable="False"
Visibility="Collapsed"
Margin="2,0,0,0" />
-
@@ -635,6 +635,7 @@
+
@@ -1397,7 +1398,7 @@
-
+
@@ -1502,7 +1503,7 @@
assuming that the bottom gridline will be drawn by its following row/element -->
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top'}" />
@@ -1513,17 +1514,20 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).HorizontalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Top, Bottom'}" />
@@ -1613,18 +1617,27 @@
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=ParentColumn.ActualWidth}" />
+
+
+
+
+ Value="{Binding RelativeSource={RelativeSource Self}, Path=(local:DataGridControl.DataGridContext).VerticalGridLineThickness, Converter={StaticResource thicknessConverter}, ConverterParameter='Right'}" />
@@ -1659,6 +1672,12 @@
+
+
+
+
@@ -1740,6 +1759,18 @@
+
+
+
+
+
+
+
+
@@ -1885,7 +1916,7 @@
Value="-1">
+ the ColumnManagerRow -->
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/aero.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/aero.normalcolor.xaml
index e286b3f5..316e120c 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/aero.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/aero.normalcolor.xaml
@@ -23,8 +23,8 @@
-
-
+
+
-
-
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/aero2.normalcolor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/aero2.normalcolor.xaml
index 27940002..07bf18da 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/aero2.normalcolor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/themes/aero2.normalcolor.xaml
@@ -20,117 +20,205 @@
xmlns:markup="clr-namespace:Xceed.Wpf.DataGrid.Markup"
xmlns:views="clr-namespace:Xceed.Wpf.DataGrid.Views">
-
-
+
+
-
-
+
+
-
-
-
+
+
-
+
-
+
+
+
\ No newline at end of file
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StylableWindowView.xaml.cs.txt b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StyleableWindowView.xaml.cs.txt
similarity index 78%
rename from ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StylableWindowView.xaml.cs.txt
rename to ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StyleableWindowView.xaml.cs.txt
index 97c60872..c0407f5a 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StylableWindowView.xaml.cs.txt
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StyleableWindowView.xaml.cs.txt
@@ -34,28 +34,28 @@ using Xceed.Wpf.Toolkit.Primitives;
namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.Window.Views
{
///
- /// Interaction logic for StylableWindowView.xaml
+ /// Interaction logic for StyleableWindowView.xaml
///
- public partial class StylableWindowView : DemoView
+ public partial class StyleableWindowView : DemoView
{
private const string StandardMsgBoxTitle = "Standard MessageBox";
private const string StyledMsgBoxTitle = "Extended WPF Toolkit styled MessageBox";
- private const string StylableWindowTitle = "Extended WPF Toolkit StylableWindow";
+ private const string StyleableWindowTitle = "Extended WPF Toolkit StyleableWindow";
private const string StandardMsgBoxMessage = "The standard system MessageBox will always have this look. No styling is possible.";
private const string StyledMsgBoxMessage = "The Toolkit MessageBox allows you to style it in order to integrate it into your application colors and styles.";
- private const string StylableWindowContent = "This is a StylableWindow that has the same functionality as a normal window.";
+ private const string StyleableWindowContent = "This is a StyleableWindow that has the same functionality as a normal window.";
private const string MessageBoxStyleKey = "messageBoxStyle";
private const string WindowControlStyleKey = "windowControlStyle";
private const string WindowButtonStyle = "FancyButtonStyle";
#if OPEN_SOURCE
- private const string StylableWindowMessage = "StylableWindow is a standalone window that can be styled just like ChildWindow or MessageBox. This is a feature of the \"Plus\" version.";
+ private const string StyleableWindowMessage = "StyleableWindow is a standalone window that can be styled just like ChildWindow or MessageBox. This is a feature of the \"Plus\" version.";
#else
- private const string StylableWindowNoStyleKey = "stylableWindowNoStyle";
- private const string StylableWindowStyleKey = "stylableWindowStyle";
- private StylableWindow _stylableWindow;
+ private const string StyleableWindowNoStyleKey = "styleableWindowNoStyle";
+ private const string StyleableWindowStyleKey = "styleableWindowStyle";
+ private StyleableWindow _styleableWindow;
#endif
- public StylableWindowView()
+ public StyleableWindowView()
{
InitializeComponent();
#if !OPEN_SOURCE
@@ -68,57 +68,57 @@ namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.Window.Views
private void OnSampleUnloaded( object sender, RoutedEventArgs e )
{
//# Be sure to close the window
- if( _stylableWindow != null )
+ if( _styleableWindow != null )
{
- _stylableWindow.Close();
+ _styleableWindow.Close();
}
}
#endif
- private void OnStylableWindow_Click( object sender, RoutedEventArgs e )
+ private void OnStyleableWindow_Click( object sender, RoutedEventArgs e )
{
#if OPEN_SOURCE
var msgBox = new Xceed.Wpf.Toolkit.MessageBox();
msgBox.DataContext = this.DataContext;
- msgBox.Text = StylableWindowMessage;
+ msgBox.Text = StyleableWindowMessage;
msgBox.Caption = StyledMsgBoxTitle;
msgBox.Style = ( _enableStyleCheckBox.IsChecked.GetValueOrDefault() ) ? ( Style )this.Resources[ MessageBoxStyleKey ] : null;
msgBox.ShowDialog();
#else
- if( _stylableWindow == null )
+ if( _styleableWindow == null )
{
- _stylableWindow = new StylableWindow();
- _stylableWindow.Width = 500;
- _stylableWindow.Height = 300;
- _stylableWindow.Title = StylableWindowTitle;
- _stylableWindow.DataContext = this.DataContext;
- _stylableWindow.Left = Application.Current.MainWindow.Left + ( Application.Current.MainWindow.ActualWidth / 2 );
- _stylableWindow.Top = Application.Current.MainWindow.Top + ( Application.Current.MainWindow.ActualHeight / 2 );
- _stylableWindow.Closed += new EventHandler( OnStylableWindowClosed );
- _stylableWindow.Topmost = true;
-
- _stylableWindow.Content = new TextBlock()
+ _styleableWindow = new StyleableWindow();
+ _styleableWindow.Width = 500;
+ _styleableWindow.Height = 300;
+ _styleableWindow.Title = StyleableWindowTitle;
+ _styleableWindow.DataContext = this.DataContext;
+ _styleableWindow.Left = Application.Current.MainWindow.Left + ( Application.Current.MainWindow.ActualWidth / 2 );
+ _styleableWindow.Top = Application.Current.MainWindow.Top + ( Application.Current.MainWindow.ActualHeight / 2 );
+ _styleableWindow.Closed += new EventHandler( OnStyleableWindowClosed );
+ _styleableWindow.Topmost = true;
+
+ _styleableWindow.Content = new TextBlock()
{
- Text = StylableWindowContent,
+ Text = StyleableWindowContent,
TextWrapping = TextWrapping.Wrap
};
- _stylableWindow.Style = ( _enableStyleCheckBox.IsChecked.GetValueOrDefault() )
- ? ( Style )this.Resources[ StylableWindowStyleKey ]
- : ( Style )this.Resources[ StylableWindowNoStyleKey ];
+ _styleableWindow.Style = ( _enableStyleCheckBox.IsChecked.GetValueOrDefault() )
+ ? ( Style )this.Resources[ StyleableWindowStyleKey ]
+ : ( Style )this.Resources[ StyleableWindowNoStyleKey ];
- _stylableWindow.Show();
+ _styleableWindow.Show();
}
#endif
}
#if !OPEN_SOURCE
- private void OnStylableWindowClosed( object sender, EventArgs e )
+ private void OnStyleableWindowClosed( object sender, EventArgs e )
{
- _stylableWindow.Closed -= new EventHandler( OnStylableWindowClosed );
- _stylableWindow.Style = null;
- _stylableWindow.DataContext = null;
- _stylableWindow = null;
+ _styleableWindow.Closed -= new EventHandler( OnStyleableWindowClosed );
+ _styleableWindow.Style = null;
+ _styleableWindow.DataContext = null;
+ _styleableWindow = null;
}
#endif
private void StandardMessageBoxButton_Click( object sender, RoutedEventArgs e )
@@ -152,11 +152,11 @@ namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.Window.Views
}
#if !OPEN_SOURCE
- if( _stylableWindow != null )
+ if( _styleableWindow != null )
{
- _stylableWindow.Style = ( styled )
- ? ( Style )this.Resources[ StylableWindowStyleKey ]
- : ( Style )this.Resources[ StylableWindowNoStyleKey ];
+ _styleableWindow.Style = ( styled )
+ ? ( Style )this.Resources[ StyleableWindowStyleKey ]
+ : ( Style )this.Resources[ StyleableWindowNoStyleKey ];
}
#endif
}
@@ -164,7 +164,7 @@ namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.Window.Views
///
/// This model will allow to share the style values between our MessageBox,
- /// ChildWindow and StylableWindow controls
+ /// ChildWindow and StyleableWindow controls
///
public class WindowModel : DependencyObject
{
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StylableWindowView.xaml.txt b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StyleableWindowView.xaml.txt
similarity index 91%
rename from ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StylableWindowView.xaml.txt
rename to ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StyleableWindowView.xaml.txt
index a7de8655..271bc3f8 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StylableWindowView.xaml.txt
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/CodeFiles/StyleableWindowView.xaml.txt
@@ -13,7 +13,7 @@
Stay informed: follow @datagrid on Twitter or Like http://facebook.com/datagrids
**************************************************************************************-->
-
+ Title="StyleableWindows" >
It is possible to style ChildWindow controls as well as MessageBox controls. All the chrome of their window can be styled (color, thickness, opacity); their action buttons can also be styled.
- The "Plus" version provides a new control called StylableWindow, which consists of a window that has all the functions of a normal window, but which can be styled in the same way as ChildWindow or MessageBox.
+ The "Plus" version provides a new control called StyleableWindow, which consists of a window that has all the functions of a normal window, but which can be styled in the same way as ChildWindow or MessageBox.
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/MainWindow.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/MainWindow.xaml
index 2c85e339..c7d75241 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/MainWindow.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/MainWindow.xaml
@@ -23,8 +23,8 @@
AllowsTransparency="False"
Icon="App.ico"
Title="Extended WPF Toolkit - LiveExplorer"
- Height="768"
- Width="1290">
+ Height="778"
+ Width="1300">
@@ -545,6 +545,10 @@
SampleType="{x:Type samples:Text.Views.RichTextboxView}" />
+
@@ -553,7 +557,6 @@
IsPlusOnlyFeature="True"/>
@@ -592,8 +595,8 @@
-
+
-
-
+
+
+
text/microsoft-resx
- 2.3
+ 2.4
- System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.3.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.4.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
- System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.3.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.4.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
\ No newline at end of file
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/DataGrid/Views/DataGridView.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/DataGrid/Views/DataGridView.xaml
index 15a1eb35..598da0b3 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/DataGrid/Views/DataGridView.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/DataGrid/Views/DataGridView.xaml
@@ -97,7 +97,8 @@
+ ItemsSource="{Binding Source={StaticResource cvsOrders}}"
+ AllowDrag="True">
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/DateTime/Views/DateTimeView.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/DateTime/Views/DateTimeView.xaml
index 6af5c431..15d3cacc 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/DateTime/Views/DateTimeView.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/DateTime/Views/DateTimeView.xaml
@@ -47,6 +47,11 @@
+
+
+
+
+
@@ -68,6 +73,7 @@
+
@@ -86,10 +92,12 @@
-
-
-
-
+
+
+
+
+
+
@@ -121,7 +129,8 @@
TimePickerVisibility="{Binding Source={x:Reference _timePickerVisibility}, Path=SelectedItem}"
TimePickerShowButtonSpinner="{Binding IsChecked, ElementName=_timePickerShowButtonSpinner}"
Minimum="{Binding Value, ElementName=_minimum}"
- Maximum="{Binding Value, ElementName=_maximum}"/>
+ Maximum="{Binding Value, ElementName=_maximum}"
+ Kind="{Binding SelectedItem, ElementName=_kind}"/>
@@ -131,6 +140,7 @@
+
@@ -143,10 +153,12 @@
-
-
+
+
+
+
-
+
-
+ Maximum="{Binding Value, ElementName=_maximum}"
+ MaxDropDownHeight="{Binding Value, ElementName=_maxDropDownHeight}"/>
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Numeric/Views/NumericView.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Numeric/Views/NumericView.xaml
index e427b107..e5a8d8d9 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Numeric/Views/NumericView.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Numeric/Views/NumericView.xaml
@@ -45,7 +45,9 @@
-
+
+
+
@@ -55,6 +57,12 @@
+
+
+
+
+
+
@@ -96,6 +104,7 @@
+
@@ -118,17 +127,22 @@
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
+
+
+
@@ -147,25 +161,28 @@
-
-
+
+
+
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
+
+
-
-
-
+
+
+
@@ -177,6 +194,7 @@
ClipValueToMinMax="False"
ShowButtonSpinner="True"
AllowSpin="True"
+ AllowTextInput="True"
IsReadOnly="False"
MouseWheelActiveOnFocus="True"
CultureInfo="en-US"
@@ -185,6 +203,7 @@
Maximum="100"
Minimum="0"
DisplayDefaultValueOnEmptyText="False"
+ ButtonSpinnerLocation="Right"
ParsingNumberStyle="Any"
Watermark="Enter Text"
DefaultValue="10"
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/PropertyGrid/Views/PropertyGridAttributesView.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/PropertyGrid/Views/PropertyGridAttributesView.xaml
index e415721e..2bcd5fa5 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/PropertyGrid/Views/PropertyGridAttributesView.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/PropertyGrid/Views/PropertyGridAttributesView.xaml
@@ -55,6 +55,8 @@
Plus edition Only:
+
+ DependsOnAttribute
(Not demoed here. See corresponding samples)
@@ -89,7 +91,8 @@
+ SelectedObject="{Binding}"
+ ShowDescriptionByTooltip="True">
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/PropertyGrid/Views/PropertyGridAttributesView.xaml.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/PropertyGrid/Views/PropertyGridAttributesView.xaml.cs
index d170913d..3e4f6621 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/PropertyGrid/Views/PropertyGridAttributesView.xaml.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/PropertyGrid/Views/PropertyGridAttributesView.xaml.cs
@@ -46,7 +46,6 @@ namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.PropertyGrid.Views
};
this.DataContext = person;
-
}
}
@@ -61,10 +60,10 @@ namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.PropertyGrid.Views
[Category( "Information" )]
[Description( "This property uses the [DisplayName(\"Is a Men\")] attribute to customize the name of this property." )]
[DisplayName( "Is male" )]
- public bool IsMale { get; protected set; }
+ public bool IsMale { get; set; }
[Category( "Information" )]
- [Description( "This property uses the [Editor(..)] attribute to provide a custom editor using the 'FirstNameEditor' class" )]
+ [Description( "This property uses the [Editor(..)] attribute to provide a custom editor using the 'FirstNameEditor' class. In the Plus version, it also depends on the IsMale property to change its foreground and source." )]
[Editor( typeof( FirstNameEditor ), typeof( FirstNameEditor ) )]
public string FirstName { get; set; }
@@ -151,7 +150,6 @@ namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.PropertyGrid.Views
{
TextBox textBox = new TextBox();
textBox.Background = new SolidColorBrush( Colors.Red );
-
//create the binding from the bound property item to the editor
var _binding = new Binding( "Value" ); //bind to the Value property of the PropertyItem
_binding.Source = propertyItem;
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Views/RangeSliderView.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Views/RangeSliderView.xaml
index 80358c2e..9c37982d 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Views/RangeSliderView.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Views/RangeSliderView.xaml
@@ -18,14 +18,12 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:sys="clr-namespace:System;assembly=mscorlib"
xmlns:local="clr-namespace:Xceed.Wpf.Toolkit.LiveExplorer"
- xmlns:conv="clr-namespace:Xceed.Wpf.Toolkit.LiveExplorer.Samples.RangeSlider.Converters"
xmlns:xctkconv="clr-namespace:Xceed.Wpf.Toolkit.Core.Converters;assembly=Xceed.Wpf.Toolkit"
xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
Title="RangeSlider">
-
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Views/RangeSliderView.xaml.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Views/RangeSliderView.xaml.cs
index 20ad2985..8b375314 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Views/RangeSliderView.xaml.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Views/RangeSliderView.xaml.cs
@@ -17,6 +17,8 @@
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.ComponentModel;
+using System.Windows.Controls;
+using System.Windows.Media;
namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.RangeSlider.Views
{
@@ -29,5 +31,32 @@ namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.RangeSlider.Views
{
InitializeComponent();
}
+
+ private void RangeStyleComboBox_SelectionChanged( object sender, SelectionChangedEventArgs e )
+ {
+ if( e.AddedItems.Count > 0 && e.AddedItems[ 0 ] is ComboBoxItem)
+ {
+ ComboBoxItem item = e.AddedItems[ 0 ] as ComboBoxItem;
+ //A style different from null is chosen
+ if( item.Tag != null )
+ {
+ //LowerRangeBackground is Transparent, force a color
+ if( object.Equals( sender, lowerRangeStyleComboBox ) && ((SolidColorBrush)_rangeSlider.LowerRangeBackground).Color.Equals( Colors.Transparent) )
+ {
+ _rangeSlider.LowerRangeBackground = new SolidColorBrush( Colors.Green );
+ }
+ //RangeBackground is Transparent, force a color
+ else if( object.Equals( sender, rangeStyleComboBox ) && ( ( SolidColorBrush )_rangeSlider.RangeBackground ).Color.Equals( Colors.Transparent ) )
+ {
+ _rangeSlider.RangeBackground = new SolidColorBrush( Colors.Blue );
+ }
+ //HigherRangeBackground is Transparent, force a color
+ else if( object.Equals( sender, higherRangeStyleComboBox ) && ( ( SolidColorBrush )_rangeSlider.HigherRangeBackground ).Color.Equals( Colors.Transparent ) )
+ {
+ _rangeSlider.HigherRangeBackground = new SolidColorBrush( Colors.Green );
+ }
+ }
+ }
+ }
}
}
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/OpenSourceImages/TokenizedTextBox.png b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/OpenSourceImages/TokenizedTextBox.png
new file mode 100644
index 00000000..dede90f0
Binary files /dev/null and b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/OpenSourceImages/TokenizedTextBox.png differ
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/Views/TokenizedTextBoxView.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/Views/TokenizedTextBoxView.xaml
new file mode 100644
index 00000000..a62e8de1
--- /dev/null
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/Views/TokenizedTextBoxView.xaml
@@ -0,0 +1,74 @@
+
+
+
+
+
+ The TokenizedTextBox lets you display a series of values as tokens. If an ItemsSource is specified, an AutoComplete popup will appear with a filtered list of valid values during edition.
+
+
+ This feature is only available in the "Plus" version.
+
+
+ Click here for more details about Xceed Extended WPF Toolkit Plus.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/Views/TokenizedTextBoxView.xaml.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/Views/TokenizedTextBoxView.xaml.cs
new file mode 100644
index 00000000..814297ab
--- /dev/null
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Text/Views/TokenizedTextBoxView.xaml.cs
@@ -0,0 +1,63 @@
+/*************************************************************************************
+
+ Extended WPF Toolkit
+
+ Copyright (C) 2007-2014 Xceed Software Inc.
+
+ This program is provided to you under the terms of the Microsoft Public
+ License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license
+
+ For more features, controls, and fast professional support,
+ pick up the Plus Edition at http://xceed.com/wpf_toolkit
+
+ Stay informed: follow @datagrid on Twitter or Like http://facebook.com/datagrids
+
+ ***********************************************************************************/
+
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+using System.ComponentModel;
+using System.Data;
+using System.Collections.ObjectModel;
+
+
+namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.TokenizedTextBox.Views
+{
+ ///
+ /// Interaction logic for TokenizedTextBoxView.xaml
+ ///
+ public partial class TokenizedTextBoxView : DemoView
+ {
+
+
+
+ public TokenizedTextBoxView()
+ {
+
+ InitializeComponent();
+ }
+
+
+
+
+ }
+
+
+
+
+
+
+
+
+}
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Resources/FancyStyles.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Resources/FancyStyles.xaml
index fd1c2c4c..a84cf966 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Resources/FancyStyles.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Resources/FancyStyles.xaml
@@ -16,7 +16,7 @@
-
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StylableWindowView.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StyleableWindowView.xaml
similarity index 92%
rename from ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StylableWindowView.xaml
rename to ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StyleableWindowView.xaml
index 1d8b041e..2417692f 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StylableWindowView.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StyleableWindowView.xaml
@@ -13,7 +13,7 @@
Stay informed: follow @datagrid on Twitter or Like http://facebook.com/datagrids
**************************************************************************************-->
-
+ Title="StyleableWindows" >
It is possible to style ChildWindow controls as well as MessageBox controls. All the chrome of their window can be styled (color, thickness, opacity); their action buttons can also be styled.
- The "Plus" version provides a new control called StylableWindow, which consists of a window that has all the functions of a normal window, but which can be styled in the same way as ChildWindow or MessageBox.
+ The "Plus" version provides a new control called StyleableWindow, which consists of a window that has all the functions of a normal window, but which can be styled in the same way as ChildWindow or MessageBox.
Click here for more details about Xceed Extended WPF Toolkit Plus.
@@ -72,7 +72,7 @@
+ between ChildWindow, MessageBox, and StyleableWindow.-->
-
+
+ Content="Show" Click="OnStyleableWindow_Click" >
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StylableWindowView.xaml.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StyleableWindowView.xaml.cs
similarity index 90%
rename from ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StylableWindowView.xaml.cs
rename to ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StyleableWindowView.xaml.cs
index b8fb209e..9896e163 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StylableWindowView.xaml.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/Window/Views/StyleableWindowView.xaml.cs
@@ -34,33 +34,33 @@ using Xceed.Wpf.Toolkit.Primitives;
namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.Window.Views
{
///
- /// Interaction logic for StylableWindowView.xaml
+ /// Interaction logic for StyleableWindowView.xaml
///
- public partial class StylableWindowView : DemoView
+ public partial class StyleableWindowView : DemoView
{
private const string StandardMsgBoxTitle = "Standard MessageBox";
private const string StyledMsgBoxTitle = "Extended WPF Toolkit styled MessageBox";
- private const string StylableWindowTitle = "Extended WPF Toolkit StylableWindow";
+ private const string StyleableWindowTitle = "Extended WPF Toolkit StyleableWindow";
private const string StandardMsgBoxMessage = "The standard system MessageBox will always have this look. No styling is possible.";
private const string StyledMsgBoxMessage = "The Toolkit MessageBox allows you to style it in order to integrate it into your application colors and styles.";
- private const string StylableWindowContent = "This is a StylableWindow that has the same functionality as a normal window.";
+ private const string StyleableWindowContent = "This is a StyleableWindow that has the same functionality as a normal window.";
private const string MessageBoxStyleKey = "messageBoxStyle";
private const string WindowControlStyleKey = "windowControlStyle";
private const string WindowButtonStyle = "FancyButtonStyle";
- private const string StylableWindowMessage = "StylableWindow is a standalone window that can be styled just like ChildWindow or MessageBox. This is a feature of the \"Plus\" version.";
+ private const string StyleableWindowMessage = "StyleableWindow is a standalone window that can be styled just like ChildWindow or MessageBox. This is a feature of the \"Plus\" version.";
- public StylableWindowView()
+ public StyleableWindowView()
{
InitializeComponent();
this.UpdateWindowsStyles(null,null);
}
- private void OnStylableWindow_Click( object sender, RoutedEventArgs e )
+ private void OnStyleableWindow_Click( object sender, RoutedEventArgs e )
{
var msgBox = new Xceed.Wpf.Toolkit.MessageBox();
msgBox.DataContext = this.DataContext;
- msgBox.Text = StylableWindowMessage;
+ msgBox.Text = StyleableWindowMessage;
msgBox.Caption = StyledMsgBoxTitle;
msgBox.Style = ( _enableStyleCheckBox.IsChecked.GetValueOrDefault() ) ? ( Style )this.Resources[ MessageBoxStyleKey ] : null;
msgBox.ShowDialog();
@@ -104,7 +104,7 @@ namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.Window.Views
///
/// This model will allow to share the style values between our MessageBox,
- /// ChildWindow and StylableWindow controls
+ /// ChildWindow and StyleableWindow controls
///
public class WindowModel : DependencyObject
{
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Xceed.Wpf.Toolkit.LiveExplorer.csproj b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Xceed.Wpf.Toolkit.LiveExplorer.csproj
index 69a3d3db..0708f3db 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Xceed.Wpf.Toolkit.LiveExplorer.csproj
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Xceed.Wpf.Toolkit.LiveExplorer.csproj
@@ -276,7 +276,6 @@
PropertyGridView.xaml
-
RangeSliderView.xaml
@@ -323,6 +322,9 @@
ToggleSwitchView.xaml
+
+ TokenizedTextBoxView.xaml
+
@@ -331,8 +333,8 @@
ChildWindowView.xaml
-
- StylableWindowView.xaml
+
+ StyleableWindowView.xaml
WindowContainerView.xaml
@@ -630,6 +632,10 @@
Designer
MSBuild:Compile
+
+ MSBuild:Compile
+ Designer
+
Designer
MSBuild:Compile
@@ -642,7 +648,7 @@
MSBuild:Compile
Designer
-
+
MSBuild:Compile
Designer
@@ -964,8 +970,6 @@
-
-
@@ -1047,10 +1051,20 @@
-
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/app.config b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/app.config
index 0893bea7..a5dd4154 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/app.config
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/app.config
@@ -1,15 +1,23 @@
-
+
-
-
+
+
-
+
-
\ No newline at end of file
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/AssemblyVersionInfo.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/AssemblyVersionInfo.cs
index ce1db48a..693b6601 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/AssemblyVersionInfo.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/AssemblyVersionInfo.cs
@@ -21,7 +21,7 @@
internal static class _XceedVersionInfo
{
[System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )]
- public const string BaseVersion = "2.3";
+ public const string BaseVersion = "2.4";
[System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )]
public const string Version = BaseVersion +
".0.0";
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Implementation/ButtonSpinner.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Implementation/ButtonSpinner.cs
index 0ea459b7..330b8d8f 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Implementation/ButtonSpinner.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Implementation/ButtonSpinner.cs
@@ -21,6 +21,12 @@ using System.Windows.Markup;
namespace Xceed.Wpf.Toolkit
{
+ public enum Location
+ {
+ Left,
+ Right
+ }
+
///
/// Represents a spinner control that includes two Buttons.
///
@@ -57,6 +63,23 @@ namespace Xceed.Wpf.Toolkit
#endregion //AllowSpin
+ #region ButtonSpinnerLocation
+
+ public static readonly DependencyProperty ButtonSpinnerLocationProperty = DependencyProperty.Register( "ButtonSpinnerLocation", typeof( Location ), typeof( ButtonSpinner ), new UIPropertyMetadata( Location.Right ) );
+ public Location ButtonSpinnerLocation
+ {
+ get
+ {
+ return ( Location )GetValue( ButtonSpinnerLocationProperty );
+ }
+ set
+ {
+ SetValue( ButtonSpinnerLocationProperty, value );
+ }
+ }
+
+ #endregion //ButtonSpinnerLocation
+
#region Content
///
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Themes/Aero2.NormalColor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Themes/Aero2.NormalColor.xaml
index a16663a6..2497238d 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Themes/Aero2.NormalColor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Themes/Aero2.NormalColor.xaml
@@ -46,12 +46,12 @@
-
-
+
+
-
+
-
+
@@ -85,7 +85,22 @@
-
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Themes/Generic.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Themes/Generic.xaml
index 91d1fb13..72c4f0c5 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Themes/Generic.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/ButtonSpinner/Themes/Generic.xaml
@@ -44,12 +44,12 @@
-
-
+
+
-
+
-
+
@@ -77,6 +77,21 @@
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Implementation/CollectionControl.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Implementation/CollectionControl.cs
index 20907e41..eb0a4876 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Implementation/CollectionControl.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Implementation/CollectionControl.cs
@@ -23,17 +23,21 @@ using System.Reflection;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
+using Xceed.Wpf.Toolkit.PropertyGrid;
namespace Xceed.Wpf.Toolkit
{
[TemplatePart( Name = PART_NewItemTypesComboBox, Type = typeof( ComboBox ) )]
+ [TemplatePart( Name = PART_PropertyGrid, Type = typeof( PropertyGrid.PropertyGrid ) )]
public class CollectionControl : Control
{
private const string PART_NewItemTypesComboBox = "PART_NewItemTypesComboBox";
+ private const string PART_PropertyGrid = "PART_PropertyGrid";
#region Private Members
private ComboBox _newItemTypesComboBox;
+ private PropertyGrid.PropertyGrid _propertyGrid;
#endregion
@@ -177,6 +181,20 @@ namespace Xceed.Wpf.Toolkit
if( _newItemTypesComboBox != null )
_newItemTypesComboBox.Loaded += new RoutedEventHandler( this.NewItemTypesComboBox_Loaded );
+
+ _propertyGrid = GetTemplateChild( PART_PropertyGrid ) as PropertyGrid.PropertyGrid;
+ }
+
+ public PropertyGrid.PropertyGrid PropertyGrid
+ {
+ get
+ {
+ if( _propertyGrid == null )
+ {
+ this.ApplyTemplate();
+ }
+ return _propertyGrid;
+ }
}
#endregion
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Implementation/CollectionControlDialog.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Implementation/CollectionControlDialog.xaml
index 76e3a691..6dfcf1ca 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Implementation/CollectionControlDialog.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Implementation/CollectionControlDialog.xaml
@@ -29,7 +29,7 @@
-
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Themes/Generic.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Themes/Generic.xaml
index e64b51c4..46756d4e 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Themes/Generic.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/CollectionControl/Themes/Generic.xaml
@@ -123,7 +123,8 @@
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Aero2.NormalColor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Aero2.NormalColor.xaml
index 00f907b3..fdb564bb 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Aero2.NormalColor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Aero2.NormalColor.xaml
@@ -21,44 +21,58 @@
xmlns:prim="clr-namespace:Xceed.Wpf.Toolkit.Primitives"
xmlns:conv="clr-namespace:Xceed.Wpf.Toolkit.Core.Converters">
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
+
+
+
+
-
-
-
-
+
+
+
+
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Generic.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Generic.xaml
index a40aa0ae..944e45e2 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Generic.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Generic.xaml
@@ -46,7 +46,8 @@
BorderThickness="{TemplateBinding BorderThickness}"
BorderBrush="{TemplateBinding BorderBrush}"
AllowSpin="{Binding AllowSpin, RelativeSource={RelativeSource TemplatedParent}}"
- ShowButtonSpinner="{Binding ShowButtonSpinner, RelativeSource={RelativeSource TemplatedParent}}">
+ ShowButtonSpinner="{Binding ShowButtonSpinner, RelativeSource={RelativeSource TemplatedParent}}"
+ ButtonSpinnerLocation="{Binding ButtonSpinnerLocation, RelativeSource={RelativeSource TemplatedParent}}">
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Converters/IntegerToBoolConverter.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Converters/IsStringEmptyConverter.cs
similarity index 59%
rename from ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Converters/IntegerToBoolConverter.cs
rename to ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Converters/IsStringEmptyConverter.cs
index 84140439..7ed0af19 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit.LiveExplorer/Samples/RangeSlider/Converters/IntegerToBoolConverter.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Converters/IsStringEmptyConverter.cs
@@ -1,8 +1,8 @@
-/**************************************************************************************
+/*************************************************************************************
Extended WPF Toolkit
- Copyright (C) 2007-2014 Xceed Software Inc.
+ Copyright (C) 2007-2013 Xceed Software Inc.
This program is provided to you under the terms of the Microsoft Public
License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license
@@ -12,28 +12,27 @@
Stay informed: follow @datagrid on Twitter or Like http://facebook.com/datagrids
- ************************************************************************************/
+ ***********************************************************************************/
+
using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
+using System.Globalization;
using System.Windows.Data;
-namespace Xceed.Wpf.Toolkit.LiveExplorer.Samples.RangeSlider.Converters
+namespace Xceed.Wpf.Toolkit.PropertyGrid.Converters
{
- public class IntegerToBoolConverter: IValueConverter
+ public class IsStringEmptyConverter : IValueConverter
{
- public object Convert( object value, Type targetType, object parameter, System.Globalization.CultureInfo culture )
+ public object Convert( object value, Type targetType, object parameter, CultureInfo culture )
{
- if( value is int )
+ if( value is string )
{
- return (( int )value != 0);
+ return string.IsNullOrEmpty( ( string )value );
}
- return value;
+ return false;
}
- public object ConvertBack( object value, Type targetType, object parameter, System.Globalization.CultureInfo culture )
+ public object ConvertBack( object value, Type targetType, object parameter, CultureInfo culture )
{
throw new NotImplementedException();
}
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/CustomPropertyItem.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/CustomPropertyItem.cs
index 37a285aa..53533f90 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/CustomPropertyItem.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/CustomPropertyItem.cs
@@ -34,6 +34,11 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
internal CustomPropertyItem() { }
+ internal CustomPropertyItem( bool isPropertyGridCategorized )
+ {
+ _isPropertyGridCategorized = isPropertyGridCategorized;
+ }
+
#region Category
public static readonly DependencyProperty CategoryProperty =
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Definitions/EditorDefinitionBase.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Definitions/EditorDefinitionBase.cs
index 6d28674a..b1490e1e 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Definitions/EditorDefinitionBase.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Definitions/EditorDefinitionBase.cs
@@ -42,16 +42,28 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
object currentValue = this.GetValue( definitionProperty );
object localValue = this.ReadLocalValue( definitionProperty );
+ object elementValue = element.GetValue( elementProp );
+ bool areEquals = false;
+
// Avoid setting values if it does not affect anything
// because setting a local value may prevent a style setter from being active.
- if( ( localValue != DependencyProperty.UnsetValue )
- || currentValue != element.GetValue( elementProp ) )
- {
- element.SetValue( elementProp, currentValue );
- }
- else
+ if( localValue != DependencyProperty.UnsetValue )
{
- element.ClearValue( elementProp );
+ if( ( elementValue != null ) && ( currentValue != null ) )
+ {
+ areEquals = ( elementValue.GetType().IsValueType && currentValue.GetType().IsValueType )
+ ? elementValue.Equals( currentValue ) // Value Types
+ : currentValue == element.GetValue( elementProp ); // Reference Types
+ }
+
+ if( !areEquals )
+ {
+ element.SetValue( elementProp, currentValue );
+ }
+ else
+ {
+ element.ClearValue( elementProp );
+ }
}
}
}
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/DescriptorPropertyDefinitionBase.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/DescriptorPropertyDefinitionBase.cs
index 98d2f66b..fc3a4a9f 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/DescriptorPropertyDefinitionBase.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/DescriptorPropertyDefinitionBase.cs
@@ -79,6 +79,9 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
return null;
}
+
+
+
protected virtual int ComputeDisplayOrder( bool isPropertyGridCategorized )
{
return int.MaxValue;
@@ -242,6 +245,10 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
: null;
}
+
+
+
+
internal object ComputeDisplayOrderForItem( object item )
{
PropertyDescriptor pd = item as PropertyDescriptor;
@@ -407,6 +414,9 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
get { return _displayName; }
internal set { _displayName = value; }
}
+
+
+
public string Description
{
get { return _description; }
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/IPropertyContainer.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/IPropertyContainer.cs
index e044a6a6..358f35f8 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/IPropertyContainer.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/IPropertyContainer.cs
@@ -31,6 +31,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
+
ContainerHelperBase ContainerHelper { get; }
Style PropertyContainerStyle { get; }
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/ObjectContainerHelperBase.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/ObjectContainerHelperBase.cs
index 0991ad88..b5c66e45 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/ObjectContainerHelperBase.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/ObjectContainerHelperBase.cs
@@ -47,7 +47,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
_propertyItemCollection = new PropertyItemCollection( new ObservableCollection() );
UpdateFilter();
- UpdateCategorization();
+ UpdateCategorization( false );
}
@@ -137,7 +137,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
protected override void OnCategorizationChanged()
{
- UpdateCategorization();
+ UpdateCategorization( true );
}
protected override void OnAutoGeneratePropertiesChanged()
@@ -165,9 +165,20 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
?? PropertyItemCollection.CreateFilter( filterInfo.InputString );
}
- private void UpdateCategorization()
+ private void UpdateCategorization( bool updateSubPropertiesCategorization )
{
_propertyItemCollection.UpdateCategorization( this.ComputeCategoryGroupDescription(), this.PropertyContainer.IsCategorized );
+ if( updateSubPropertiesCategorization && (_propertyItemCollection.Count > 0) )
+ {
+ foreach( PropertyItem propertyItem in _propertyItemCollection )
+ {
+ PropertyItemCollection subPropertyItemsCollection = propertyItem.Properties as PropertyItemCollection;
+ if( subPropertyItemsCollection != null )
+ {
+ subPropertyItemsCollection.UpdateCategorization( this.ComputeCategoryGroupDescription(), this.PropertyContainer.IsCategorized );
+ }
+ }
+ }
}
private GroupDescription ComputeCategoryGroupDescription()
@@ -218,7 +229,6 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
propertyItem.PropertyChanged -= OnChildrenPropertyChanged;
}
-
PropertyItems.UpdateItems( subProperties );
//Add the event callback to the new childrens
@@ -309,6 +319,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
propertyItem.IsReadOnly = pd.IsReadOnly;
propertyItem.DisplayName = pd.DisplayName;
propertyItem.Description = pd.Description;
+
propertyItem.Category = pd.Category;
propertyItem.PropertyOrder = pd.DisplayOrder;
@@ -344,7 +355,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
propertyItem.SetBinding( itemProperty, binding );
}
- private FrameworkElement GenerateChildrenEditorElement( PropertyItem propertyItem )
+ internal FrameworkElement GenerateChildrenEditorElement( PropertyItem propertyItem )
{
FrameworkElement editorElement = null;
DescriptorPropertyDefinitionBase pd = propertyItem.DescriptorDefinition;
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyDefinitionBaseCollection.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyDefinitionBaseCollection.cs
index 8d12011c..8a1059f0 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyDefinitionBaseCollection.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyDefinitionBaseCollection.cs
@@ -15,17 +15,26 @@
***********************************************************************************/
using System;
+using System.Collections.Generic;
using System.Collections.ObjectModel;
+using System.Linq;
+using System.Windows.Documents;
namespace Xceed.Wpf.Toolkit.PropertyGrid
{
- public class PropertyDefinitionCollection : PropertyDefinitionBaseCollection { }
- public class EditorDefinitionCollection : PropertyDefinitionBaseCollection { }
+ public class PropertyDefinitionCollection : PropertyDefinitionBaseCollection
+ {
+ }
+ public class EditorDefinitionCollection : PropertyDefinitionBaseCollection
+ {
+ }
public abstract class PropertyDefinitionBaseCollection : DefinitionCollectionBase where T : PropertyDefinitionBase
{
- internal PropertyDefinitionBaseCollection() { }
+ internal PropertyDefinitionBaseCollection()
+ {
+ }
public T this[ object propertyId ]
{
@@ -35,6 +44,24 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
if( item.TargetProperties.Contains( propertyId ) )
return item;
+
+ // Using the special character "*" in a string of TargetProperties will
+ // return all the items containing the string (before or after) the "*".
+ // ex : Prop* will return properties named Prop1, Prop2, Prop3...
+ List stringTargetProperties = item.TargetProperties.OfType().ToList();
+ if( (stringTargetProperties != null) && (stringTargetProperties.Count > 0) && ( propertyId is string ) )
+ {
+ string stringPropertyID = ( string )propertyId;
+ foreach( var targetPropertyString in stringTargetProperties )
+ {
+ if( targetPropertyString.Contains( "*" ) )
+ {
+ string searchString = targetPropertyString.Replace( "*", "" );
+ if( stringPropertyID.StartsWith( searchString ) || stringPropertyID.EndsWith( searchString ) )
+ return item;
+ }
+ }
+ }
}
return null;
@@ -56,7 +83,9 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
public abstract class DefinitionCollectionBase : ObservableCollection where T : DefinitionBase
{
- internal DefinitionCollectionBase() { }
+ internal DefinitionCollectionBase()
+ {
+ }
protected override void InsertItem( int index, T item )
{
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyGrid.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyGrid.cs
index 5a9f1ff8..61086d0c 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyGrid.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyGrid.cs
@@ -94,6 +94,23 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
#endregion //AutoGenerateProperties
+ #region ShowDescriptionByTooltip
+
+ public static readonly DependencyProperty ShowDescriptionByTooltipProperty = DependencyProperty.Register( "ShowDescriptionByTooltip", typeof( bool ), typeof( PropertyGrid ), new UIPropertyMetadata( false ) );
+ public bool ShowDescriptionByTooltip
+ {
+ get
+ {
+ return ( bool )GetValue( ShowDescriptionByTooltipProperty );
+ }
+ set
+ {
+ SetValue( ShowDescriptionByTooltipProperty, value );
+ }
+ }
+
+ #endregion //ShowDescriptionByTooltip
+
#region ShowSummary
public static readonly DependencyProperty ShowSummaryProperty = DependencyProperty.Register( "ShowSummary", typeof( bool ), typeof( PropertyGrid ), new UIPropertyMetadata( true ) );
@@ -721,7 +738,6 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
CommandBindings.Add( new CommandBinding( PropertyGridCommands.ClearFilter, ClearFilter, CanClearFilter ) );
}
-
#endregion //Constructors
#region Base Class Overrides
@@ -818,6 +834,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
NameColumnWidth = Math.Max( 0, NameColumnWidth + e.HorizontalChange );
}
+
#endregion //Event Handlers
#region Commands
@@ -917,6 +934,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
+
#endregion //Methods
#region Events
@@ -1129,6 +1147,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
}
}
+
#endregion
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItem.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItem.cs
index fb7f09e4..a89a75be 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItem.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItem.cs
@@ -196,7 +196,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
#region Constructors
internal PropertyItem( DescriptorPropertyDefinitionBase definition )
- : base()
+ : base( definition.IsPropertyGridCategorized )
{
if( definition == null )
throw new ArgumentNullException( "definition" );
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItemBase.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItemBase.cs
index 3b52f4b8..049b5c9f 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItemBase.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItemBase.cs
@@ -40,6 +40,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
private ContentControl _valueContainer;
private ContainerHelperBase _containerHelper;
private IPropertyContainer _parentNode;
+ internal bool _isPropertyGridCategorized;
#region Properties
@@ -416,6 +417,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
+
Style IPropertyContainer.PropertyContainerStyle
{
get { return this.PropertyContainerStyle; }
@@ -441,7 +443,10 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
bool IPropertyContainer.IsCategorized
{
- get { return false; }
+ get
+ {
+ return _isPropertyGridCategorized;
+ }
}
bool IPropertyContainer.AutoGenerateProperties
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Aero2.NormalColor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Aero2.NormalColor.xaml
index 2e214c53..4d564b64 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Aero2.NormalColor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Aero2.NormalColor.xaml
@@ -44,6 +44,7 @@
+
@@ -500,7 +501,28 @@
-
+
+
+
+
+
+
+
+
+ True
+
+
+
+
+
+
+
+
+
+
@@ -615,6 +637,11 @@
+
+
+
+
+
@@ -641,6 +668,17 @@
TargetName="_text"
Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}" />
+
+
+
+
+
+
+
-
-
-
-
-
-
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Generic.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Generic.xaml
index 8c13cee2..792d08b1 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Generic.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Generic.xaml
@@ -41,6 +41,7 @@
+
@@ -197,6 +198,12 @@
+
+
+
+
+
+
@@ -557,6 +564,27 @@
+
+
@@ -656,6 +684,11 @@
+
+
+
+
+
@@ -676,6 +709,17 @@
TargetName="_text"
Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}" />
+
+
+
+
+
+
+
@@ -806,27 +850,7 @@
-
-
-
-
-
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/Converters/SliderThumbWidthConverter.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/Converters/SliderThumbWidthConverter.cs
index c96ee1ee..a36deced 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/Converters/SliderThumbWidthConverter.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/Converters/SliderThumbWidthConverter.cs
@@ -25,6 +25,7 @@ using System.Windows.Data;
namespace Xceed.Wpf.Toolkit.Converters
{
+ [Obsolete("This class is no longer used internaly and may be removed in a future release")]
public class SliderThumbWidthConverter : IValueConverter
{
public object Convert( object value, Type targetType, object parameter, CultureInfo culture )
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/RangeSlider.cs b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/RangeSlider.cs
index fff651b4..14f39322 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/RangeSlider.cs
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/RangeSlider.cs
@@ -49,16 +49,6 @@ namespace Xceed.Wpf.Toolkit
#endregion Members
- #region Enums
-
- public enum OrientationEnum
- {
- Horizontal,
- Vertical
- };
-
- #endregion Enums
-
#region Constructors
static RangeSlider()
@@ -177,7 +167,7 @@ namespace Xceed.Wpf.Toolkit
/// HigherValue property represents the higher value within the selected range.
///
public static readonly DependencyProperty HigherValueProperty = DependencyProperty.Register( "HigherValue", typeof( double ), typeof( RangeSlider )
- , new FrameworkPropertyMetadata( RangeSlider.OnHigherValueChanged, RangeSlider.CoerceHigherValue ) );
+ , new FrameworkPropertyMetadata( 0d, FrameworkPropertyMetadataOptions.BindsTwoWayByDefault, RangeSlider.OnHigherValueChanged ) );
public double HigherValue
{
@@ -191,14 +181,6 @@ namespace Xceed.Wpf.Toolkit
}
}
- private static object CoerceHigherValue( DependencyObject sender, object value )
- {
- RangeSlider rangeSlider = sender as RangeSlider;
- double newValue = ( double )value;
-
- return Math.Max( rangeSlider.LowerValue, Math.Max( rangeSlider.Minimum, Math.Min( rangeSlider.Maximum, newValue ) ) );
- }
-
private static void OnHigherValueChanged( DependencyObject sender, DependencyPropertyChangedEventArgs args )
{
RangeSlider rangeSlider = sender as RangeSlider;
@@ -210,7 +192,7 @@ namespace Xceed.Wpf.Toolkit
protected virtual void OnHigherValueChanged( double oldValue, double newValue )
{
- this.AdjustWidths( this.Minimum, this.Maximum, this.LowerValue, newValue );
+ this.AdjustView();
RoutedEventArgs args = new RoutedEventArgs();
args.RoutedEvent = RangeSlider.HigherValueChangedEvent;
@@ -273,7 +255,7 @@ namespace Xceed.Wpf.Toolkit
///
private static DependencyPropertyKey LowerRangeWidthPropertyKey = DependencyProperty.RegisterAttachedReadOnly( "LowerRangeWidth", typeof( double )
- , typeof( RangeSlider ), new PropertyMetadata( 0d ) );
+ , typeof( RangeSlider ), new PropertyMetadata( 0d ) );
public static readonly DependencyProperty LowerRangeWidthProperty = LowerRangeWidthPropertyKey.DependencyProperty;
@@ -319,7 +301,7 @@ namespace Xceed.Wpf.Toolkit
/// LowerValue property represents the lower value within the selected range.
///
public static readonly DependencyProperty LowerValueProperty = DependencyProperty.Register( "LowerValue", typeof( double ), typeof( RangeSlider )
- , new FrameworkPropertyMetadata( RangeSlider.OnLowerValueChanged, RangeSlider.CoerceLowerValue ) );
+ , new FrameworkPropertyMetadata( 0d, FrameworkPropertyMetadataOptions.BindsTwoWayByDefault, RangeSlider.OnLowerValueChanged ) );
public double LowerValue
{
@@ -333,19 +315,6 @@ namespace Xceed.Wpf.Toolkit
}
}
- private static object CoerceLowerValue( DependencyObject sender, object value )
- {
- RangeSlider rangeSlider = sender as RangeSlider;
- double newValue = ( double )value;
-
- if( ( rangeSlider.HigherValue == 0 ) && ( rangeSlider.LowerValue == 0 ) )
- newValue = Math.Max( rangeSlider.Minimum, Math.Min( rangeSlider.Maximum, newValue ) );
- else
- newValue = Math.Min( Math.Max( rangeSlider.Minimum, Math.Min( rangeSlider.Maximum, newValue ) ), rangeSlider.HigherValue );
-
- return newValue;
- }
-
private static void OnLowerValueChanged( DependencyObject sender, DependencyPropertyChangedEventArgs args )
{
RangeSlider rangeSlider = sender as RangeSlider;
@@ -357,9 +326,7 @@ namespace Xceed.Wpf.Toolkit
protected virtual void OnLowerValueChanged( double oldValue, double newValue )
{
- this.HigherValue = Math.Max( this.HigherValue, newValue );
-
- this.AdjustWidths( this.Minimum, this.Maximum, newValue, this.HigherValue );
+ this.AdjustView();
RoutedEventArgs args = new RoutedEventArgs();
args.RoutedEvent = RangeSlider.LowerValueChangedEvent;
@@ -374,7 +341,7 @@ namespace Xceed.Wpf.Toolkit
/// Maximum property represents the maximum value, which can be selected, in a range.
///
public static readonly DependencyProperty MaximumProperty = DependencyProperty.Register( "Maximum", typeof( double ), typeof( RangeSlider )
- , new FrameworkPropertyMetadata( RangeSlider.OnMaximumChanged, RangeSlider.CoerceMaximum ) );
+ , new FrameworkPropertyMetadata( RangeSlider.OnMaximumChanged ) );
public double Maximum
{
@@ -388,14 +355,6 @@ namespace Xceed.Wpf.Toolkit
}
}
- private static object CoerceMaximum( DependencyObject sender, object value )
- {
- RangeSlider rangeSlider = sender as RangeSlider;
- double newValue = ( double )value;
-
- return Math.Max( newValue, rangeSlider.HigherValue );
- }
-
private static void OnMaximumChanged( DependencyObject sender, DependencyPropertyChangedEventArgs args )
{
RangeSlider rangeSlider = sender as RangeSlider;
@@ -407,7 +366,7 @@ namespace Xceed.Wpf.Toolkit
protected virtual void OnMaximumChanged( double oldValue, double newValue )
{
- this.AdjustWidths( this.Minimum, newValue, this.LowerValue, this.HigherValue );
+ this.AdjustView();
}
#endregion Maximum
@@ -418,7 +377,7 @@ namespace Xceed.Wpf.Toolkit
/// Minimum property represents the minimum value, which can be selected, in a range.
///
public static readonly DependencyProperty MinimumProperty = DependencyProperty.Register( "Minimum", typeof( double ), typeof( RangeSlider )
- , new FrameworkPropertyMetadata( RangeSlider.OnMinimumChanged, RangeSlider.CoerceMinimum ) );
+ , new FrameworkPropertyMetadata( RangeSlider.OnMinimumChanged ) );
public double Minimum
{
@@ -432,23 +391,6 @@ namespace Xceed.Wpf.Toolkit
}
}
- private static object CoerceMinimum( DependencyObject sender, object value )
- {
- RangeSlider rangeSlider = sender as RangeSlider;
- double newValue = ( double )value;
-
- if( ( rangeSlider.Minimum == 0.0 ) && ( rangeSlider.LowerValue == 0 ) && ( rangeSlider.HigherValue == 0 ) && ( rangeSlider.Maximum == 0 ) )
- {
- newValue = Math.Max( newValue, rangeSlider.LowerValue );
- }
- else
- {
- newValue = Math.Min( newValue, rangeSlider.LowerValue );
- }
-
- return newValue;
- }
-
private static void OnMinimumChanged( DependencyObject sender, DependencyPropertyChangedEventArgs args )
{
RangeSlider rangeSlider = sender as RangeSlider;
@@ -461,7 +403,7 @@ namespace Xceed.Wpf.Toolkit
protected virtual void OnMinimumChanged( double oldValue, double newValue )
{
// adjust the range width
- this.AdjustWidths( newValue, this.Maximum, this.LowerValue, this.HigherValue );
+ this.AdjustView();
}
#endregion Minimum
@@ -472,14 +414,14 @@ namespace Xceed.Wpf.Toolkit
/// # TODODOC
/// Get/Set the RangeSlider orientation.
///
- public static readonly DependencyProperty OrientationProperty = DependencyProperty.Register( "Orientation", typeof( OrientationEnum ), typeof( RangeSlider ),
- new FrameworkPropertyMetadata( OrientationEnum.Horizontal, RangeSlider.OnOrientationChanged ) );
+ public static readonly DependencyProperty OrientationProperty = DependencyProperty.Register( "Orientation", typeof( Orientation ), typeof( RangeSlider ),
+ new FrameworkPropertyMetadata( Orientation.Horizontal, RangeSlider.OnOrientationChanged ) );
- public OrientationEnum Orientation
+ public Orientation Orientation
{
get
{
- return ( OrientationEnum )GetValue( RangeSlider.OrientationProperty );
+ return ( Orientation )GetValue( RangeSlider.OrientationProperty );
}
set
{
@@ -492,11 +434,11 @@ namespace Xceed.Wpf.Toolkit
RangeSlider rangeSlider = sender as RangeSlider;
if( rangeSlider != null )
{
- rangeSlider.OnOrientationChanged( ( OrientationEnum )e.OldValue, ( OrientationEnum )e.NewValue );
+ rangeSlider.OnOrientationChanged( ( Orientation )e.OldValue, ( Orientation )e.NewValue );
}
}
- protected virtual void OnOrientationChanged( OrientationEnum oldValue, OrientationEnum newValue )
+ protected virtual void OnOrientationChanged( Orientation oldValue, Orientation newValue )
{
}
@@ -635,21 +577,25 @@ namespace Xceed.Wpf.Toolkit
if( _lowerSlider != null )
{
_lowerSlider.Loaded -= this.Slider_Loaded;
+ _lowerSlider.ValueChanged -= LowerSlider_ValueChanged;
}
_lowerSlider = this.Template.FindName( PART_LowerSlider, this ) as Slider;
if( _lowerSlider != null )
{
_lowerSlider.Loaded += this.Slider_Loaded;
+ _lowerSlider.ValueChanged += LowerSlider_ValueChanged;
}
if( _higherSlider != null )
{
- _higherSlider.Loaded -= this.Slider_Loaded;
+ _higherSlider.Loaded -= this.Slider_Loaded;
+ _higherSlider.ValueChanged -= HigherSlider_ValueChanged;
}
_higherSlider = this.Template.FindName( PART_HigherSlider, this ) as Slider;
if( _higherSlider != null )
{
- _higherSlider.Loaded += this.Slider_Loaded;
+ _higherSlider.Loaded += this.Slider_Loaded;
+ _higherSlider.ValueChanged += HigherSlider_ValueChanged;
}
}
@@ -690,19 +636,22 @@ namespace Xceed.Wpf.Toolkit
return 0d;
}
- private void AdjustWidths( double minimum, double maximum, double lowerValue, double higherValue )
+ private void AdjustView()
{
+ //Coerce values to make them consistent.
+ CoercedValues cv = this.GetCoercedValues();
+
double actualWidth = 0;
double lowerSliderThumbWidth = 0d;
double higherSliderThumbWidth = 0d;
- if( this.Orientation == OrientationEnum.Horizontal )
+ if( this.Orientation == Orientation.Horizontal )
{
actualWidth = this.ActualWidth;
lowerSliderThumbWidth = RangeSlider.GetThumbWidth( _lowerSlider );
higherSliderThumbWidth = RangeSlider.GetThumbWidth( _higherSlider );
}
- else if( this.Orientation == OrientationEnum.Vertical )
+ else if( this.Orientation == Orientation.Vertical )
{
actualWidth = this.ActualHeight;
lowerSliderThumbWidth = RangeSlider.GetThumbHeight( _lowerSlider );
@@ -711,20 +660,34 @@ namespace Xceed.Wpf.Toolkit
actualWidth -= ( lowerSliderThumbWidth + higherSliderThumbWidth );
- double entireRange = maximum - minimum;
+ this.SetLowerSliderValues( cv.LowerValue, cv.Minimum, cv.Maximum );
+ this.SetHigherSliderValues( cv.HigherValue, cv.Minimum, cv.Maximum );
+
+ double entireRange = cv.Maximum - cv.Minimum;
+
+ if( entireRange > 0 )
+ {
+ this.HigherRangeWidth = ( actualWidth * ( cv.Maximum - cv.HigherValue ) ) / entireRange;
+
+ this.RangeWidth = ( actualWidth * ( cv.HigherValue - cv.LowerValue ) ) / entireRange;
- this.HigherRangeWidth = ( actualWidth * ( maximum - higherValue ) ) / entireRange;
+ this.LowerRangeWidth = ( actualWidth * ( cv.LowerValue - cv.Minimum ) ) / entireRange;
+ }
+ else
+ {
+ this.HigherRangeWidth = 0d;
+ this.RangeWidth = 0d;
+ this.LowerRangeWidth = actualWidth;
+ }
- this.RangeWidth = ( actualWidth * ( higherValue - lowerValue ) ) / entireRange;
- this.LowerRangeWidth = ( actualWidth * ( lowerValue - minimum ) ) / entireRange;
}
private void SetSlidersMargins()
{
if( ( _lowerSlider != null ) && ( _higherSlider != null ) )
{
- if( this.Orientation == OrientationEnum.Horizontal )
+ if( this.Orientation == Orientation.Horizontal )
{
double lowerSliderThumbWidth = RangeSlider.GetThumbWidth( _lowerSlider );
double higherSliderThumbWidth = RangeSlider.GetThumbWidth( _higherSlider );
@@ -743,6 +706,53 @@ namespace Xceed.Wpf.Toolkit
}
}
+ private CoercedValues GetCoercedValues()
+ {
+ CoercedValues cv = new CoercedValues();
+ cv.Minimum = Math.Min( this.Minimum, this.Maximum );
+ cv.Maximum = Math.Max( cv.Minimum, this.Maximum );
+ cv.LowerValue = Math.Max( cv.Minimum, Math.Min( cv.Maximum, this.LowerValue ) );
+ cv.HigherValue = Math.Max( cv.Minimum, Math.Min( cv.Maximum, this.HigherValue ) );
+ cv.HigherValue = Math.Max( cv.LowerValue, cv.HigherValue );
+
+ return cv;
+ }
+
+ private void SetLowerSliderValues( double value, double? minimum, double? maximum )
+ {
+ this.SetSliderValues( _lowerSlider, this.LowerSlider_ValueChanged, value, minimum, maximum );
+ }
+
+ private void SetHigherSliderValues( double value, double? minimum, double? maximum )
+ {
+ this.SetSliderValues( _higherSlider, this.HigherSlider_ValueChanged, value, minimum, maximum );
+ }
+
+ private void SetSliderValues(
+ Slider slider,
+ RoutedPropertyChangedEventHandler handler,
+ double value,
+ double? minimum,
+ double? maximum )
+ {
+ if( slider != null )
+ {
+ slider.ValueChanged -= handler;
+
+ slider.Value = value;
+ if( minimum != null )
+ {
+ slider.Minimum = minimum.Value;
+ }
+ if( maximum != null )
+ {
+ slider.Maximum = maximum.Value;
+ }
+
+ slider.ValueChanged += handler;
+ }
+ }
+
#endregion
#region Events
@@ -779,25 +789,73 @@ namespace Xceed.Wpf.Toolkit
private void LowerRange_Click(object sender, RoutedEventArgs e)
{
- this.LowerValue -= this.Step;
+ CoercedValues cv = this.GetCoercedValues();
+ //When Maximum is not greater than Minimum, the
+ //slider display is in an inconsistant state. Don't
+ //consider any operation from the user
+ if( cv.Minimum < cv.Maximum )
+ {
+ double newValue = cv.LowerValue - this.Step;
+ this.LowerValue = Math.Min( cv.Maximum, Math.Max( cv.Minimum, newValue ) );
+ }
}
private void HigherRange_Click(object sender, RoutedEventArgs e)
{
- this.HigherValue += this.Step;
+ CoercedValues cv = this.GetCoercedValues();
+ //When Maximum is not greater than Minimum, the
+ //slider display is in an inconsistant state. Don't
+ //consider any operation from the user
+ if( cv.Minimum < cv.Maximum )
+ {
+ double newValue = cv.HigherValue + this.Step;
+ this.HigherValue = Math.Min( cv.Maximum, Math.Max( cv.Minimum, newValue ) );
+ }
}
private void RangeSlider_SizeChanged( object sender, SizeChangedEventArgs e )
{
- this.AdjustWidths( this.Minimum, this.Maximum, this.LowerValue, this.HigherValue );
+ this.AdjustView();
}
private void Slider_Loaded( object sender, RoutedEventArgs e )
{
this.SetSlidersMargins();
- this.AdjustWidths( this.Minimum, this.Maximum, this.LowerValue, this.HigherValue );
+ this.AdjustView();
+ }
+
+ private void LowerSlider_ValueChanged( object sender, RoutedPropertyChangedEventArgs e )
+ {
+ if( _lowerSlider.IsLoaded )
+ {
+ CoercedValues cv = this.GetCoercedValues();
+ double newValue = Math.Max( cv.Minimum, Math.Min( cv.Maximum, e.NewValue ) );
+ newValue = Math.Min( newValue, cv.HigherValue );
+ this.SetLowerSliderValues( newValue, null, null );
+ this.LowerValue = newValue;
+ }
+ }
+
+ private void HigherSlider_ValueChanged( object sender, RoutedPropertyChangedEventArgs e )
+ {
+ if( _higherSlider.IsLoaded )
+ {
+ CoercedValues cv = this.GetCoercedValues();
+ double newValue = Math.Max( cv.Minimum, Math.Min( cv.Maximum, e.NewValue ) );
+ newValue = Math.Max( newValue, cv.LowerValue );
+ this.SetHigherSliderValues( newValue, null, null );
+ this.HigherValue = newValue;
+ }
}
#endregion Events Handlers
+
+ private struct CoercedValues
+ {
+ public double Minimum;
+ public double Maximum;
+ public double LowerValue;
+ public double HigherValue;
+ }
}
}
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Themes/Aero2.NormalColor.xaml b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Themes/Aero2.NormalColor.xaml
index 499c266c..2776dfc9 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Themes/Aero2.NormalColor.xaml
+++ b/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.Toolkit/RangeSlider/Themes/Aero2.NormalColor.xaml
@@ -22,30 +22,46 @@
xmlns:conv="clr-namespace:Xceed.Wpf.Toolkit.Converters"
xmlns:coreConv="clr-namespace:Xceed.Wpf.Toolkit.Core.Converters">
-
+
+
+
+
+
+
-
-
-
-
-
-
@@ -107,451 +121,192 @@
TargetName="MainBorder"
Value="#FFF0F0F0" />
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
-
-
-
-
-
-
-
-
+
-
-
-
+
+
+
+
+
+
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
-
+
-
-
-
-
+
+
+
+
+
+
+
-
@@ -230,7 +173,7 @@
-
@@ -259,412 +202,167 @@
-
+
-
-
-
-
-
-
-
-
-
-
+
-
+
-
-
-
+
+
+
+
+
+
+
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Aero2.NormalColor.xaml b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Aero2.NormalColor.xaml
index 00f907b3..fdb564bb 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Aero2.NormalColor.xaml
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Aero2.NormalColor.xaml
@@ -21,44 +21,58 @@
xmlns:prim="clr-namespace:Xceed.Wpf.Toolkit.Primitives"
xmlns:conv="clr-namespace:Xceed.Wpf.Toolkit.Core.Converters">
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
+
+
+
+
-
-
-
-
+
+
+
+
-
+
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Generic.xaml b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Generic.xaml
index a40aa0ae..944e45e2 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Generic.xaml
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/NumericUpDown/Themes/Generic.xaml
@@ -46,7 +46,8 @@
BorderThickness="{TemplateBinding BorderThickness}"
BorderBrush="{TemplateBinding BorderBrush}"
AllowSpin="{Binding AllowSpin, RelativeSource={RelativeSource TemplatedParent}}"
- ShowButtonSpinner="{Binding ShowButtonSpinner, RelativeSource={RelativeSource TemplatedParent}}">
+ ShowButtonSpinner="{Binding ShowButtonSpinner, RelativeSource={RelativeSource TemplatedParent}}"
+ ButtonSpinnerLocation="{Binding ButtonSpinnerLocation, RelativeSource={RelativeSource TemplatedParent}}">
+
+
+
+
+
+
+
+
+
+
diff --git a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/Converters/FilterCriterionToForeignKeyConverter.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Converters/IsStringEmptyConverter.cs
similarity index 57%
rename from ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/Converters/FilterCriterionToForeignKeyConverter.cs
rename to ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Converters/IsStringEmptyConverter.cs
index 779b5cab..7ed0af19 100644
--- a/ExtendedWPFToolkitSolution/Src/Xceed.Wpf.DataGrid/Converters/FilterCriterionToForeignKeyConverter.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Converters/IsStringEmptyConverter.cs
@@ -18,39 +18,23 @@ using System;
using System.Globalization;
using System.Windows.Data;
-using Xceed.Wpf.DataGrid.FilterCriteria;
-
-namespace Xceed.Wpf.DataGrid.Converters
+namespace Xceed.Wpf.Toolkit.PropertyGrid.Converters
{
- [ValueConversion( typeof( FilterCriterion ), typeof( Nullable ) )]
- internal class FilterCriterionToForeignKeyConverter : IValueConverter
+ public class IsStringEmptyConverter : IValueConverter
{
- #region IValueConverter Members
-
public object Convert( object value, Type targetType, object parameter, CultureInfo culture )
{
- EqualToFilterCriterion filterCriterion = value as EqualToFilterCriterion;
-
- if( filterCriterion != null )
+ if( value is string )
{
- return filterCriterion.Value;
+ return string.IsNullOrEmpty( ( string )value );
}
- return null;
+ return false;
}
public object ConvertBack( object value, Type targetType, object parameter, CultureInfo culture )
{
- if( ( value == null ) || ( value == DBNull.Value ) )
- {
- return null;
- }
- else
- {
- return new EqualToFilterCriterion( value );
- }
+ throw new NotImplementedException();
}
-
- #endregion
}
}
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/CustomPropertyItem.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/CustomPropertyItem.cs
index 37a285aa..53533f90 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/CustomPropertyItem.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/CustomPropertyItem.cs
@@ -34,6 +34,11 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
internal CustomPropertyItem() { }
+ internal CustomPropertyItem( bool isPropertyGridCategorized )
+ {
+ _isPropertyGridCategorized = isPropertyGridCategorized;
+ }
+
#region Category
public static readonly DependencyProperty CategoryProperty =
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Definitions/EditorDefinitionBase.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Definitions/EditorDefinitionBase.cs
index 6d28674a..b1490e1e 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Definitions/EditorDefinitionBase.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/Definitions/EditorDefinitionBase.cs
@@ -42,16 +42,28 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
object currentValue = this.GetValue( definitionProperty );
object localValue = this.ReadLocalValue( definitionProperty );
+ object elementValue = element.GetValue( elementProp );
+ bool areEquals = false;
+
// Avoid setting values if it does not affect anything
// because setting a local value may prevent a style setter from being active.
- if( ( localValue != DependencyProperty.UnsetValue )
- || currentValue != element.GetValue( elementProp ) )
- {
- element.SetValue( elementProp, currentValue );
- }
- else
+ if( localValue != DependencyProperty.UnsetValue )
{
- element.ClearValue( elementProp );
+ if( ( elementValue != null ) && ( currentValue != null ) )
+ {
+ areEquals = ( elementValue.GetType().IsValueType && currentValue.GetType().IsValueType )
+ ? elementValue.Equals( currentValue ) // Value Types
+ : currentValue == element.GetValue( elementProp ); // Reference Types
+ }
+
+ if( !areEquals )
+ {
+ element.SetValue( elementProp, currentValue );
+ }
+ else
+ {
+ element.ClearValue( elementProp );
+ }
}
}
}
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/DescriptorPropertyDefinitionBase.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/DescriptorPropertyDefinitionBase.cs
index 98d2f66b..fc3a4a9f 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/DescriptorPropertyDefinitionBase.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/DescriptorPropertyDefinitionBase.cs
@@ -79,6 +79,9 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
return null;
}
+
+
+
protected virtual int ComputeDisplayOrder( bool isPropertyGridCategorized )
{
return int.MaxValue;
@@ -242,6 +245,10 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
: null;
}
+
+
+
+
internal object ComputeDisplayOrderForItem( object item )
{
PropertyDescriptor pd = item as PropertyDescriptor;
@@ -407,6 +414,9 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
get { return _displayName; }
internal set { _displayName = value; }
}
+
+
+
public string Description
{
get { return _description; }
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/IPropertyContainer.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/IPropertyContainer.cs
index e044a6a6..358f35f8 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/IPropertyContainer.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/IPropertyContainer.cs
@@ -31,6 +31,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
+
ContainerHelperBase ContainerHelper { get; }
Style PropertyContainerStyle { get; }
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/ObjectContainerHelperBase.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/ObjectContainerHelperBase.cs
index 0991ad88..b5c66e45 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/ObjectContainerHelperBase.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/ObjectContainerHelperBase.cs
@@ -47,7 +47,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
_propertyItemCollection = new PropertyItemCollection( new ObservableCollection() );
UpdateFilter();
- UpdateCategorization();
+ UpdateCategorization( false );
}
@@ -137,7 +137,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
protected override void OnCategorizationChanged()
{
- UpdateCategorization();
+ UpdateCategorization( true );
}
protected override void OnAutoGeneratePropertiesChanged()
@@ -165,9 +165,20 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
?? PropertyItemCollection.CreateFilter( filterInfo.InputString );
}
- private void UpdateCategorization()
+ private void UpdateCategorization( bool updateSubPropertiesCategorization )
{
_propertyItemCollection.UpdateCategorization( this.ComputeCategoryGroupDescription(), this.PropertyContainer.IsCategorized );
+ if( updateSubPropertiesCategorization && (_propertyItemCollection.Count > 0) )
+ {
+ foreach( PropertyItem propertyItem in _propertyItemCollection )
+ {
+ PropertyItemCollection subPropertyItemsCollection = propertyItem.Properties as PropertyItemCollection;
+ if( subPropertyItemsCollection != null )
+ {
+ subPropertyItemsCollection.UpdateCategorization( this.ComputeCategoryGroupDescription(), this.PropertyContainer.IsCategorized );
+ }
+ }
+ }
}
private GroupDescription ComputeCategoryGroupDescription()
@@ -218,7 +229,6 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
propertyItem.PropertyChanged -= OnChildrenPropertyChanged;
}
-
PropertyItems.UpdateItems( subProperties );
//Add the event callback to the new childrens
@@ -309,6 +319,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
propertyItem.IsReadOnly = pd.IsReadOnly;
propertyItem.DisplayName = pd.DisplayName;
propertyItem.Description = pd.Description;
+
propertyItem.Category = pd.Category;
propertyItem.PropertyOrder = pd.DisplayOrder;
@@ -344,7 +355,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
propertyItem.SetBinding( itemProperty, binding );
}
- private FrameworkElement GenerateChildrenEditorElement( PropertyItem propertyItem )
+ internal FrameworkElement GenerateChildrenEditorElement( PropertyItem propertyItem )
{
FrameworkElement editorElement = null;
DescriptorPropertyDefinitionBase pd = propertyItem.DescriptorDefinition;
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyDefinitionBaseCollection.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyDefinitionBaseCollection.cs
index 8d12011c..8a1059f0 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyDefinitionBaseCollection.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyDefinitionBaseCollection.cs
@@ -15,17 +15,26 @@
***********************************************************************************/
using System;
+using System.Collections.Generic;
using System.Collections.ObjectModel;
+using System.Linq;
+using System.Windows.Documents;
namespace Xceed.Wpf.Toolkit.PropertyGrid
{
- public class PropertyDefinitionCollection : PropertyDefinitionBaseCollection { }
- public class EditorDefinitionCollection : PropertyDefinitionBaseCollection { }
+ public class PropertyDefinitionCollection : PropertyDefinitionBaseCollection
+ {
+ }
+ public class EditorDefinitionCollection : PropertyDefinitionBaseCollection
+ {
+ }
public abstract class PropertyDefinitionBaseCollection : DefinitionCollectionBase where T : PropertyDefinitionBase
{
- internal PropertyDefinitionBaseCollection() { }
+ internal PropertyDefinitionBaseCollection()
+ {
+ }
public T this[ object propertyId ]
{
@@ -35,6 +44,24 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
{
if( item.TargetProperties.Contains( propertyId ) )
return item;
+
+ // Using the special character "*" in a string of TargetProperties will
+ // return all the items containing the string (before or after) the "*".
+ // ex : Prop* will return properties named Prop1, Prop2, Prop3...
+ List stringTargetProperties = item.TargetProperties.OfType().ToList();
+ if( (stringTargetProperties != null) && (stringTargetProperties.Count > 0) && ( propertyId is string ) )
+ {
+ string stringPropertyID = ( string )propertyId;
+ foreach( var targetPropertyString in stringTargetProperties )
+ {
+ if( targetPropertyString.Contains( "*" ) )
+ {
+ string searchString = targetPropertyString.Replace( "*", "" );
+ if( stringPropertyID.StartsWith( searchString ) || stringPropertyID.EndsWith( searchString ) )
+ return item;
+ }
+ }
+ }
}
return null;
@@ -56,7 +83,9 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
public abstract class DefinitionCollectionBase : ObservableCollection where T : DefinitionBase
{
- internal DefinitionCollectionBase() { }
+ internal DefinitionCollectionBase()
+ {
+ }
protected override void InsertItem( int index, T item )
{
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyGrid.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyGrid.cs
index 5a9f1ff8..61086d0c 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyGrid.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyGrid.cs
@@ -94,6 +94,23 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
#endregion //AutoGenerateProperties
+ #region ShowDescriptionByTooltip
+
+ public static readonly DependencyProperty ShowDescriptionByTooltipProperty = DependencyProperty.Register( "ShowDescriptionByTooltip", typeof( bool ), typeof( PropertyGrid ), new UIPropertyMetadata( false ) );
+ public bool ShowDescriptionByTooltip
+ {
+ get
+ {
+ return ( bool )GetValue( ShowDescriptionByTooltipProperty );
+ }
+ set
+ {
+ SetValue( ShowDescriptionByTooltipProperty, value );
+ }
+ }
+
+ #endregion //ShowDescriptionByTooltip
+
#region ShowSummary
public static readonly DependencyProperty ShowSummaryProperty = DependencyProperty.Register( "ShowSummary", typeof( bool ), typeof( PropertyGrid ), new UIPropertyMetadata( true ) );
@@ -721,7 +738,6 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
CommandBindings.Add( new CommandBinding( PropertyGridCommands.ClearFilter, ClearFilter, CanClearFilter ) );
}
-
#endregion //Constructors
#region Base Class Overrides
@@ -818,6 +834,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
NameColumnWidth = Math.Max( 0, NameColumnWidth + e.HorizontalChange );
}
+
#endregion //Event Handlers
#region Commands
@@ -917,6 +934,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
+
#endregion //Methods
#region Events
@@ -1129,6 +1147,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
}
}
+
#endregion
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItem.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItem.cs
index fb7f09e4..a89a75be 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItem.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItem.cs
@@ -196,7 +196,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
#region Constructors
internal PropertyItem( DescriptorPropertyDefinitionBase definition )
- : base()
+ : base( definition.IsPropertyGridCategorized )
{
if( definition == null )
throw new ArgumentNullException( "definition" );
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItemBase.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItemBase.cs
index 3b52f4b8..049b5c9f 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItemBase.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Implementation/PropertyItemBase.cs
@@ -40,6 +40,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
private ContentControl _valueContainer;
private ContainerHelperBase _containerHelper;
private IPropertyContainer _parentNode;
+ internal bool _isPropertyGridCategorized;
#region Properties
@@ -416,6 +417,7 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
+
Style IPropertyContainer.PropertyContainerStyle
{
get { return this.PropertyContainerStyle; }
@@ -441,7 +443,10 @@ namespace Xceed.Wpf.Toolkit.PropertyGrid
bool IPropertyContainer.IsCategorized
{
- get { return false; }
+ get
+ {
+ return _isPropertyGridCategorized;
+ }
}
bool IPropertyContainer.AutoGenerateProperties
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Aero2.NormalColor.xaml b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Aero2.NormalColor.xaml
index ec009d6d..c329a4f1 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Aero2.NormalColor.xaml
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Aero2.NormalColor.xaml
@@ -44,6 +44,7 @@
+
@@ -500,7 +501,25 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -615,6 +634,11 @@
+
+
+
+
+
@@ -641,6 +665,17 @@
TargetName="_text"
Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}" />
+
+
+
+
+
+
+
-
-
-
-
-
-
+
+
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Generic.xaml b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Generic.xaml
index 944a4a6e..a993532f 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Generic.xaml
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/PropertyGrid/Themes/Generic.xaml
@@ -41,6 +41,7 @@
+
@@ -197,6 +198,12 @@
+
+
+
+
+
+
@@ -557,6 +564,24 @@
+
+
@@ -656,6 +681,11 @@
+
+
+
+
+
@@ -676,6 +706,17 @@
TargetName="_text"
Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}" />
+
+
+
+
+
+
+
@@ -806,24 +847,7 @@
-
-
-
-
-
+
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/Converters/SliderThumbWidthConverter.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/Converters/SliderThumbWidthConverter.cs
index c96ee1ee..a36deced 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/Converters/SliderThumbWidthConverter.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/Converters/SliderThumbWidthConverter.cs
@@ -25,6 +25,7 @@ using System.Windows.Data;
namespace Xceed.Wpf.Toolkit.Converters
{
+ [Obsolete("This class is no longer used internaly and may be removed in a future release")]
public class SliderThumbWidthConverter : IValueConverter
{
public object Convert( object value, Type targetType, object parameter, CultureInfo culture )
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/RangeSlider.cs b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/RangeSlider.cs
index fff651b4..14f39322 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/RangeSlider.cs
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Implementation/RangeSlider.cs
@@ -49,16 +49,6 @@ namespace Xceed.Wpf.Toolkit
#endregion Members
- #region Enums
-
- public enum OrientationEnum
- {
- Horizontal,
- Vertical
- };
-
- #endregion Enums
-
#region Constructors
static RangeSlider()
@@ -177,7 +167,7 @@ namespace Xceed.Wpf.Toolkit
/// HigherValue property represents the higher value within the selected range.
///
public static readonly DependencyProperty HigherValueProperty = DependencyProperty.Register( "HigherValue", typeof( double ), typeof( RangeSlider )
- , new FrameworkPropertyMetadata( RangeSlider.OnHigherValueChanged, RangeSlider.CoerceHigherValue ) );
+ , new FrameworkPropertyMetadata( 0d, FrameworkPropertyMetadataOptions.BindsTwoWayByDefault, RangeSlider.OnHigherValueChanged ) );
public double HigherValue
{
@@ -191,14 +181,6 @@ namespace Xceed.Wpf.Toolkit
}
}
- private static object CoerceHigherValue( DependencyObject sender, object value )
- {
- RangeSlider rangeSlider = sender as RangeSlider;
- double newValue = ( double )value;
-
- return Math.Max( rangeSlider.LowerValue, Math.Max( rangeSlider.Minimum, Math.Min( rangeSlider.Maximum, newValue ) ) );
- }
-
private static void OnHigherValueChanged( DependencyObject sender, DependencyPropertyChangedEventArgs args )
{
RangeSlider rangeSlider = sender as RangeSlider;
@@ -210,7 +192,7 @@ namespace Xceed.Wpf.Toolkit
protected virtual void OnHigherValueChanged( double oldValue, double newValue )
{
- this.AdjustWidths( this.Minimum, this.Maximum, this.LowerValue, newValue );
+ this.AdjustView();
RoutedEventArgs args = new RoutedEventArgs();
args.RoutedEvent = RangeSlider.HigherValueChangedEvent;
@@ -273,7 +255,7 @@ namespace Xceed.Wpf.Toolkit
///
private static DependencyPropertyKey LowerRangeWidthPropertyKey = DependencyProperty.RegisterAttachedReadOnly( "LowerRangeWidth", typeof( double )
- , typeof( RangeSlider ), new PropertyMetadata( 0d ) );
+ , typeof( RangeSlider ), new PropertyMetadata( 0d ) );
public static readonly DependencyProperty LowerRangeWidthProperty = LowerRangeWidthPropertyKey.DependencyProperty;
@@ -319,7 +301,7 @@ namespace Xceed.Wpf.Toolkit
/// LowerValue property represents the lower value within the selected range.
///
public static readonly DependencyProperty LowerValueProperty = DependencyProperty.Register( "LowerValue", typeof( double ), typeof( RangeSlider )
- , new FrameworkPropertyMetadata( RangeSlider.OnLowerValueChanged, RangeSlider.CoerceLowerValue ) );
+ , new FrameworkPropertyMetadata( 0d, FrameworkPropertyMetadataOptions.BindsTwoWayByDefault, RangeSlider.OnLowerValueChanged ) );
public double LowerValue
{
@@ -333,19 +315,6 @@ namespace Xceed.Wpf.Toolkit
}
}
- private static object CoerceLowerValue( DependencyObject sender, object value )
- {
- RangeSlider rangeSlider = sender as RangeSlider;
- double newValue = ( double )value;
-
- if( ( rangeSlider.HigherValue == 0 ) && ( rangeSlider.LowerValue == 0 ) )
- newValue = Math.Max( rangeSlider.Minimum, Math.Min( rangeSlider.Maximum, newValue ) );
- else
- newValue = Math.Min( Math.Max( rangeSlider.Minimum, Math.Min( rangeSlider.Maximum, newValue ) ), rangeSlider.HigherValue );
-
- return newValue;
- }
-
private static void OnLowerValueChanged( DependencyObject sender, DependencyPropertyChangedEventArgs args )
{
RangeSlider rangeSlider = sender as RangeSlider;
@@ -357,9 +326,7 @@ namespace Xceed.Wpf.Toolkit
protected virtual void OnLowerValueChanged( double oldValue, double newValue )
{
- this.HigherValue = Math.Max( this.HigherValue, newValue );
-
- this.AdjustWidths( this.Minimum, this.Maximum, newValue, this.HigherValue );
+ this.AdjustView();
RoutedEventArgs args = new RoutedEventArgs();
args.RoutedEvent = RangeSlider.LowerValueChangedEvent;
@@ -374,7 +341,7 @@ namespace Xceed.Wpf.Toolkit
/// Maximum property represents the maximum value, which can be selected, in a range.
///
public static readonly DependencyProperty MaximumProperty = DependencyProperty.Register( "Maximum", typeof( double ), typeof( RangeSlider )
- , new FrameworkPropertyMetadata( RangeSlider.OnMaximumChanged, RangeSlider.CoerceMaximum ) );
+ , new FrameworkPropertyMetadata( RangeSlider.OnMaximumChanged ) );
public double Maximum
{
@@ -388,14 +355,6 @@ namespace Xceed.Wpf.Toolkit
}
}
- private static object CoerceMaximum( DependencyObject sender, object value )
- {
- RangeSlider rangeSlider = sender as RangeSlider;
- double newValue = ( double )value;
-
- return Math.Max( newValue, rangeSlider.HigherValue );
- }
-
private static void OnMaximumChanged( DependencyObject sender, DependencyPropertyChangedEventArgs args )
{
RangeSlider rangeSlider = sender as RangeSlider;
@@ -407,7 +366,7 @@ namespace Xceed.Wpf.Toolkit
protected virtual void OnMaximumChanged( double oldValue, double newValue )
{
- this.AdjustWidths( this.Minimum, newValue, this.LowerValue, this.HigherValue );
+ this.AdjustView();
}
#endregion Maximum
@@ -418,7 +377,7 @@ namespace Xceed.Wpf.Toolkit
/// Minimum property represents the minimum value, which can be selected, in a range.
///
public static readonly DependencyProperty MinimumProperty = DependencyProperty.Register( "Minimum", typeof( double ), typeof( RangeSlider )
- , new FrameworkPropertyMetadata( RangeSlider.OnMinimumChanged, RangeSlider.CoerceMinimum ) );
+ , new FrameworkPropertyMetadata( RangeSlider.OnMinimumChanged ) );
public double Minimum
{
@@ -432,23 +391,6 @@ namespace Xceed.Wpf.Toolkit
}
}
- private static object CoerceMinimum( DependencyObject sender, object value )
- {
- RangeSlider rangeSlider = sender as RangeSlider;
- double newValue = ( double )value;
-
- if( ( rangeSlider.Minimum == 0.0 ) && ( rangeSlider.LowerValue == 0 ) && ( rangeSlider.HigherValue == 0 ) && ( rangeSlider.Maximum == 0 ) )
- {
- newValue = Math.Max( newValue, rangeSlider.LowerValue );
- }
- else
- {
- newValue = Math.Min( newValue, rangeSlider.LowerValue );
- }
-
- return newValue;
- }
-
private static void OnMinimumChanged( DependencyObject sender, DependencyPropertyChangedEventArgs args )
{
RangeSlider rangeSlider = sender as RangeSlider;
@@ -461,7 +403,7 @@ namespace Xceed.Wpf.Toolkit
protected virtual void OnMinimumChanged( double oldValue, double newValue )
{
// adjust the range width
- this.AdjustWidths( newValue, this.Maximum, this.LowerValue, this.HigherValue );
+ this.AdjustView();
}
#endregion Minimum
@@ -472,14 +414,14 @@ namespace Xceed.Wpf.Toolkit
/// # TODODOC
/// Get/Set the RangeSlider orientation.
///
- public static readonly DependencyProperty OrientationProperty = DependencyProperty.Register( "Orientation", typeof( OrientationEnum ), typeof( RangeSlider ),
- new FrameworkPropertyMetadata( OrientationEnum.Horizontal, RangeSlider.OnOrientationChanged ) );
+ public static readonly DependencyProperty OrientationProperty = DependencyProperty.Register( "Orientation", typeof( Orientation ), typeof( RangeSlider ),
+ new FrameworkPropertyMetadata( Orientation.Horizontal, RangeSlider.OnOrientationChanged ) );
- public OrientationEnum Orientation
+ public Orientation Orientation
{
get
{
- return ( OrientationEnum )GetValue( RangeSlider.OrientationProperty );
+ return ( Orientation )GetValue( RangeSlider.OrientationProperty );
}
set
{
@@ -492,11 +434,11 @@ namespace Xceed.Wpf.Toolkit
RangeSlider rangeSlider = sender as RangeSlider;
if( rangeSlider != null )
{
- rangeSlider.OnOrientationChanged( ( OrientationEnum )e.OldValue, ( OrientationEnum )e.NewValue );
+ rangeSlider.OnOrientationChanged( ( Orientation )e.OldValue, ( Orientation )e.NewValue );
}
}
- protected virtual void OnOrientationChanged( OrientationEnum oldValue, OrientationEnum newValue )
+ protected virtual void OnOrientationChanged( Orientation oldValue, Orientation newValue )
{
}
@@ -635,21 +577,25 @@ namespace Xceed.Wpf.Toolkit
if( _lowerSlider != null )
{
_lowerSlider.Loaded -= this.Slider_Loaded;
+ _lowerSlider.ValueChanged -= LowerSlider_ValueChanged;
}
_lowerSlider = this.Template.FindName( PART_LowerSlider, this ) as Slider;
if( _lowerSlider != null )
{
_lowerSlider.Loaded += this.Slider_Loaded;
+ _lowerSlider.ValueChanged += LowerSlider_ValueChanged;
}
if( _higherSlider != null )
{
- _higherSlider.Loaded -= this.Slider_Loaded;
+ _higherSlider.Loaded -= this.Slider_Loaded;
+ _higherSlider.ValueChanged -= HigherSlider_ValueChanged;
}
_higherSlider = this.Template.FindName( PART_HigherSlider, this ) as Slider;
if( _higherSlider != null )
{
- _higherSlider.Loaded += this.Slider_Loaded;
+ _higherSlider.Loaded += this.Slider_Loaded;
+ _higherSlider.ValueChanged += HigherSlider_ValueChanged;
}
}
@@ -690,19 +636,22 @@ namespace Xceed.Wpf.Toolkit
return 0d;
}
- private void AdjustWidths( double minimum, double maximum, double lowerValue, double higherValue )
+ private void AdjustView()
{
+ //Coerce values to make them consistent.
+ CoercedValues cv = this.GetCoercedValues();
+
double actualWidth = 0;
double lowerSliderThumbWidth = 0d;
double higherSliderThumbWidth = 0d;
- if( this.Orientation == OrientationEnum.Horizontal )
+ if( this.Orientation == Orientation.Horizontal )
{
actualWidth = this.ActualWidth;
lowerSliderThumbWidth = RangeSlider.GetThumbWidth( _lowerSlider );
higherSliderThumbWidth = RangeSlider.GetThumbWidth( _higherSlider );
}
- else if( this.Orientation == OrientationEnum.Vertical )
+ else if( this.Orientation == Orientation.Vertical )
{
actualWidth = this.ActualHeight;
lowerSliderThumbWidth = RangeSlider.GetThumbHeight( _lowerSlider );
@@ -711,20 +660,34 @@ namespace Xceed.Wpf.Toolkit
actualWidth -= ( lowerSliderThumbWidth + higherSliderThumbWidth );
- double entireRange = maximum - minimum;
+ this.SetLowerSliderValues( cv.LowerValue, cv.Minimum, cv.Maximum );
+ this.SetHigherSliderValues( cv.HigherValue, cv.Minimum, cv.Maximum );
+
+ double entireRange = cv.Maximum - cv.Minimum;
+
+ if( entireRange > 0 )
+ {
+ this.HigherRangeWidth = ( actualWidth * ( cv.Maximum - cv.HigherValue ) ) / entireRange;
+
+ this.RangeWidth = ( actualWidth * ( cv.HigherValue - cv.LowerValue ) ) / entireRange;
- this.HigherRangeWidth = ( actualWidth * ( maximum - higherValue ) ) / entireRange;
+ this.LowerRangeWidth = ( actualWidth * ( cv.LowerValue - cv.Minimum ) ) / entireRange;
+ }
+ else
+ {
+ this.HigherRangeWidth = 0d;
+ this.RangeWidth = 0d;
+ this.LowerRangeWidth = actualWidth;
+ }
- this.RangeWidth = ( actualWidth * ( higherValue - lowerValue ) ) / entireRange;
- this.LowerRangeWidth = ( actualWidth * ( lowerValue - minimum ) ) / entireRange;
}
private void SetSlidersMargins()
{
if( ( _lowerSlider != null ) && ( _higherSlider != null ) )
{
- if( this.Orientation == OrientationEnum.Horizontal )
+ if( this.Orientation == Orientation.Horizontal )
{
double lowerSliderThumbWidth = RangeSlider.GetThumbWidth( _lowerSlider );
double higherSliderThumbWidth = RangeSlider.GetThumbWidth( _higherSlider );
@@ -743,6 +706,53 @@ namespace Xceed.Wpf.Toolkit
}
}
+ private CoercedValues GetCoercedValues()
+ {
+ CoercedValues cv = new CoercedValues();
+ cv.Minimum = Math.Min( this.Minimum, this.Maximum );
+ cv.Maximum = Math.Max( cv.Minimum, this.Maximum );
+ cv.LowerValue = Math.Max( cv.Minimum, Math.Min( cv.Maximum, this.LowerValue ) );
+ cv.HigherValue = Math.Max( cv.Minimum, Math.Min( cv.Maximum, this.HigherValue ) );
+ cv.HigherValue = Math.Max( cv.LowerValue, cv.HigherValue );
+
+ return cv;
+ }
+
+ private void SetLowerSliderValues( double value, double? minimum, double? maximum )
+ {
+ this.SetSliderValues( _lowerSlider, this.LowerSlider_ValueChanged, value, minimum, maximum );
+ }
+
+ private void SetHigherSliderValues( double value, double? minimum, double? maximum )
+ {
+ this.SetSliderValues( _higherSlider, this.HigherSlider_ValueChanged, value, minimum, maximum );
+ }
+
+ private void SetSliderValues(
+ Slider slider,
+ RoutedPropertyChangedEventHandler handler,
+ double value,
+ double? minimum,
+ double? maximum )
+ {
+ if( slider != null )
+ {
+ slider.ValueChanged -= handler;
+
+ slider.Value = value;
+ if( minimum != null )
+ {
+ slider.Minimum = minimum.Value;
+ }
+ if( maximum != null )
+ {
+ slider.Maximum = maximum.Value;
+ }
+
+ slider.ValueChanged += handler;
+ }
+ }
+
#endregion
#region Events
@@ -779,25 +789,73 @@ namespace Xceed.Wpf.Toolkit
private void LowerRange_Click(object sender, RoutedEventArgs e)
{
- this.LowerValue -= this.Step;
+ CoercedValues cv = this.GetCoercedValues();
+ //When Maximum is not greater than Minimum, the
+ //slider display is in an inconsistant state. Don't
+ //consider any operation from the user
+ if( cv.Minimum < cv.Maximum )
+ {
+ double newValue = cv.LowerValue - this.Step;
+ this.LowerValue = Math.Min( cv.Maximum, Math.Max( cv.Minimum, newValue ) );
+ }
}
private void HigherRange_Click(object sender, RoutedEventArgs e)
{
- this.HigherValue += this.Step;
+ CoercedValues cv = this.GetCoercedValues();
+ //When Maximum is not greater than Minimum, the
+ //slider display is in an inconsistant state. Don't
+ //consider any operation from the user
+ if( cv.Minimum < cv.Maximum )
+ {
+ double newValue = cv.HigherValue + this.Step;
+ this.HigherValue = Math.Min( cv.Maximum, Math.Max( cv.Minimum, newValue ) );
+ }
}
private void RangeSlider_SizeChanged( object sender, SizeChangedEventArgs e )
{
- this.AdjustWidths( this.Minimum, this.Maximum, this.LowerValue, this.HigherValue );
+ this.AdjustView();
}
private void Slider_Loaded( object sender, RoutedEventArgs e )
{
this.SetSlidersMargins();
- this.AdjustWidths( this.Minimum, this.Maximum, this.LowerValue, this.HigherValue );
+ this.AdjustView();
+ }
+
+ private void LowerSlider_ValueChanged( object sender, RoutedPropertyChangedEventArgs e )
+ {
+ if( _lowerSlider.IsLoaded )
+ {
+ CoercedValues cv = this.GetCoercedValues();
+ double newValue = Math.Max( cv.Minimum, Math.Min( cv.Maximum, e.NewValue ) );
+ newValue = Math.Min( newValue, cv.HigherValue );
+ this.SetLowerSliderValues( newValue, null, null );
+ this.LowerValue = newValue;
+ }
+ }
+
+ private void HigherSlider_ValueChanged( object sender, RoutedPropertyChangedEventArgs e )
+ {
+ if( _higherSlider.IsLoaded )
+ {
+ CoercedValues cv = this.GetCoercedValues();
+ double newValue = Math.Max( cv.Minimum, Math.Min( cv.Maximum, e.NewValue ) );
+ newValue = Math.Max( newValue, cv.LowerValue );
+ this.SetHigherSliderValues( newValue, null, null );
+ this.HigherValue = newValue;
+ }
}
#endregion Events Handlers
+
+ private struct CoercedValues
+ {
+ public double Minimum;
+ public double Maximum;
+ public double LowerValue;
+ public double HigherValue;
+ }
}
}
diff --git a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Themes/Aero2.NormalColor.xaml b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Themes/Aero2.NormalColor.xaml
index 499c266c..2776dfc9 100644
--- a/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Themes/Aero2.NormalColor.xaml
+++ b/ExtendedWPFToolkitSolution_35/Src/Xceed.Wpf.Toolkit/RangeSlider/Themes/Aero2.NormalColor.xaml
@@ -22,30 +22,46 @@
xmlns:conv="clr-namespace:Xceed.Wpf.Toolkit.Converters"
xmlns:coreConv="clr-namespace:Xceed.Wpf.Toolkit.Core.Converters">
-
+
+
+
+
+
+
-
-
-
-
-
-
@@ -107,451 +121,192 @@
TargetName="MainBorder"
Value="#FFF0F0F0" />
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
-
-
-
-
-
-
-
-
+
-
-
-
+
+
+
+
+
+
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
-
+
-
-
-
-
+
+
+
+
+
+
+
-
@@ -230,7 +173,7 @@
-
@@ -259,412 +202,167 @@
-
+
-
-
-
-
-
-
-
-
-
-
+
-
+
-
-
-
+
+
+
+
+
+
+
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-