visualbruno
Topic Author
Posts: 2
Joined: 08 Jan 2014, 15:19

New to NoesisGUI (Unity) : Crash on simple xaml

31 Jan 2014, 16:24

Hi everyone.

I'm trying to display a very simple menu. But everytime I play the scene, it crashed with this message :

NullReferenceException: Object reference not set to an instance of an object
UnityEditor.DockArea.OnGUI () (at C:/BuildAgent/work/d3d49558e4d408f4/Editor/Mono/GUI/DockArea.cs:585)
System.Object:wrapper_native_28292B20(String, String)
NoesisGUISystem:Noesis_Init(String, String) (at Assets/Plugins/NoesisGUI/Scripts/Core/NoesisGUISystem.cs:393)
NoesisGUISystem:DoInit() (at Assets/Plugins/NoesisGUI/Scripts/Core/NoesisGUISystem.cs:167)
NoesisGUISystem:Init() (at Assets/Plugins/NoesisGUI/Scripts/Core/NoesisGUISystem.cs:124)
NoesisGUISystem:Awake() (at Assets/Plugins/NoesisGUI/Scripts/Core/NoesisGUISystem.cs:54)
UnityEngine.GameObject:AddComponent()
NoesisGUISystem:Create() (at Assets/Plugins/NoesisGUI/Scripts/Core/NoesisGUISystem.cs:23)
NoesisGUIPanel:OnEnable() (at Assets/Plugins/NoesisGUI/Scripts/NoesisGUIPanel.cs:62)

and this message :

Exception: Font Fill only available with solid paints
Noesis.Error.Check () (at Assets/Plugins/NoesisGUI/Scripts/Core/NoesisError.cs:51)
Noesis.UIRenderer.Noesis_UpdateRenderer (Int32 rendererId, Double timeInSeconds) (at Assets/Plugins/NoesisGUI/Scripts/Core/NoesisUIRendererImports.cs:139)
Noesis.UIRenderer.Update (Double timeInSeconds, AntialiasingMode aaMode, TessellationMode tessMode, TessellationQuality tessQuality, RendererFlags flags, Boolean enableMouse, Boolean enableTouch) (at Assets/Plugins/NoesisGUI/Scripts/Core/NoesisUIRenderer.cs:84)
NoesisGUIPanel.Update () (at Assets/Plugins/NoesisGUI/Scripts/NoesisGUIPanel.cs:97)

My xaml is very simple :
<Grid xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
      xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"
      xmlns:noesis="clr-namespace:Noesis">
  <Viewbox>
    <Border BorderBrush="Black" BorderThickness="2" CornerRadius="20" Height="337" Width="336.85">
	    <Border.Background>
		    <ImageBrush ImageSource="../../Skins/MenuSkin/WindowBackground.png"/>
	    </Border.Background>
	    <Border.Effect>
		    <DropShadowEffect/>
	    </Border.Effect>
	    <Grid x:Name="grdMain">
		    <Border VerticalAlignment="Top" Height="48" HorizontalAlignment="Stretch" Margin="50" CornerRadius="50" BorderBrush="Black" BorderThickness="1" Opacity="0.8">
			    <Border.Effect>
				    <DropShadowEffect/>
			    </Border.Effect>
			    <Border.Background>
				    <LinearGradientBrush EndPoint="0.5,1" MappingMode="RelativeToBoundingBox" StartPoint="0.5,0">
					    <GradientStop Color="White"/>
					    <GradientStop Color="White" Offset="1"/>
					    <GradientStop Color="#FF555555" Offset="0.388"/>
				    </LinearGradientBrush>
			    </Border.Background>
			    <Button x:Name="btnStart" Content="Start" FontSize="27" Margin="40,0" Background="Transparent" BorderBrush="Transparent">
				    <Button.Foreground>
					    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
						    <GradientStop Color="Black" Offset="0"/>
						    <GradientStop Color="#FFD81616" Offset="1"/>
					    </LinearGradientBrush>
				    </Button.Foreground>
			    </Button>
		    </Border>	
		    <Border VerticalAlignment="Top" Height="48" HorizontalAlignment="Stretch" Margin="50,140,50,0" CornerRadius="50" BorderBrush="Black" BorderThickness="1" Opacity="0.8">
			    <Border.Effect>
				    <DropShadowEffect/>
			    </Border.Effect>
			    <Border.Background>
				    <LinearGradientBrush EndPoint="0.5,1" MappingMode="RelativeToBoundingBox" StartPoint="0.5,0">
					    <GradientStop Color="White"/>
					    <GradientStop Color="White" Offset="1"/>
					    <GradientStop Color="#FF555555" Offset="0.388"/>
				    </LinearGradientBrush>
			    </Border.Background>
			    <Button x:Name="btnContinue" Content="Continue" FontSize="27" Margin="40,0" Background="Transparent" BorderBrush="Transparent">
				    <Button.Foreground>
					    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
						    <GradientStop Color="Black" Offset="0"/>
						    <GradientStop Color="#FFD81616" Offset="1"/>
					    </LinearGradientBrush>
				    </Button.Foreground>
			    </Button>
		    </Border>
		    <Border VerticalAlignment="Top" Height="48" HorizontalAlignment="Stretch" Margin="50,230,50,0" CornerRadius="50" BorderBrush="Black" BorderThickness="1" Opacity="0.8">
			    <Border.Effect>
				    <DropShadowEffect/>
			    </Border.Effect>
			    <Border.Background>
				    <LinearGradientBrush EndPoint="0.5,1" MappingMode="RelativeToBoundingBox" StartPoint="0.5,0">
					    <GradientStop Color="White"/>
					    <GradientStop Color="White" Offset="1"/>
					    <GradientStop Color="#FF555555" Offset="0.388"/>
				    </LinearGradientBrush>
			    </Border.Background>
			    <Button x:Name="btnSettings" Content="Settings" FontSize="27" Margin="40,0" Background="Transparent" BorderBrush="Transparent">
				    <Button.Foreground>
					    <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
						    <GradientStop Color="Black" Offset="0"/>
						    <GradientStop Color="#FFD81616" Offset="1"/>
					    </LinearGradientBrush>
				    </Button.Foreground>
			    </Button>
		    </Border>
	    </Grid>
    </Border>
  </Viewbox>
</Grid>
Any help will be appreciated.

Thanks
 
User avatar
jsantos
Site Admin
Posts: 3905
Joined: 20 Jan 2012, 17:18
Contact:

Re: New to NoesisGUI (Unity) : Crash on simple xaml

31 Jan 2014, 17:16

Hi!
Exception: Font Fill only available with solid paints
For now, we only support text rendering with solid colors. Gradients are yet not supported. If this is an important feature for you, we can prioritize it (not being a bug, features are only prioritized for customers).

The first error is a bug in Unity editor (solved in the last version?) that happens when you have active "Maximize on Play". You can safely ignore it.

Thanks!
 
visualbruno
Topic Author
Posts: 2
Joined: 08 Jan 2014, 15:19

Re: New to NoesisGUI (Unity) : Crash on simple xaml

01 Feb 2014, 12:38

Thanks for your answer. It's working now.

Who is online

Users browsing this forum: Bing [Bot] and 34 guests