Skip to content

Commit

Permalink
Merge pull request #2 from SyncfusionExamples/851507_UpdateReadme
Browse files Browse the repository at this point in the history
851507_Update readme file
  • Loading branch information
naveenkumar-sanjeevirayan authored Oct 6, 2023
2 parents 9ce8185 + b02584a commit 5926654
Showing 1 changed file with 137 additions and 2 deletions.
139 changes: 137 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,141 @@
# How to customize size of close button in Xamarin.Forms chip group

[Xamarin.Forms Chips](https://help.syncfusion.com/xamarin/chips/getting-started) allow users to display the information in token representation. These chips arranged manner named ChipGroup. Default mode of [ChipGroup](https://www.syncfusion.com/xamarin-ui-controls/xamarin-chips) is [Input](https://help.syncfusion.com/xamarin/chips/types#input) type and its default size has been customized as per in below
The chip control supports to customize the background color, border color, close button color, and more. The chip control can be customized using the following properties:

![](https://github.com/SyncfusionExamples/How-to-customize-size-of-close-button-in-Xamarin.Forms-chip-group/blob/main/Close-Button-Customization.gif)
# ShowCloseButton

The [ShowCloseButton](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfChip.html#Syncfusion_XForms_Buttons_SfChip_ShowCloseButton) property sets the visible state of close button in [SfChip](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfChip.html).

**[XAML]**

```
<ContentPage.Content>
<StackLayout Margin="8,8,8,8" >
<buttons:SfChip Text="James"
WidthRequest="150"
HorizontalOptions="Center"
VerticalOptions="Center"
ShowCloseButton="true" >
</buttons:SfChip>
</StackLayout>
</ContentPage.Content>
```

**[C#]**

```
SfChip chip = new SfChip();
chip.Text = "James";
chip.WidthRequest = 150;
chip.HorizontalOptions = LayoutOptions.Center;
chip.VerticalOptions = LayoutOptions.Center;
chip.ShowCloseButton = true;
```
# ShowSelectionIndicator

The [ShowCloseButton](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfChip.html#Syncfusion_XForms_Buttons_SfChip_ShowSelectionIndicator
) property sets the visible state of close button in [SfChip](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfChip.html).

**[XAML]**
```
<buttons:SfChip Text="James"
WidthRequest="150"
HorizontalOptions="Center"
VerticalOptions="Center"
ShowCloseButton="true"
ShowSelectionIndicator="true"
>
</buttons:SfChip>
```
**[C#]**

```
SfChip chip = new SfChip();
chip.Text = "James";
chip.WidthRequest = 150;
chip.HorizontalOptions = LayoutOptions.Center;
chip.VerticalOptions = LayoutOptions.Center;
chip.ShowCloseButton = true;
chip.ShowSelectionIndicator = true;
```

# CloseButtonColor
The [CloseButtonColor](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfChip.html#Syncfusion_XForms_Buttons_SfChip_CloseButtonColor) property customizes the color of the close button in [SfChip](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfChip.html).

**[XAML]**

```
<buttons:SfChip Text="James"
WidthRequest="150"
HorizontalOptions="Center"
VerticalOptions="Center"
ShowCloseButton="true"
CloseButtonColor="White"
>
</buttons:SfChip>
```

**[C#]**

```
SfChip chip = new SfChip();
chip.Text = "James";
chip.ShowCloseButton = true;
chip.CloseButtonColor = Color.White;
```
# BorderColor
The [BorderColor](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfButton.html#Syncfusion_XForms_Buttons_SfButton_BorderColor) property customizes the color of border in [SfChip](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfChip.html).

**[XAML]**

```
<buttons:SfChip Text="James"
WidthRequest="150"
HorizontalOptions="Center"
VerticalOptions="Center"
BorderWidth="4"
BorderColor="Black"
>
</buttons:SfChip>
```

**[C#]**
```
SfChip chip = new SfChip();
chip.Text = "James";
chip.WidthRequest = 150;
chip.HorizontalOptions = LayoutOptions.Center;
chip.VerticalOptions = LayoutOptions.Center;
chip.BorderWidth = 4;
chip.BorderColor = Color.Black;
```
# BorderWidth
The [BorderWidth](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfButton.html#Syncfusion_XForms_Buttons_SfButton_BorderWidth) property customizes the thickness of border in [SfChip](https://help.syncfusion.com/cr/xamarin/Syncfusion.XForms.Buttons.SfChip.html).

**[XAML]**

```
<buttons:SfChip Text="James"
WidthRequest="150"
HorizontalOptions="Center"
VerticalOptions="Center"
BorderWidth="8"
BorderColor="Black"
>
</buttons:SfChip>
```

**[C#]**

```
SfChip chip = new SfChip();
chip.Text = "James";
chip.WidthRequest = 150;
chip.HorizontalOptions = LayoutOptions.Center;
chip.VerticalOptions = LayoutOptions.Center;
chip.BorderWidth = 8;
```

0 comments on commit 5926654

Please sign in to comment.