control_style 0.1.2
control_style: ^0.1.2 copied to clipboard
Applies additional decoration to Flutter-based text fields, buttons and other controls. This allows for better interface customisation.
0.1.2 #
Bug fixes:
- Restore the canvas state after clipping the outer shadow. The leaked clip
hid the child of a
DecoratedBox/ContainerusingShapeDecorationwith a decorated shape. DecoratedOutlinedBorder.copyWith(side:)now forwards the side to the child instead of making it transparent.OutlinedButton,CheckboxandChipwith a decorated shape and noborderGradientshow their outline again.GradientShadowkeeps its gradient inscaleandcopyWith, and therefore when animated in or out vialerp/lerpListandShapeBorder.scale.GradientShadow.lerpbetween aGradientShadowand a plainBoxShadowinterpolates the gradient instead of dropping it.GradientBorderSide.lerpfades a side withBorderStyle.nonein and out instead of switching it at full opacity.- Forward
TextDirectionto the background and border gradient shaders; gradients withAlignmentDirectionalno longer throw. - Shadows with negative offsets are clipped and painted correctly.
DecoratedInputBorderkeeps itsisOutlinewhile interpolating.- The child's side is preserved when
borderGradienthasstyle: BorderStyle.nonebut is not identical toGradientBorderSide.none. - Decorations interpolate smoothly even when the child borders cannot
interpolate into each other, and when interpolating between a decorated and
a plain
InputBorder/OutlinedBorder. GradientShadow.toString()is well-formed.
Behaviour changes caused by the fixes above:
- Controls that previously lost their outline or content will show them again.
- Shadows with negative
offsetwill become visible where they used to be clipped away or painted over the interior. - Animations that used to jump will animate.
Additions:
DecoratedOutlinedBorder.clipInnerconstructor parameter (defaulttrue).GradientBorderSide.isNoneandGradientBorderSide.toPaint(textDirection:).GradientShadow.fromBoxShadow,GradientShadow.scaleandGradientShadow.copyWithreturningGradientShadow.copyWithandscaleof the decorated borders return the concrete type.DecorationPainter.paintGradientBorder;paintBorder2is deprecated and will be removed in the next breaking release.
Other:
- Skip painting the gradient border when it is switched off.
- Documentation: fixed doc comments and README, described how
borderGradientreplaces the child's side and how buttons,CheckboxandChipresolve their side from the style. - Tests added.
0.1.1 #
- lint rules updated
0.1.0 #
- document public members
- place the code in
srcfolder - fix SDK version
0.0.3 #
- Replaced deprecated functions.
- Updated lint rules.
0.0.2 #
- Fixed bugs in
lerpfunctions.
0.0.1 #
- Initial release.