Coder Social home page Coder Social logo

cemolcay / livefader Goto Github PK

View Code? Open in Web Editor NEW
25.0 4.0 2.0 306 KB

@IBDesignable Horizontal or vertical UIControl subclass that can start from bottom or middle of the control.

License: MIT License

Ruby 31.42% Swift 68.58%
swift fader uicontrol slider audio ibdesignable

livefader's Introduction

LiveFader

@IBDesignable Horizontal or vertical UIControl subclass that can start from bottom or middle of the control.

Demo

alt tag

Requirements

  • iOS 9.0+
  • Swift 4.2+
  • Xcode 10.0+

Install

Manual

  • Import the LiveFader.swift file into your codebase

Cocoapods

pod 'LiveFader'

Usage

  • Create a UIView instance in your storyboard and make it's class to LiveFaderView.
  • Or create a LiveFaderView programmatically.
  • Set the bottom or middle control style with the style property.
  • Set the horizontal or vertical control type with the controlType property.
  • You can bind a @IBAction to the LiveFader's valueChanged event from the storyboard or programmatically.
  • You can change the enabled/disabled/highlighted color styles from the @IBInspectable in storyboard or programmatically.
  • LiveFaderView is an open class, so you can subclass it to make it look anything you want, by playing with it's layers or adding new ones.

LiveFaderScrollView

alt tag

  • Custom scroll view subclass lets you edit all faders with a single pan gesture recognizer.
  • Set its isFaderPanningEnabled property to true.
  • It won't let you scroll in this mode because you will use the current pan gesture for editing faders instead of scrolling.
  • Finds all LiveFaderViews in itself and it's subviews recursively, feel free to add your faders in a stack view or a custom container inside your LiveFaderScrollView.

SwiftUI Bridge

You can use it with SwiftUI
https://gist.github.com/cemolcay/8cf7a413e4fcc20bc8c456bc0a5832be

App Store

This library used in my apps in App Store, check them up!

livefader's People

Contributors

cemolcay avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

carabina rimasinc

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.