Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

hjam40/Spinner.MAUI

Open more actions menu

Repository files navigation

Spinner.MAUI

A plugin for .NET MAUI providing a Spinner control.

For use the control after install de nuget package follow this steps:

XAML:

Add the namespace:

 xmlns:sc="clr-namespace:Spinner.MAUI;assembly=Spinner.MAUI"

Use it:

    <Border HorizontalOptions="Center" VerticalOptions="Center" Grid.Row="1" Margin="10" Background="white">
        <Grid>
            <Border VerticalOptions="Center" HeightRequest="30" Stroke="gray" Background="#EEEEEE" Margin="2,0,2,0" StrokeShape="RoundRectangle 10">
                <Label/>
            </Border>
            <HorizontalStackLayout VerticalOptions="Center" BindingContext="{x:Reference spn1}" HeightRequest="120">
                <sc:Spinner x:Name="spn1" BindingContext="{x:Reference mainpage}" Items="{Binding Hours}" SelectedItemIndex="{Binding Hour}" VerticalOptions="Center" WidthRequest="60" IsCyclic="True" SelectionBoxIsVisible="False" ItemStyle="{StaticResource Key=SpinnerTimeItemStyle}"/>
                <Label VerticalOptions="Center" Text=":" FontSize="25" FontAttributes="Bold" TextColor="Black"/>
                <sc:Spinner BindingContext="{x:Reference mainpage}" Items="{Binding Minutes}" SelectedItemIndex="{Binding Minute}" VerticalOptions="Center" WidthRequest="60" IsCyclic="True" SelectionBoxIsVisible="False" ItemStyle="{StaticResource Key=SpinnerTimeItemStyle}"/>
                <Label VerticalOptions="Center" Text=":" FontSize="25" FontAttributes="Bold" TextColor="Black"/>
                <sc:Spinner BindingContext="{x:Reference mainpage}" Items="{Binding Seconds}" SelectedItemIndex="{Binding Second}" VerticalOptions="Center" WidthRequest="60" IsCyclic="True" SelectionBoxIsVisible="False" ItemStyle="{StaticResource Key=SpinnerTimeItemStyle}"/>
            </HorizontalStackLayout>
        </Grid>
    </Border>

Code:

Add the using command:

using Spinner.MAUI;

Use it:

Spinner spinner=new Spinner { NumItemsToShow = 5, WidthRequest = 200 , HeightRequest = 150 };

About

A plugin for .NET MAUI providing a Spinner control to costume

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.