|
16 | 16 | <Setter Property="Background" Value="Transparent"/>
|
17 | 17 | <Setter Property="CaretBrush" Value="{Binding RelativeSource={RelativeSource Self}, Path=BorderBrush}"/>
|
18 | 18 | <Setter Property="KeyboardNavigation.TabNavigation" Value="None"/>
|
19 |
| - <Setter Property="HorizontalContentAlignment" Value="Left"/> |
20 |
| - <Setter Property="VerticalContentAlignment" Value="Center"/> |
| 19 | + <Setter Property="HorizontalContentAlignment" Value="Stretch"/> |
| 20 | + <Setter Property="VerticalContentAlignment" Value="Stretch"/> |
21 | 21 | <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
|
22 | 22 | <Setter Property="AllowDrop" Value="true"/>
|
23 | 23 | <Setter Property="ScrollViewer.PanningMode" Value="VerticalFirst"/>
|
|
27 | 27 | <Setter Property="Template">
|
28 | 28 | <Setter.Value>
|
29 | 29 | <ControlTemplate TargetType="{x:Type PasswordBox}">
|
30 |
| - <Grid VerticalAlignment="{TemplateBinding VerticalContentAlignment}"> |
| 30 | + <Grid> |
31 | 31 | <Border x:Name="border"
|
32 | 32 | BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"
|
33 | 33 | Background="{TemplateBinding Background}"
|
34 | 34 | SnapsToDevicePixels="True"
|
35 |
| - Padding="0 4 0 4" VerticalAlignment="Center"> |
36 |
| - <Grid Margin="{TemplateBinding Padding}"> |
37 |
| - <ScrollViewer x:Name="PART_ContentHost" |
38 |
| - Focusable="false" |
39 |
| - HorizontalScrollBarVisibility="Hidden" VerticalScrollBarVisibility="Hidden" |
40 |
| - TextElement.FontFamily="Times New Roman" /> |
| 35 | + Padding="0 4 0 4"> |
| 36 | + <Grid Margin="{TemplateBinding Padding}" |
| 37 | + HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
| 38 | + VerticalAlignment="{TemplateBinding VerticalContentAlignment}"> |
| 39 | + <ScrollViewer x:Name="PART_ContentHost" Focusable="false" HorizontalScrollBarVisibility="Hidden" VerticalScrollBarVisibility="Hidden" |
| 40 | + /> |
41 | 41 | <TextBlock Text="{Binding Path=(wpf:TextFieldAssist.Hint), RelativeSource={RelativeSource TemplatedParent}}"
|
42 |
| - Visibility="{Binding Path=(wpf:PasswordFieldAssist.HintVisibility), RelativeSource={RelativeSource TemplatedParent}, Mode=OneWay}" |
43 |
| - Margin="1 0 1 0" |
| 42 | + Visibility="{Binding Path=(wpf:PasswordFieldAssist.HintVisibility), RelativeSource={RelativeSource TemplatedParent}, Mode=OneWay}" |
44 | 43 | IsHitTestVisible="False"
|
45 |
| - x:Name="Hint" |
46 |
| - Opacity="{Binding Path=(wpf:TextFieldAssist.HintOpacity), RelativeSource={RelativeSource TemplatedParent}}" /> |
| 44 | + x:Name="Hint" |
| 45 | + Margin="1 0 1 0" |
| 46 | + Opacity="{Binding Path=(wpf:TextFieldAssist.HintOpacity), RelativeSource={RelativeSource TemplatedParent}}" /> |
47 | 47 | </Grid>
|
48 | 48 | </Border>
|
49 | 49 | <wpf:Underline x:Name="Underline"/>
|
|
0 commit comments