TabView has empty space at start of Tabs. How to reduce/eliminate ?

In SFTabView on Win platform has empty space at the left of the Tabs. I have used HorizontalOptions , Margin etc., but wasn't able to reduce space and have Tab start at the left of Tab Sectio ? 


See screenshot

Image_3736_1724867853277

Image_2784_1724867870944


thanks


3 Replies 1 reply marked as answer

BV Brundha Velusamy Syncfusion Team August 29, 2024 08:13 AM UTC

Hi Praveen D,


Greetings from Syncfusion support!


If you want to customize the padding or remove the space from the left side of the TabHeader when SizeToContent is set as TabWidthMode, we suggest adjusting the TabHeaderPadding based on your needs. We have drafted a sample based on this approach and attached it for your reference. Please review the attached file and let us know if you need further details.


Here's the code snippet for your reference,

<Grid>

    <tabView:SfTabView TabWidthMode="SizeToContent" TabHeaderPadding="0">

        <tabView:SfTabItem Header="JAS Layout">

            <tabView:SfTabItem.Content>

                <Label Text="JAS Layout" VerticalOptions="Center" HorizontalOptions="Center"/>

            </tabView:SfTabItem.Content>

        </tabView:SfTabItem>

        <tabView:SfTabItem Header="More">

            <tabView:SfTabItem.Content>

                <Label Text="More" VerticalOptions="Center" HorizontalOptions="Center"/>

            </tabView:SfTabItem.Content>

        </tabView:SfTabItem>

    </tabView:SfTabView>

</Grid>


For more information, please refer to the help documentation provided in the link below:

Display Type in .NET MAUI Tab View (SfTabView) control | Syncfusion


Regards,

Brundha V


Attachment: TabView_61113926.zip

Marked as answer

PD Praveen D August 29, 2024 11:09 PM UTC

thank you that worked 



PR Preethi Rajakandham Syncfusion Team August 30, 2024 03:28 AM UTC

Hi Praveen,

You're welcome. 

We are glad that the provided response meets your requirement. Please let us know if you need further assistance. As always, we are happy to help you out. 

Regards,

Preethi R


Loader.
Up arrow icon