Tag: style

  • WPF ToolTip Drop Shadows in Windows 8

    The standard ToolTip control template for the Windows 8 theme in WPF (‘Aero2’) has no drop shadow, whether or not the HasDropShadow property is set. The background colour and margins are also slightly off compared to the native style. The following template produces a result that’s closer to the real thing: <Style TargetType="{x:Type ToolTip}"> <Setter…

  • WPF: Using System Colours in Animations

    WPF provides access to the Windows system colours through the System.Windows.SystemColors class. As the MSDN documentation indicates, it’s possible to bind to these colours dynamically using the *Key resources, so when the system colours change, so will the appearance of your application. This code will set the colour of a TextBlock to the ‘GrayText’ system…