androidx_graphics_shapes 1.2.0
androidx_graphics_shapes: ^1.2.0 copied to clipboard
A library for easy creation, transformation, and morphing of rounded polygonal shapes. Contains predefined Material Design shapes that can be used at various components.
AndroidX Graphics Shapes
A library for easy creation, transformation, and morphing of rounded polygonal shapes. Contains predefined Material Design shapes that can be used at various components.
A Flutter port of the androidx.graphics.shapes library and the androidx.compose.material3.MaterialShapes object.
Table of contents
Features #
Use this package in your Flutter app to:
-
Create rounded polygonal shapes.
-
Morph between rounded polygonal shapes.
-
Display shapes from the M3 Shape library.
-
Port Kotlin code which uses
androidx.graphics.shapesorandroidx.compose.material3.MaterialShapesto Dart.
Getting started #
Prerequisites #
This is a Flutter-only package. It requires the Flutter SDK to be installed. It doesn't work in a Dart-only environment.
Install the package #
Add the package to a Flutter project:
flutter pub add androidx_graphics_shapes
Import the library #
There are two options for importing the library, depending on whether you want to use M3 Shapes or not.
Shape manipulation is the base functionality of this package.
Only for shape manipulation
import 'package:androidx_graphics_shapes/shapes.dart`;
Both for using M3 Shapes and shape manipulation
import 'package:androidx_graphics_shapes/material_shapes.dart`;
Comparisons #
This section will be updated once in a while, as it's hard to properly collect and compile the features of all packages.
Unpublished packages #
The following packages can only be used as a Git dependency:
-
m3_expressive_shapes by kekland:
-
Source code on GitHub:
kekland/m3_expressive_shapes -
Stability:
As stated by the author "currently I'm only using it internally for my own projects".
-
-
androidx_graphics_shapes & m3_expressive_shapes by benthillerkus:
- Source code on GitHub:
benthillerkus/m3_expressive_shapes
- Source code on GitHub:
Published packages #
The following packages are hosted on Pub and can be added to a project using flutter pub add:
-
material_new_shapes by ulims:
-
Hosted on Pub:
material_new_shapes -
Source code on GitHub:
ulims/material_shapes
-
-
material_shapes by Chitranshu-Nagdawane:
-
Hosted on Pub:
material_shapes -
Source code on GitHub:
Chitranshu-Nagdawane/material_shapes
-
-
flutter_m3shapes:
-
Red flags:
- Does not implement most of the functionality.
-
More info will be added later.
-
-
flutter_m3shapes_extended:
-
Red flags:
-
Fork of
flutter_m3shapes. -
Does not implement most of the functionality.
-
-
More info will be added later.
-
This package #
-
androidx_graphics_shapes by deminearchiver:
-
Hosted on Pub:
androidx_graphics_shapes -
Source code on GitHub:
deminearchiver/dart-flutter-packages -
Parity:
Fully matches the native library in behavior. Contains modifications to original APIs that make the library more idiomatic and optimal to Dart. There is some extended functionality, such as thestartAngleparameter being adouble.
-