Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/herbsun/okklineswift
Draw the K-Line by Swift, support iOS & macOS
https://github.com/herbsun/okklineswift
kline macos stock swift swift3
Last synced: about 17 hours ago
JSON representation
Draw the K-Line by Swift, support iOS & macOS
- Host: GitHub
- URL: https://github.com/herbsun/okklineswift
- Owner: herbsun
- License: mit
- Created: 2016-11-22T06:43:52.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2018-01-25T04:54:12.000Z (about 7 years ago)
- Last Synced: 2025-02-06T08:09:48.415Z (about 17 hours ago)
- Topics: kline, macos, stock, swift, swift3
- Language: Swift
- Homepage:
- Size: 6.59 MB
- Stars: 419
- Watchers: 17
- Forks: 75
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
OKKLineSwift
### [中文介绍](README_CN.md)
:smile: **OKKLineSwift** is written in Swift3 to draw the stock K-line library
## Screenshot
iOS Screenshot
[Support drag gestures, long press gestures (see details), knead gestures (zoom in)]![OKKLineSwift](https://github.com/Herb-Sun/OKKLineSwift/blob/master/Screenshot/OKKLineSwift-iOS.gif)
macOS Screenshot
[Support drag events, crosshairs follow, mouse scrolling events (zoom in)]![OKKLineSwift](https://github.com/Herb-Sun/OKKLineSwift/blob/master/Screenshot/OKKLineSwift-macOS.gif)
Support
===
Swift 3.0iOS 8+
macOS 10.10+
Installation
===
#### Manually1. Download the full file.
2. Drag the OKKLineSwift folder to your project.## Source directory
|Directory | Description|
| ---------- | -----------|
| Configuration | OKConfiguration.swift - This is a global control class that controls the global theme (e.g. color, font size, etc.) |
| Views | OKKLineView - This class is the parent view of all views
OKKLineDrawView.swift - This class is a parent view of all K-line views that handle gestures and data sources
OKValueView.swift - Responsible for drawing prices
1、MainView:
OKKLineMainView.swift - Responsible for drawing the main graph
2、VolumeView:
OKKLineVolumeView.swift - Responsible for drawing the volume view
3、AccessoryView:
OKKLineAccessoryView.swift - Responsible for drawing the index view
4、SegmentView:
OKSegmentView.swift - Responsible for displaying timeline or indicator type
|
| Models | Data model directory, mainly K-line data and a variety of indicators model |
| Tools | Tool class directory,for example:
OKLineBrush.swift - Responsible for drawing lines
OKMALineBrush.swift - Responsible for drawing the average class|## TODO
- [x] Support macOS system
- [ ] Support for more metric types## Licenses
All the OK at the beginning of the project source code to comply with MIT license.
Copyright (c) 2016 Herb. All rights reserved.## Contributions
Welcome to contribute to your ideas and code! You can pull requests and issues here! :clap: