Browse Source

merged last minute bug fixes into branch.

import/raw
brianlagunas_cp 16 years ago
parent
commit
d800a280d1
  1. 2
      Release/v1.4.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Themes/Generic.xaml
  2. 14
      Release/v1.4.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/Core/Primitives/InputBase.cs
  3. 6
      Release/v1.4.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/DateTimeUpDown/Themes/Generic.xaml
  4. 10
      Release/v1.4.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/NumericUpDown/Themes/Generic.xaml
  5. 2
      Release/v1.4.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/CalculatorUpDown/Themes/Generic.xaml
  6. 2
      Release/v1.4.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/DateTimeUpDown/Themes/Generic.xaml
  7. 6
      Release/v1.4.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/NumericUpDown/Themes/Generic.xaml

2
Release/v1.4.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Themes/Generic.xaml

@ -64,6 +64,7 @@
<Setter Property="Focusable" Value="False" /> <Setter Property="Focusable" Value="False" />
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/> <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/>
<Setter Property="HorizontalContentAlignment" Value="Right" /> <Setter Property="HorizontalContentAlignment" Value="Right" />
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
<Setter Property="Template"> <Setter Property="Template">
<Setter.Value> <Setter.Value>
@ -87,6 +88,7 @@
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}" IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}"
MinWidth="20" AcceptsReturn="False" MinWidth="20" AcceptsReturn="False"
TextAlignment="{TemplateBinding TextAlignment}"
TextWrapping="NoWrap" TextWrapping="NoWrap"
TabIndex="{TemplateBinding TabIndex}" TabIndex="{TemplateBinding TabIndex}"
Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}" Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}"

14
Release/v1.4.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/Core/Primitives/InputBase.cs

@ -50,10 +50,22 @@ namespace Microsoft.Windows.Controls.Primitives
protected virtual void OnTextChanged(string oldValue, string newValue) protected virtual void OnTextChanged(string oldValue, string newValue)
{ {
} }
#endregion //Text #endregion //Text
#region TextAlignment
public static readonly DependencyProperty TextAlignmentProperty = DependencyProperty.Register("TextAlignment", typeof(TextAlignment), typeof(InputBase), new UIPropertyMetadata(TextAlignment.Left));
public TextAlignment TextAlignment
{
get { return (TextAlignment)GetValue(TextAlignmentProperty); }
set { SetValue(TextAlignmentProperty, value); }
}
#endregion //TextAlignment
#region Watermark #region Watermark
public static readonly DependencyProperty WatermarkProperty = DependencyProperty.Register("Watermark", typeof(object), typeof(InputBase), new UIPropertyMetadata(null)); public static readonly DependencyProperty WatermarkProperty = DependencyProperty.Register("Watermark", typeof(object), typeof(InputBase), new UIPropertyMetadata(null));

6
Release/v1.4.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/DateTimeUpDown/Themes/Generic.xaml

@ -8,7 +8,7 @@
<DataTemplate x:Key="DefaultWatermarkTemplate"> <DataTemplate x:Key="DefaultWatermarkTemplate">
<ContentControl Content="{Binding}" Foreground="Gray" Focusable="False" /> <ContentControl Content="{Binding}" Foreground="Gray" Focusable="False" />
</DataTemplate> </DataTemplate>
<!-- =============================================================================== --> <!-- =============================================================================== -->
<!-- DateTimeUpDown --> <!-- DateTimeUpDown -->
<!-- =============================================================================== --> <!-- =============================================================================== -->
@ -19,6 +19,7 @@
<Setter Property="Focusable" Value="False" /> <Setter Property="Focusable" Value="False" />
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/> <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/>
<Setter Property="HorizontalContentAlignment" Value="Right" /> <Setter Property="HorizontalContentAlignment" Value="Right" />
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
<Setter Property="Template"> <Setter Property="Template">
<Setter.Value> <Setter.Value>
@ -36,6 +37,7 @@
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}" IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}"
MinWidth="20" AcceptsReturn="False" MinWidth="20" AcceptsReturn="False"
TextAlignment="{TemplateBinding TextAlignment}"
TextWrapping="NoWrap" TextWrapping="NoWrap"
TabIndex="{TemplateBinding TabIndex}" TabIndex="{TemplateBinding TabIndex}"
Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}" Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}"
@ -46,5 +48,5 @@
</Setter.Value> </Setter.Value>
</Setter> </Setter>
</Style> </Style>
</ResourceDictionary> </ResourceDictionary>

10
Release/v1.4.0/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/NumericUpDown/Themes/Generic.xaml

@ -9,13 +9,13 @@
<DataTemplate x:Key="DefaultWatermarkTemplate"> <DataTemplate x:Key="DefaultWatermarkTemplate">
<ContentControl Content="{Binding}" Foreground="Gray" Focusable="False" /> <ContentControl Content="{Binding}" Foreground="Gray" Focusable="False" />
</DataTemplate> </DataTemplate>
<Style x:Key="NumericUpDown" TargetType="Control"> <Style x:Key="NumericUpDown" TargetType="Control">
<Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.WindowBrushKey}}"/> <Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.WindowBrushKey}}"/>
<Setter Property="BorderThickness" Value="1" /> <Setter Property="BorderThickness" Value="1" />
<Setter Property="Focusable" Value="False" /> <Setter Property="Focusable" Value="False" />
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/> <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/>
<Setter Property="HorizontalContentAlignment" Value="Right" /> <Setter Property="HorizontalContentAlignment" Value="Right" />
<Setter Property="Template"> <Setter Property="Template">
<Setter.Value> <Setter.Value>
<ControlTemplate TargetType="Control"> <ControlTemplate TargetType="Control">
@ -32,6 +32,7 @@
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}" IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}"
MinWidth="20" AcceptsReturn="False" MinWidth="20" AcceptsReturn="False"
TextAlignment="{Binding TextAlignment, RelativeSource={RelativeSource TemplatedParent}}"
TextWrapping="NoWrap" TextWrapping="NoWrap"
TabIndex="{TemplateBinding TabIndex}" TabIndex="{TemplateBinding TabIndex}"
Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}" Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}"
@ -48,6 +49,7 @@
<!-- =============================================================================== --> <!-- =============================================================================== -->
<Style TargetType="{x:Type local:DecimalUpDown}" BasedOn="{StaticResource NumericUpDown}"> <Style TargetType="{x:Type local:DecimalUpDown}" BasedOn="{StaticResource NumericUpDown}">
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
</Style> </Style>
@ -56,6 +58,7 @@
<!-- =============================================================================== --> <!-- =============================================================================== -->
<Style TargetType="{x:Type local:DoubleUpDown}" BasedOn="{StaticResource NumericUpDown}"> <Style TargetType="{x:Type local:DoubleUpDown}" BasedOn="{StaticResource NumericUpDown}">
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
</Style> </Style>
@ -64,7 +67,8 @@
<!-- =============================================================================== --> <!-- =============================================================================== -->
<Style TargetType="{x:Type local:IntegerUpDown}" BasedOn="{StaticResource NumericUpDown}"> <Style TargetType="{x:Type local:IntegerUpDown}" BasedOn="{StaticResource NumericUpDown}">
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
</Style> </Style>
</ResourceDictionary> </ResourceDictionary>

2
Release/v1.4.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/CalculatorUpDown/Themes/Generic.xaml

@ -64,6 +64,7 @@
<Setter Property="Focusable" Value="False" /> <Setter Property="Focusable" Value="False" />
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/> <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/>
<Setter Property="HorizontalContentAlignment" Value="Right" /> <Setter Property="HorizontalContentAlignment" Value="Right" />
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
<Setter Property="Template"> <Setter Property="Template">
<Setter.Value> <Setter.Value>
@ -87,6 +88,7 @@
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}" IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}"
MinWidth="20" AcceptsReturn="False" MinWidth="20" AcceptsReturn="False"
TextAlignment="{TemplateBinding TextAlignment}"
TextWrapping="NoWrap" TextWrapping="NoWrap"
TabIndex="{TemplateBinding TabIndex}" TabIndex="{TemplateBinding TabIndex}"
Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}" Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}"

2
Release/v1.4.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/DateTimeUpDown/Themes/Generic.xaml

@ -19,6 +19,7 @@
<Setter Property="Focusable" Value="False" /> <Setter Property="Focusable" Value="False" />
<Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/> <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}"/>
<Setter Property="HorizontalContentAlignment" Value="Right" /> <Setter Property="HorizontalContentAlignment" Value="Right" />
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
<Setter Property="Template"> <Setter Property="Template">
<Setter.Value> <Setter.Value>
@ -36,6 +37,7 @@
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}" IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}"
MinWidth="20" AcceptsReturn="False" MinWidth="20" AcceptsReturn="False"
TextAlignment="{TemplateBinding TextAlignment}"
TextWrapping="NoWrap" TextWrapping="NoWrap"
TabIndex="{TemplateBinding TabIndex}" TabIndex="{TemplateBinding TabIndex}"
Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}" Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}"

6
Release/v1.4.0/ExtendedWPFToolkitSolution_35/Src/WPFToolkit.Extended/NumericUpDown/Themes/Generic.xaml

@ -20,7 +20,7 @@
<Setter.Value> <Setter.Value>
<ControlTemplate TargetType="Control"> <ControlTemplate TargetType="Control">
<local:ButtonSpinner x:Name="Spinner" IsTabStop="False" Background="{TemplateBinding Background}" BorderThickness="{TemplateBinding BorderThickness}" <local:ButtonSpinner x:Name="Spinner" IsTabStop="False" Background="{TemplateBinding Background}" BorderThickness="{TemplateBinding BorderThickness}"
AllowSpin="{Binding AllowSpin, RelativeSource={RelativeSource TemplatedParent}}" ShowButtonSpinner="{Binding ShowButtonSpinner, RelativeSource={RelativeSource TemplatedParent}}" > AllowSpin="{Binding AllowSpin, RelativeSource={RelativeSource TemplatedParent}}" ShowButtonSpinner="{Binding ShowButtonSpinner, RelativeSource={RelativeSource TemplatedParent}}">
<local:WatermarkTextBox x:Name="TextBox" BorderThickness="0" <local:WatermarkTextBox x:Name="TextBox" BorderThickness="0"
Background="{TemplateBinding Background}" Background="{TemplateBinding Background}"
FontFamily="{TemplateBinding FontFamily}" FontFamily="{TemplateBinding FontFamily}"
@ -32,6 +32,7 @@
HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}"
IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}" IsReadOnly="{Binding IsEditable, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource InverseBoolConverter}}"
MinWidth="20" AcceptsReturn="False" MinWidth="20" AcceptsReturn="False"
TextAlignment="{Binding TextAlignment, RelativeSource={RelativeSource TemplatedParent}}"
TextWrapping="NoWrap" TextWrapping="NoWrap"
TabIndex="{TemplateBinding TabIndex}" TabIndex="{TemplateBinding TabIndex}"
Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}" Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}}"
@ -48,6 +49,7 @@
<!-- =============================================================================== --> <!-- =============================================================================== -->
<Style TargetType="{x:Type local:DecimalUpDown}" BasedOn="{StaticResource NumericUpDown}"> <Style TargetType="{x:Type local:DecimalUpDown}" BasedOn="{StaticResource NumericUpDown}">
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
</Style> </Style>
@ -56,6 +58,7 @@
<!-- =============================================================================== --> <!-- =============================================================================== -->
<Style TargetType="{x:Type local:DoubleUpDown}" BasedOn="{StaticResource NumericUpDown}"> <Style TargetType="{x:Type local:DoubleUpDown}" BasedOn="{StaticResource NumericUpDown}">
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
</Style> </Style>
@ -64,6 +67,7 @@
<!-- =============================================================================== --> <!-- =============================================================================== -->
<Style TargetType="{x:Type local:IntegerUpDown}" BasedOn="{StaticResource NumericUpDown}"> <Style TargetType="{x:Type local:IntegerUpDown}" BasedOn="{StaticResource NumericUpDown}">
<Setter Property="TextAlignment" Value="Right" />
<Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" /> <Setter Property="WatermarkTemplate" Value="{StaticResource DefaultWatermarkTemplate}" />
</Style> </Style>

Loading…
Cancel
Save