A simple flutter widget to paint with your fingers.
The widget supports:
- Changing fore- and background color
- Changing the thickness of lines you draw
- Exporting your painting as png
- Undo drawing a line
- Clearing the hole drawing
Some Notes #
- After calling 'finish()' on a PainterController you can't draw on this painting any more
- To create a new painting after finishing the old one simply create a new PainterController
- Calling 'finish()' for the first time will render the drawing. Successive calls will then return a cached version of the rendered picture
For a full example take a look at the example project. Here is a short recording showing it. Note that the color picker is an external dependency which is only required for the example.
[0.3.2] - 07.07.2019
- Merge pull request #5 from devobs/flutter_upgrade
- Upgrade to flutter 1.14.11
[0.3.1] - 22.06.2018
- Initial public release
Painter example #
A example to demonstrate painter. The color picker is an external dependency!
Use this package as a library
1. Depend on it
Add this to your package's pubspec.yaml file:
dependencies: painter: ^0.3.2
2. Install it
You can install packages from the command line:
$ flutter pub get
Alternatively, your editor might support
flutter pub get.
Check the docs for your editor to learn more.
3. Import it
Now in your Dart code, you can use:
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
We analyzed this package on Oct 11, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:
- Dart: 2.5.1
- pana: 0.12.21
- Flutter: 1.9.1+hotfix.4
Detected platforms: Flutter
References Flutter, and has no conflicting libraries.
flutter format to format