Giter Club home page Giter Club logo

jtchartview's Introduction

Version License Platform

JTChartView

JTChartView is the new lightweight and fully customizable solution to draw a curve and fill the space underneath it with a gradient. The result is a beautiful chart.

Example Chart 1 Example Chart 2

Installation

There are two ways to add the JTProgressHUD library to your project. Add it as a regular library or install it through CocoaPods.

pod 'JTChartView'

You may also quick try the example project with

pod try JTChartView

Library requires target iOS 7.0 and above

Works in both - Portrait and Landscape modes

Usage and Customization

JTChartView is designed to be created in one initialization line of code. Core logic creates all layers and draw them into final JTChartView. You MUST create a parent view for that JTChartView to kepp it work correctly.

Simple programmatic example:

// Parent view (Whatever you need)
UIView *baseChartView = [[UIView alloc] initWithFrame:CGRectMake(30.0, 30.0, self.view.frame.size.width - 60.0, self.view.frame.size.width - 60.0)];
baseChartView.layer.masksToBounds = true;
baseChartView.backgroundColor = [UIColor whiteColor];

// JTChartView
JTChartView *chartView = [[JTChartView alloc] initWithFrame:baseChartView.bounds 
                                              values:@[@15, @5, @10] 
                                              curveColor:[UIColor grayColor] 
                                              curveWidth:5.0 
                                              topGradientColor:[UIColor redColor] 
                                              bottomGradientColor:[UIColor orangeColor] 
                                              minY:0.5 
                                              maxY:1.0 
                                              topPadding:10.0];
[baseChartView addSubview:chartView];

Changelog

v1.0.0 - 07.03.15

  • [NEW] Initial commit

Author

This library is open-sourced by Jakub Truhlar.

License

The MIT License (MIT) Copyright © 2015 Jakub Truhlar

jtchartview's People

Contributors

kubatruhlar avatar

Watchers

woshizilong avatar

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.