SExtensionsScreenUtil class

A widget that initializes the FlutterSExtensions package with a given design-time screenSize and wraps the provided app widget.

This widget should be placed at the root of the widget tree (above MaterialApp/CupertinoApp) so that the design-size is set once and the extension context is updated before any descendant widgets are built.

Inheritance
Available extensions

Constructors

SExtensionsScreenUtil({Key? key, required Size screenSize, required Widget app})
Creates an SExtensionsScreenUtil.
const

Properties

app Widget
The root widget of the application.
final
hashCode int
The hash code for this object.
no setterinherited
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
screenSize Size
The design-time size (in logical pixels) used for scaling calculations.
final

Methods

align({Key? key, AlignmentGeometry alignment = .center, double? widthFactor, double? heightFactor}) Align

Available on Widget, provided by the WidgetExtensions extension

Returns a new aligned widget with the given alignment.
build(BuildContext context) Widget
Describes the part of the user interface represented by this widget.
override
card({Key? key, bool borderOnForeground = true, bool semanticContainer = true, Color? surfaceTintColor, EdgeInsetsGeometry? margin, Color? color, Color? shadowColor, double? elevation, ShapeBorder? shape, Clip? clipBehavior}) Card

Available on Widget, provided by the WidgetExtensions extension

Returns a new Card widget with the given child.
center({Key? key, double? widthFactor, double? heightFactor}) Center

Available on Widget, provided by the WidgetExtensions extension

Returns a new centered widget.
constrained({double? width, double? height}) SizedBox

Available on Widget, provided by the WidgetExtensions extension

Returns a new constrained widget with the given width and height.
createElement() StatelessElement
Creates a StatelessElement to manage this widget's location in the tree.
inherited
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
decoration({Key? key, Color? color, DecorationImage? image, BoxBorder? border, BorderRadiusGeometry? borderRadius, List<BoxShadow>? boxShadow, Gradient? gradient, BlendMode? backgroundBlendMode, BoxShape shape = .rectangle}) Container

Available on Widget, provided by the WidgetExtensions extension

Returns a decorated widget with the given decoration.
directionality({required TextDirection direction}) Directionality

Available on Widget, provided by the WidgetExtensions extension

Returns a new directed text widget with the given text direction.
expanded({Key? key, int flex = 1}) Expanded

Available on Widget, provided by the WidgetExtensions extension

Returns a new expanded widget with the given flex.
fade({Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOut, double beginOpacity = 0}) Widget

Available on Widget, provided by the WidgetExtensions extension

Fades the widget.
flexible({Key? key, int flex = 1}) Flexible

Available on Widget, provided by the WidgetExtensions extension

Returns a new flexible widget with the given flex.
gestures({Key? key, void onTapDown(TapDownDetails)?, void onTapUp(TapUpDetails)?, void onTap()?, void onTapMove(TapMoveDetails)?, void onTapCancel()?, void onSecondaryTap()?, void onSecondaryTapDown(TapDownDetails)?, void onSecondaryTapUp(TapUpDetails)?, void onSecondaryTapCancel()?, void onTertiaryTapDown(TapDownDetails)?, void onTertiaryTapUp(TapUpDetails)?, void onTertiaryTapCancel()?, void onDoubleTapDown(TapDownDetails)?, void onDoubleTap()?, void onDoubleTapCancel()?, void onLongPressDown(LongPressDownDetails)?, void onLongPressCancel()?, void onLongPress()?, void onLongPressStart(LongPressStartDetails)?, void onLongPressMoveUpdate(LongPressMoveUpdateDetails)?, void onLongPressUp()?, void onLongPressEnd(LongPressEndDetails)?, void onSecondaryLongPressDown(LongPressDownDetails)?, void onSecondaryLongPressCancel()?, void onSecondaryLongPress()?, void onSecondaryLongPressStart(LongPressStartDetails)?, void onSecondaryLongPressMoveUpdate(LongPressMoveUpdateDetails)?, void onSecondaryLongPressUp()?, void onSecondaryLongPressEnd(LongPressEndDetails)?, void onTertiaryLongPressDown(LongPressDownDetails)?, void onTertiaryLongPressCancel()?, void onTertiaryLongPress()?, void onTertiaryLongPressStart(LongPressStartDetails)?, void onTertiaryLongPressMoveUpdate(LongPressMoveUpdateDetails)?, void onTertiaryLongPressUp()?, void onTertiaryLongPressEnd(LongPressEndDetails)?, void onVerticalDragDown(DragDownDetails)?, void onVerticalDragStart(DragStartDetails)?, void onVerticalDragUpdate(DragUpdateDetails)?, void onVerticalDragEnd(DragEndDetails)?, void onVerticalDragCancel()?, void onHorizontalDragDown(DragDownDetails)?, void onHorizontalDragStart(DragStartDetails)?, void onHorizontalDragUpdate(DragUpdateDetails)?, void onHorizontalDragEnd(DragEndDetails)?, void onHorizontalDragCancel()?, void onForcePressStart(ForcePressDetails)?, void onForcePressPeak(ForcePressDetails)?, void onForcePressUpdate(ForcePressDetails)?, void onForcePressEnd(ForcePressDetails)?, void onPanDown(DragDownDetails)?, void onPanStart(DragStartDetails)?, void onPanUpdate(DragUpdateDetails)?, void onPanEnd(DragEndDetails)?, void onPanCancel()?, void onScaleStart(ScaleStartDetails)?, void onScaleUpdate(ScaleUpdateDetails)?, void onScaleEnd(ScaleEndDetails)?, HitTestBehavior? behavior, bool excludeFromSemantics = false, DragStartBehavior dragStartBehavior = DragStartBehavior.start, bool trackpadScrollCausesScale = false, Offset trackpadScrollToScaleFactor = kDefaultTrackpadScrollToScaleFactor, Set<PointerDeviceKind>? supportedDevices}) GestureDetector

Available on Widget, provided by the WidgetExtensions extension

Returns a new GestureDetector widget with the given gestures.
height(double height) SizedBox

Available on Widget, provided by the WidgetExtensions extension

Returns a new constrained widget with the given height.
hero({Key? key, required Object tag, Tween<Rect?> createRectTween(Rect?, Rect?)?, Widget flightShuttleBuilder(BuildContext, Animation<double>, HeroFlightDirection, BuildContext, BuildContext)?, Widget placeholderBuilder(BuildContext, Size, Widget)?, bool transitionOnUserGestures = false}) Hero

Available on Widget, provided by the WidgetExtensions extension

Returns a new Hero widget with the given tag.
ink({VoidCallback? onTap, BorderRadius? radius}) Widget

Available on Widget, provided by the WidgetExtensions extension

Returns a new InkWell widget with the given onTap callback, and optional radius for the ink splash.
intrinsicHeight({Key? key, double? stepHeight}) IntrinsicHeight

Available on Widget, provided by the WidgetExtensions extension

Returns a new IntrinsicHeight widget.
intrinsicWidth({Key? key, double? stepWidth, double? stepHeight}) IntrinsicWidth

Available on Widget, provided by the WidgetExtensions extension

Returns a new IntrinsicWidth widget.
margin({double? all, double? horizontal, double? vertical, double? left, double? top, double? right, double? bottom}) Container

Available on Widget, provided by the WidgetExtensions extension

Returns a new widget with the given margin.
marginAll(double margin) Container

Available on Widget, provided by the WidgetExtensions extension

Returns a new widget with the given margin.
marginOnly({double? left = 0, double? top = 0, double? right = 0, double? bottom = 0}) Container

Available on Widget, provided by the WidgetExtensions extension

Returns a new widget with the given margin.
marginSymmetric({double? vertical = 0, double? horizontal = 0}) Container

Available on Widget, provided by the WidgetExtensions extension

Returns a new widget with the given margin.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onDoubleTap(void onDoubleTap()?) GestureDetector

Available on Widget, provided by the WidgetExtensions extension

Returns a new GestureDetector widget with the given onDoubleTap callback.
onLongPress(void onLongPress()?) GestureDetector

Available on Widget, provided by the WidgetExtensions extension

Returns a new GestureDetector widget with the given onLongPress callback.
onTap(void onTap()?) GestureDetector

Available on Widget, provided by the WidgetExtensions extension

Returns a new GestureDetector widget with the given onTap callback.
onTouch(void onTouch(TapDownDetails tapDetails)?) GestureDetector

Available on Widget, provided by the WidgetExtensions extension

Returns a new GestureDetector widget with the given onTouch callback.
padding({double? all, double? horizontal, double? vertical, double? left, double? top, double? right, double? bottom}) Widget

Available on Widget, provided by the WidgetExtensions extension

Returns a new widget with the given padding.
paddingAll(double padding) Padding

Available on Widget, provided by the WidgetExtensions extension

Returns a new widget with the given padding.
paddingOnly({double? left = 0, double? top = 0, double? right = 0, double? bottom = 0}) Padding

Available on Widget, provided by the WidgetExtensions extension

Returns a new widget with the given padding.
paddingSymmetric({double? vertical = 0, double? horizontal = 0}) Padding

Available on Widget, provided by the WidgetExtensions extension

Returns a new widget with the given padding.
positioned({Key? key, double? left, double? top, double? right, double? bottom, double? width, double? height}) Positioned

Available on Widget, provided by the WidgetExtensions extension

Returns a new positioned widget with the given position.
positionedDirectional({Key? key, double? start, double? top, double? end, double? bottom, double? width, double? height}) PositionedDirectional

Available on Widget, provided by the WidgetExtensions extension

Returns a new directional positioned widget with the given position.
refreshable({Key? key, double displacement = 40.0, double edgeOffset = 0.0, required Future<void> onRefresh(), Color? color, Color? backgroundColor, bool notificationPredicate(ScrollNotification) = defaultScrollNotificationPredicate, String? semanticsLabel, String? semanticsValue, double strokeWidth = RefreshProgressIndicator.defaultStrokeWidth, RefreshIndicatorTriggerMode triggerMode = .onEdge, double elevation = 2.0}) RefreshIndicator

Available on Widget, provided by the WidgetExtensions extension

Returns a new refresh indicator widget.
rotate({Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOut, double beginAngle = 0.05}) Widget

Available on Widget, provided by the WidgetExtensions extension

Rotates the widget.
rounded({Key? key, double radius = 8, Clip clipBehavior = .antiAlias, CustomClipper<RRect>? clipper}) ClipRRect

Available on Widget, provided by the WidgetExtensions extension

Returns a new rounded widget with the given radius.
roundedBottom({Key? key, double radius = 8, Clip clipBehavior = .antiAlias, CustomClipper<RRect>? clipper}) ClipRRect

Available on Widget, provided by the WidgetExtensions extension

Returns a new rounded widget from bottom with the given radius.
roundedLeft({Key? key, double radius = 8, Clip clipBehavior = .antiAlias, CustomClipper<RRect>? clipper}) ClipRRect

Available on Widget, provided by the WidgetExtensions extension

Returns a new rounded widget from left with the given radius.
roundedRight({Key? key, double radius = 8, Clip clipBehavior = .antiAlias, CustomClipper<RRect>? clipper}) ClipRRect

Available on Widget, provided by the WidgetExtensions extension

Returns a new rounded widget from right with the given radius.
roundedTop({Key? key, double radius = 8, Clip clipBehavior = .antiAlias, CustomClipper<RRect>? clipper}) ClipRRect

Available on Widget, provided by the WidgetExtensions extension

Returns a new rounded widget from top with the given radius.
safeArea({Key? key, bool left = true, bool top = true, bool right = true, bool bottom = true, EdgeInsets minimum = .zero, bool maintainBottomViewPadding = false}) SafeArea

Available on Widget, provided by the WidgetExtensions extension

Wrap this widget with safe area.
scaffold({Key? key, PreferredSizeWidget? appBar, Widget? body, Widget? floatingActionButton, FloatingActionButtonLocation? floatingActionButtonLocation, FloatingActionButtonAnimator? floatingActionButtonAnimator, List<Widget>? persistentFooterButtons, AlignmentDirectional persistentFooterAlignment = .centerEnd, BoxDecoration? persistentFooterDecoration, Widget? drawer, void onDrawerChanged(bool)?, Widget? endDrawer, void onEndDrawerChanged(bool)?, Widget? bottomNavigationBar, Widget? bottomSheet, Color? backgroundColor, bool? resizeToAvoidBottomInset, bool primary = true, DragStartBehavior drawerDragStartBehavior = .start, bool extendBody = false, bool drawerBarrierDismissible = true, bool extendBodyBehindAppBar = false, Color? drawerScrimColor, Widget? bottomSheetScrimBuilder(BuildContext, Animation<double>) = _defaultBottomSheetScrimBuilder, double? drawerEdgeDragWidth, bool drawerEnableOpenDragGesture = true, bool endDrawerEnableOpenDragGesture = true, String? restorationId}) Scaffold

Available on Widget, provided by the WidgetExtensions extension

Returns a new Scaffold widget with the given body.
scale({Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOut, double beginScale = 0.95}) Widget

Available on Widget, provided by the WidgetExtensions extension

Scales the widget.
scrollable({Key? key, Axis scrollDirection = .vertical, bool reverse = false, EdgeInsetsGeometry? padding, bool? primary, ScrollPhysics? physics, ScrollController? controller, Widget? child, DragStartBehavior dragStartBehavior = .start, Clip clipBehavior = .hardEdge, HitTestBehavior hitTestBehavior = .opaque, String? restorationId, ScrollViewKeyboardDismissBehavior? keyboardDismissBehavior}) SingleChildScrollView

Available on Widget, provided by the WidgetExtensions extension

Returns a new scrollable widget.
slideDown({Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOut, Offset? beginOffset}) Widget

Available on Widget, provided by the WidgetExtensions extension

Slides the widget down.
slideLeft({Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOut, Offset? beginOffset}) Widget

Available on Widget, provided by the WidgetExtensions extension

Slides the widget left.
slideRight({Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOut, Offset? beginOffset}) Widget

Available on Widget, provided by the WidgetExtensions extension

Slides the widget right.
slideUp({Duration duration = const Duration(milliseconds: 300), Curve curve = Curves.easeOut, Offset? beginOffset}) Widget

Available on Widget, provided by the WidgetExtensions extension

Slides the widget up.
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
tooltip({Key? key, String? message, InlineSpan? richMessage, BoxConstraints? constraints, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, double? verticalOffset, bool? preferBelow, bool? excludeFromSemantics, Decoration? decoration, TextStyle? textStyle, TextAlign? textAlign, Duration? waitDuration, Duration? showDuration, Duration? exitDuration, bool enableTapToDismiss = true, TooltipTriggerMode? triggerMode, bool? enableFeedback, void onTriggered()?, MouseCursor? mouseCursor, bool? ignorePointer}) Tooltip

Available on Widget, provided by the WidgetExtensions extension

Returns a new Tooltip widget with the given message.
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited
width(double width) SizedBox

Available on Widget, provided by the WidgetExtensions extension

Returns a new constrained widget with the given width.

Operators

operator ==(Object other) bool
The equality operator.
inherited