-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Closed
Milestone
Description
It would be cool if the option in TextBoxHelper.UseFloatingWatermark worked on DatePicker. Any way to make it work in case you don't plan to make it a functionality?
As a temporary workaround I created a simple style to achieve what I'd like:
<Style TargetType="{x:Type DatePickerTextBox}"
BasedOn="{StaticResource {x:Type DatePickerTextBox}}">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate>
<TextBox Controls:TextBoxHelper.Watermark="{Binding Path=(Controls:TextBoxHelper.Watermark),RelativeSource={RelativeSource TemplatedParent}}"
Controls:TextBoxHelper.UseFloatingWatermark="True"
VerticalContentAlignment="Center"
Text="{Binding Text, RelativeSource={RelativeSource TemplatedParent}, Mode=TwoWay}"
BorderThickness="0"
Padding="0" />
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
Metadata
Metadata
Assignees
Labels
No labels