padding_extra 1.1.0
padding_extra: ^1.1.0 copied to clipboard
This package provides extra padding widgets
padding_extra #
This package provides extra padding related widgets.
Features #
- Padding Widgets (with shortcut named too)
- Safe Area Padding Widgets (with shortcut named too)
- Alignment Widgets
- Size Widgets
Getting started #
$ flutter pub add local_file_preferences
This will add a line like this to your package's pubspec.yaml (and run an implicit flutter pub get):
dependencies:
local_file_preferences: {*version}
Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.
Import it Now in your Dart code, you can use:
import 'package:padding_extra/padding_extra.dart';
Usage #
Padding Widgets #
PaddingAll,PAllPaddingHorizontal,PXPaddingVertical,PYPaddingSymmetric,PSymmPaddingTop,PTPaddingLeft,PLPaddingRight,PRPaddingBottom,PB
SafeArea Widgets #
Internally, These widgets use SafeArea widget and remove specified padding with MediaQuery.removePadding.
Also, you can pass extra parameter to add extra padding at that direction.
SafeAreaHorizontal,SafeAreaXSafeAreaVertical,SafeAreaYSafeAreaTopSafeAreaLeftSafeAreaRightSafeAreaBottom
Size Widgets #
FullFullWidth,FullWFullHeight,FullH
Alignment Widgets #
TopLeftRightBottomTopLeftTopRightBottomLeftBottomRight
Code #
PaddingAll(
24,
child: _buildRect(context),
),
SafeAreaHorizontal(
child: Container(
color: Colors.yellow,
width: double.infinity,
height: 100,
),
),