The below code will work:
<Panel ux:Class="MyButton" ux:Name="self">
<float4 ux:Property="FSize" ux:Value="20" />
<float4 ux:Property="TColor" ux:Value="#f00" />
<string ux:Property="Txt" ux:Value="PageButton" />
<Text Alignment="Center" TextColor="{Property self.TColor}" Value="{Property self.Txt}" />
</Panel>
<MyButton Txt="Test" TColor="#ffcc00" FSize="20" Dock="Top" />
However if you reference ux:Property="FSize"
inside the <Text>
element fuze preview will fail to render and crash.
<Panel ux:Class="MyButton" ux:Name="self">
<float4 ux:Property="FSize" ux:Value="20" />
<float4 ux:Property="TColor" ux:Value="#f00" />
<string ux:Property="Txt" ux:Value="PageButton" />
<Text Alignment="Center" TextColor="{Property self.TColor}" Value="{Property self.Txt}" FontSize="{Property self.FSize}" />
</Panel>
<MyButton Txt="Test" TColor="#ffcc00" FSize="20" Dock="Top" />
Below is the error outputted: