Skip to content

Simple lightweight kotlin-dsl for canvas drawings

License

Notifications You must be signed in to change notification settings

fAntel/canvasdsl

 
 

Repository files navigation

CanvasDSL

Simple lightweight kotlin-dsl for canvas drawings.

Key features

  • Inherited from standard drawable
  • Easy to use for value animation
  • SVG-like primitives
  • Supports references to predefined groups
  • Viewport mechanics with relative "viewport points"
  • No compatibility limits - works with minimum android sdk 1
  • One dependency: kotlin stdlib, you should use it anyway for kotlin

Usecases

  • Charts
  • Determinate progress, charge indicators
  • Another simple data visualization
  • Bitmap decoration

Usage

Add it in your root build.gradle at the end of repositories:

	allprojects {
		repositories {
			//...
			maven { url 'https://jitpack.io' }
		}
	} 

Add the dependency:

	dependencies {
	        implementation 'com.github.AlexeyErofeev:canvasdsl:1.0.2'
	}

Example

Included example contains chart bar for stress level for last completed 7 days, which shows how to use main primitives and measures except "path" Included example screenshot

About

Simple lightweight kotlin-dsl for canvas drawings

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Kotlin 100.0%