Something Exciting is Coming
We're building a powerful real-time collaboration platform to transform the way teams and educators brainstorm, plan, and create.
Stay tuned – launching soon!
2 |
3 | # DrawBox
4 |
5 | [](https://androidweekly.net/issues/issue-502)
6 | [](https://android-arsenal.com/details/1/8292)
7 | [](https://mailchi.mp/kotlinweekly/kotlin-weekly-294)
8 | [](https://search.maven.org/artifact/io.ak1/drawbox)
9 | [](https://devlibrary.withgoogle.com/products/android/repos/akshay2211-DrawBox)
10 |
11 | DrawBox is a multi-purpose tool to draw anything on canvas, written completely on jetpack compose.
12 |
13 | ## Features
14 | * Customisable stoke size and color
15 | * Inbuilt Undo and Redo options
16 | * Reset option
17 | * Easy Implementations
18 | * Export feature to store history localy
19 | * Written on Jetpack-Compose
20 |
21 | ## Demo
22 |
23 |
24 | ## Usage
25 | ```kotlin
26 | val controller = rememberDrawController()
27 |
28 | DrawBox(drawController = controller, modifier = Modifier.fillMaxSize().weight(1f, true))
29 | ```
30 | With multiple methods in DrawController
31 | ```kotlin
32 | * setStrokeColor(color: Color)
33 | * setStrokeWidth(width: Float)
34 | * unDo()
35 | * reDo()
36 | * reset()
37 | * getDrawBoxBitmap() // gives the result bitmap from canvas
38 | * importPath(path)
39 | * exportPath()
40 | ```
41 |
42 | ## Download
43 | [](https://search.maven.org/artifact/io.ak1/drawbox) or grab via Gradle:
44 |
45 | include in app level build.gradle
46 | ```groovy
47 | repositories {
48 | mavenCentral()
49 | }
50 | ```
51 | ```groovy
52 | implementation 'io.ak1:drawbox:1.0.3'
53 | ```
54 | or Maven:
55 | ```xml
56 | We're building a powerful real-time collaboration platform to transform the way teams and educators brainstorm, plan, and create.
Stay tuned – launching soon!