Shell Tab layout

RogerSchmidlinRogerSchmidlin CHUniversity ✭✭✭

I am using Shell with a flyout. I would like to have my own tab template. Is that possible? I tried Shell.ItemTemplate but that only has an impact on the flyout itself not the tabs. In particular, I would like to specify the dimensions of my icons in the tabs.

Tagged:

Best Answer

Answers

  • LeonLuLeonLu Member, Xamarin Team Xamurai

    Do you want to adjust your image size like following screenshot?

    You could adjust the icons by the setting HeightRequest="" and WidthRequest="" like following code.

     <Shell.ItemTemplate>
        <DataTemplate>
            <Grid>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="*" />
                    <ColumnDefinition Width="*" />
                </Grid.ColumnDefinitions>
                <Image Source="{Binding Icon}"
                       Margin="5"
                       HeightRequest="80" WidthRequest="30" />
                <Label Grid.Column="1"
                       Text="{Binding Title}"
                       FontAttributes="Italic"
                       VerticalTextAlignment="Center" />
            </Grid>
        </DataTemplate>
    </Shell.ItemTemplate>
    

    If not, can you provide a screenshot about what do you want to achieve?

  • RogerSchmidlinRogerSchmidlin CHUniversity ✭✭✭

    I am talking about formatting the bottom tab bars when the flyout is closed

  • RogerSchmidlinRogerSchmidlin CHUniversity ✭✭✭

    I thought that would be possible out of the box. All control supplier do it this way, like SyncFusion. If Xamarin comes out with this new thing called Shell, I would expect it to have a itemtemplete I could supply. But thanks for your suggestion.

  • LeonLuLeonLu Member, Xamarin Team Xamurai

    @RogerSchmidlin You are welcome, If the reply is helpful, please mark it as an answer, it will help others who have similar issue.

Sign In or Register to comment.