[Unity] Ignoring unknown type 'mscorlib.Double'
I have a resource dictionary that defines some default values for widths, radiuses, fontsizes, etc. I've defined these as follows:
In the root element I've declared the System namespace as follows:
Now, noesis gives me the compiler warning "Ignoring unknown type 'mscorlib.Double'.
What am I doing wrong? Do I have to reference a different assembly in the namespace declaration?
Code: Select all
<System:Double x:Key="MessageCornderRadius">6</System:Double>
<System:Double x:Key="MessageWidth">400</System:Double>
<System:Double x:Key="MessageFontSize">16</System:Double>
<System:Double x:Key="LargeFontSize">20</System:Double>
Code: Select all
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:System="clr-namespace:System;assembly=mscorlib"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
What am I doing wrong? Do I have to reference a different assembly in the namespace declaration?
Last edited by Basp on 07 Aug 2014, 09:00, edited 1 time in total.
Re: Ignoring unknown type 'mscorlib.Double'
Noesis binds Singles not doubles.
Re: Ignoring unknown type 'mscorlib.Double'
If I make them singles, I just get "Ignoring unknown type 'mscorlib.Single'. Also then Blend and Visual Studio complain that you can't apply an object of the type Single to a property that expects the type Double.
-
sfernandez
Site Admin
- Posts: 3184
- Joined:
Re: [Unity] Ignoring unknown type 'mscorlib.Double'
Hi,
The problem is not using Singles instead of Doubles. The problem is that our parser does not have support for this System type (only Boolean and String are correctly parsed by now).
We will add Double (and other numeric types) in the following release. Sorry for the inconvenience.
The problem is not using Singles instead of Doubles. The problem is that our parser does not have support for this System type (only Boolean and String are correctly parsed by now).
We will add Double (and other numeric types) in the following release. Sorry for the inconvenience.
Re: [Unity] Ignoring unknown type 'mscorlib.Double'
Thanks, then I know I can stop looking for a way to get this to work. I can make do with a workaround for now. Thanks for the information!
-
sfernandez
Site Admin
- Posts: 3184
- Joined:
Re: [Unity] Ignoring unknown type 'mscorlib.Double'
Maybe you can define some Styles to set these default values.
Who is online
Users browsing this forum: No registered users and 1 guest