ScrollableSegmentedControl 1.0.8715

dotnet add package ScrollableSegmentedControl --version 1.0.8715
                    
NuGet\Install-Package ScrollableSegmentedControl -Version 1.0.8715
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ScrollableSegmentedControl" Version="1.0.8715" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ScrollableSegmentedControl" Version="1.0.8715" />
                    
Directory.Packages.props
<PackageReference Include="ScrollableSegmentedControl" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add ScrollableSegmentedControl --version 1.0.8715
                    
#r "nuget: ScrollableSegmentedControl, 1.0.8715"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#addin nuget:?package=ScrollableSegmentedControl&version=1.0.8715
                    
Install ScrollableSegmentedControl as a Cake Addin
#tool nuget:?package=ScrollableSegmentedControl&version=1.0.8715
                    
Install ScrollableSegmentedControl as a Cake Tool

ScrollableSegmentedControl

A drop-in replacement for UISegmentedControl mimicking the style of the segmented control used in Google Currents and various other Google products.

A C# port for Xamarin.iOS of HMSegmentedControl written by Hesham Abd-Elmegid (https://github.com/HeshamMegid/HMSegmentedControl).

Screenshot

ScrollableSegmentedControl

Usages

The easiest way to get started with using this is by installing the ScrollableSegmentedControl NuGet package to your Xamarin.iOS project

Here's an example of how to create the ScrollableSegmentedControl

private void CreateScrollableSegmentedControl()
{
    var sectionTitles = new[] { "One", "Two", "Three", "Four", "Five", "Six" };
    var segmentedControl = new ScrollableSegmentedControl(sectionTitles)
    {
        Font = UIFont.FromName("STHeitiSC-Light", 18.0f),
        Frame = new CGRect(0, 60, View.Frame.Width, 40),
        SegmentEdgeInset = new UIEdgeInsets(0, 10, 0, 10),
        SelectionStyle = ScrollableSegmentedControlSelectionStyle.FullWidthStripe,
        SelectionIndicatorLocation = ScrollableSegmentedControlIndicatorLocation.Down
    };
    View.AddSubview(segmentedControl);
}

Selection Indicator Position

enum ScrollableSegmentedControlIndicatorLocation
{
    Up,
    Down,
    None
}

Selection Style

enum ScrollableSegmentedControlSelectionStyle
{
    TextWidthStripe,
    FullWidthStripe,
    Box,
    Arrow
}

Segment Width Styles

enum ScrollableSegmentedControlWidthStyle
{
    Fixed,
    Dynamic
}

For tips and tricks on software development, check out my blog

If you find this useful and feel a bit generous then feel free to buy me a coffee 😃

Product Compatible and additional computed target framework versions.
Xamarin.iOS xamarinios10 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.8715 735 12/28/2021
1.0.8714 318 12/28/2021
1.0.8705 318 12/27/2021
1.0.2570 5,162 10/6/2020
1.0.1271 1,281 2/28/2020
1.0.625 664 6/13/2019
1.0.622 579 6/11/2019
1.0.621 626 6/9/2019
1.0.620 628 6/8/2019
1.0.619 654 6/8/2019
1.0.617 621 6/7/2019
1.0.616 631 6/7/2019
1.0.613 589 6/6/2019
1.0.612 589 6/6/2019
1.0.602 575 6/3/2019
1.0.601 599 6/3/2019