Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

Can I force a button to fit it's container ?

$
0
0

I tried everything I could think of to make these buttons use the full space available to them.
Here is the XAML:

            <DataTemplate>
                <ViewCell>
                    <Grid Padding="0" Margin="0" BackgroundColor="Blue" RowSpacing="0">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="8*"/>
                            <ColumnDefinition Width="3*"/>
                        </Grid.ColumnDefinitions>
                        <StackLayout Grid.Column="0" Padding="8,0,8,0" Spacing="5" BackgroundColor="Red">
                            <Label Text="{Binding Display}" LineBreakMode="TailTruncation"/>
                            <Label Text="{Binding DurationDT}"/>
                        </StackLayout>
                        <Button Text="Convertir"  FontSize="Micro"
                                Margin="0"
                                BorderRadius="0"
                                VerticalOptions="CenterAndExpand" HorizontalOptions="CenterAndExpand"
                                BackgroundColor="LimeGreen" Grid.Column="1"/>
                    </Grid>
                </ViewCell>
            </DataTemplate>

Imo the buttons should completely fill the Blue spaces and have no border radius.
But it's clearly not the case.

Can anyone tell me why, and how to fix it ? Thanks


Viewing all articles
Browse latest Browse all 204402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>