Simple android library to present an animated ferris wheel

Overview

Ferris Wheel View

Android Arsenal Build Status Download License

image

Overview

An Android Library used to implement an animated Ferris Wheel in android.

  • API SDK 15+
  • Written in Kotlin
  • Supports landscape mode
  • Lightweight view with 1 drawable inside, uses canvas 2D drawing technique

Preview-demo Monochrome-sample
Inspired by the one-color Planet Coaster loading screen

Mentions

Sample Project

For more information how to use the library in Kotlin/Java checkout Sample App in repository.

Quick Setup

Include library

Using Gradle

FerrisWheelView is distributed using jcenter.

repositories { 
    jcenter()
}
dependencies {
    implementation 'ru.github.igla:ferriswheel:1.2'
}

Or Maven

<dependency>
  <groupId>ru.github.igla</groupId>
  <artifactId>ferriswheel</artifactId>
  <version>1.2</version>
  <type>pom</type>
</dependency>

Usage

Add widget in your xml layout like this:

    <ru.github.igla.ferriswheel.FerrisWheelView
        android:id="@+id/ferrisWheelView"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_gravity="center"
        app:fwv_cabinsNumber="8"
        app:fwv_rotateSpeed="6" />

To start animation you need only call this method:

    ferrisWheelView.startAnimation()

Or you can stop/pause/resume animation by the following methods:

    ferrisWheelView.stopAnimation()
    ferrisWheelView.pauseAnimation()
    ferrisWheelView.resumeAnimation()

Attributes

attr format default description
fwv_cabinSize dimension 42dp the size of each cabin
fwv_cabinsNumber integer 8 the number of cabins on the wheel
fwv_isClockwise boolean true toogle the rotate direction
fwv_isAutoRotate boolean true start rotating wheel automatically after initialization
fwv_rotateSpeed integer 6 wheel speed rotation measured in degrees
fwv_startAngle float 0 angle at which wheel will start to rotate
fwv_wheelStrokeColor color #73302b #73302b with this color the wheel will be filled
fwv_baseStrokeColor color #666666 #666666 with this color the wheel base will be filled
fwv_cabinFillColor color array with this color the cabin will be filled
fwv_cabinLineStrokeColor color #000000 #000000 with this color the cabin line will be filled

Issues

If you find any problems or would like to suggest a feature, please feel free to file an issue

License

Copyright 2018 Igor Lashkov

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
You might also like...
[Android Library] A SharedPreferences helper library to save and fetch the values easily.

Preference Helper A SharedPreferences helper library to save and fetch the values easily. Featured in Use in your project Add this to your module's bu

Simple(vanilla) yet 'Do it all' place picker for your place picking needs in Android
Simple(vanilla) yet 'Do it all' place picker for your place picking needs in Android

Vanilla Place Picker Vanilla Place Picker provides a UI that displays an interactive map to get the place details and Autocomplete functionality, whic

Simple PGP encryption/decryption on android.
Simple PGP encryption/decryption on android.

Android-PGP Introduction Adds PGP encryption and decryption support. How to install repositories { maven { url "https://jitpack.io" }

Dead simple EventBus for Android made with Kotlin and RxJava 2

KBus Super lightweight (13 LOC) and minimalistic (post(), subscribe(), unsubscribe()) EventBus written with idiomatic Kotlin and RxJava 2 KBus in 3 st

A simple 'Slide to Unlock' Material widget for Android, written in Kotlin 📱🎨🦄
A simple 'Slide to Unlock' Material widget for Android, written in Kotlin 📱🎨🦄

Slide To Act A simple Slide to Unlock Material widget for Android, written in Kotlin 🇰. Getting Started Example Features Attributes area_margin inner

Simple Kotlin Multiplatform PrayerTimes App for iOS and Android

Kotlin Multiplatform ___ _______ ___ / _ \_______ ___ _____ ___/_ __(_)_ _ ___ ___ / _ | __

An example of a test task for creating a simple currency converter application for the Android platform. The app is developed using Kotlin, MVI, Dagger Hilt, Retrofit, Jetpack Compose.
An example of a test task for creating a simple currency converter application for the Android platform. The app is developed using Kotlin, MVI, Dagger Hilt, Retrofit, Jetpack Compose.

Simple Currency Converter Simple Currency Converter Android App by Isaev Semyon An example of a test task for creating a simple currency converter app

A simple project that describes the relationship between the view and it's viewmodel in android development
A simple project that describes the relationship between the view and it's viewmodel in android development

View-ViewModel-Communication A simple project that describes the relationship between the view and it's viewmodel in android development In MVVM archi

Simple android application that consumes Rick and Morty API to display characters,episodes,Location
Simple android application that consumes Rick and Morty API to display characters,episodes,Location

Rick and Morty Compose An android app built using Kotlin that consumes Rick and

Comments
  • Suggest new feacture

    Suggest new feacture

    You can add an onclick event on each cabin? I want yo use a ferris wheel component like a different component to "loading component". Each cabin trigger a onclick for differents actions Also you can add a xml attribute like "autoplay:true" for auto-play animation

    Thanks for your time!

    opened by ghost 1
  • Cabin Fill Color

    Cabin Fill Color

    I wanted to change the colors of the cabins but was not able to. I tried creating an array resource file like suggested in the documentations but was not able to do it.

    opened by UFivePlus 0
Releases(v.1.2)
Owner
Igor Lashkov
Igor Lashkov
Animated tabbar with native control

SSCustomBottomNavigation Getting Started SSCustomBottomNavigation is a customizable bottom bar library with curved animations. The actual features are

Simform Solutions 363 Dec 30, 2022
Simple Android Library, that provides easy way to start the Activities with arguments.

Warning: Library is not maintained anymore. If you want to take care of this library, propose it via Pull Request. It needs adjustmensts for newer ver

Marcin Moskała 429 Dec 15, 2022
A lightweight and simple Kotlin library for deep link handling on Android 🔗.

A lightweight and simple Kotlin library for deep link handling on Android ??.

Jeziel Lago 101 Aug 14, 2022
This library is a set of simple wrapper classes that are aimed to help you easily access android device information.

SysInfo Simple, single class wrapper to get device information from an android device. This library provides an easy way to access all the device info

Klejvi Kapaj 7 Dec 27, 2022
A lightweight, simple, smart and powerful Android routing library.

RxRouter Read this in other languages: 中文, English A lightweight, simple, smart and powerful Android routing library. Getting started Setting up the d

Season 323 Nov 10, 2022
A simple library that can connect your autocomplete edittext to Google places api

Google Places AutoComplete EditText A simple library that can connect your autocomplete edittext to Google's places api Supporting Places AutoComplete

Mukesh Solanki 71 Dec 28, 2022
🚟 Lightweight, and simple scheduling library made for Kotlin (JVM)

Haru ?? Lightweight, and simple scheduling library made for Kotlin (JVM) Why did you build this? I built this library as a personal usage library to h

Noel 13 Dec 16, 2022
Simple Service Locator Library

ScrapServiceLocator A small, asynchronous IoC library for Android that might be half compile-time safe (?) Before I start, I'm very poor at English, s

HyungWoo Kim 3 Aug 28, 2021
Very simple Kotlin caching library

Very simple Kotlin caching library

Ji Sungbin 4 Jun 15, 2022
A Kotlin library providing a simple, high-performance way to use off-heap native memory in JVM applications.

native_memory_allocator A library which uses sun.misc.Unsafe to allocate off-heap native memory. Motivation The goal of this project is to provide a s

Target 5 Dec 8, 2022