# .NET MAUI OptionsButton ToolbarItem

Use the `OptionsButtonToolbarItem` for displaying an options panel in the Toolbar control. The toolbar item has to be attached to the `RadToolbarOptionsPanel`.

```XAML
<telerik:OptionsButtonToolbarItem Text="Filters">
    <telerik:OptionsButtonToolbarItem.ImageSource>
        <FontImageSource Glyph="{x:Static telerik:TelerikFont.IconFilters}"
                         FontFamily="{x:Static telerik:TelerikFont.Name}"
                         Size="16" />
    </telerik:OptionsButtonToolbarItem.ImageSource>
    <telerik:OptionsButtonToolbarItem.OptionsContentTemplate>
        <ControlTemplate>
            <VerticalStackLayout Spacing="10"
                                 WidthRequest="200"
                                 Padding="20">
                <Label Text="Brightness" />
                <Slider />
                <Label Text="Contrast" />
                <Slider />
                <HorizontalStackLayout Spacing="10"
                                       HorizontalOptions="End">
                    <Button Text="OK" />
                    <Button Text="Cancel" />
                </HorizontalStackLayout>
            </VerticalStackLayout>
        </ControlTemplate>
    </telerik:OptionsButtonToolbarItem.OptionsContentTemplate>
</telerik:OptionsButtonToolbarItem>
```

And the `RadToolbarOptionsPanel` definition:

```XAML
<telerik:RadToolbarOptionsPanel x:Name="topPanel" />
```

* `OptionsPanel`(`Telerik.Maui.controls.RadToolbarOptionsPanel`)—Specifies the options panel associated with this toolbar item.
* `OptionsContentStyle`(`Telerik.Maui.controls.RadToolbarOptionsPanel`)—Specifies the style of the options content. The target type of this style is `Telerik.Maui.Controls.OptionsButtonToolbarItemViewContent`.
* `OptionsContentTemplate`(`Microsoft.Maui.Controls.ControlTemplate`)—Specifies the template of the options content. The target type of this template is `Telerik.Maui.Controls.OptionsButtonToolbarItemViewContent`.
* `Text`(`string`)—Defines the text(target type `Label`) in the toolbar item. You can display an image next to the text.
* `ImageSource`(`Microsoft.Maui.Controls.ImageSource`)—Specifies the source of the image to display in the toolbar item.

> note Use the properties available in the [DropDownButtonToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/dropdown-button) as the `OptionsButtonToolbarItem` inherits from it.

## Events

The exposed events are:

* `Clicked`—Raised when the button is clicked.

## Commands

The available commands are:

* `Command`(`ICommand`)—Specifies the command to execute when the button is clicked.
* `CommandParameter`(`object`)—Specifies the parameter of the command, which is executed when the button is clicked.

## Styling

Use the `Style` property with target type `OptionsButtonToolbarItemView`. The available properties that can be applied through Style are:

* `OptionsPanel`(`Telerik.Maui.controls.RadToolbarOptionsPanel`)—Specifies the options panel associated with this toolbar item.
* `OptionsContentStyle`(`Telerik.Maui.controls.RadToolbarOptionsPanel`)—Specifies the style of the options content. The target type of this style is `Telerik.Maui.Controls.OptionsButtonToolbarItemViewContent`.
* `OptionsContentTemplate`(`Microsoft.Maui.Controls.ControlTemplate`)—Specifies the template of the options content. The target type of this template is `Telerik.Maui.Controls.OptionsButtonToolbarItemViewContent`.

The other available properties are the properties used in the [DropDownButtonToolbarItemView](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/dropdown-button#styling), [ButtonToolbarItemView](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/button#styling), [ToolbarItemView](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/overview#styling) and [LabelToolbarItemView](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/label#styling).

## See Also

* [SplitButton ToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/split-button)
* [ToggleButton ToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/toggle-button)
* [Label ToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/label)
* [NavigationButton ToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/navigation-button)
* [ListPicker ToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/listpicker-button)
* [Group ToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/group)
* [RadioButton ToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/radio-button)
* [Slider ToolbarItem](https://www.telerik.com/maui-ui/documentation/controls/toolbar/items/slider)
