I've been trying to specify a dimension in pixels as a resource, so I can then use it in multiple places in my UI. e.g.
...
<ResourceDictionary
xmlns:System="clr-namespace:System;assembly=mscorlib">
<System:Double x:Key="a-width">140px</System:Double>
</ResourceDictionary
...
<TextBlock
Width="{StaticResource a-width}"
Text="this TextBlock is a-width wide"/>
...
However, this doesn't work. Although Width is of type 'double', you can't specify the value of a double using the 'px' suffix, as this format is supported by the LengthConverter, which is the TypeConverter for the FrameworkElement.Width property.
Is there a way to specify a width in 'Npx' format as a resource?