You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
sae201_qwirkle/Qwirkle/QwirkleViews/Views/TileCircle.xaml

29 lines
1.2 KiB

<?xml version="1.0" encoding="utf-8"?>
<ContentView xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="Qwirkle.Views.TileCircle"
xmlns:conv="clr-namespace:Qwirkle.Converters"
x:Name="root">
<ContentView.Resources>
<conv:Int2ColorConverter x:Key="int2ColorConverter"/>
</ContentView.Resources>
<Grid>
<Label Text="{Binding Shape, Source={x:Reference root}}"></Label>
<Rectangle HeightRequest="70"
Grid.Row="0"
Grid.Column="0"
WidthRequest="70"
VerticalOptions="Center"
HorizontalOptions="Center"
BackgroundColor="Transparent"/>
<Ellipse HeightRequest="50"
WidthRequest="50"
BackgroundColor="{Binding ColorPush, Source={x:Reference root}, Converter={StaticResource int2ColorConverter}}"
VerticalOptions="Center"
HorizontalOptions="Center"/>
<Label Text="{Binding ColorPush, Source={x:Reference root}}"></Label>
</Grid>
</ContentView>