buildBody method

Widget buildBody(
  1. BuildContext context,
  2. MorphGlassOutline outline,
  3. List<MorphGlassSurface> surfaces
)

Builds the widget that draws one glass body: the surfaces a control fused into one silhouette, filling the box of their layer, with outline its edge in that box's coordinates.

The default fills the outline's path flat with the color of the first of surfaces, faded by its MorphGlassSurface.opacity, as the control does without a painter.

Implementation

Widget buildBody(
  BuildContext context,
  MorphGlassOutline outline,
  List<MorphGlassSurface> surfaces,
) {
  return CustomPaint(
    painter: _BodyPainter(MorphFixed(_bodyOf(outline, surfaces))),
  );
}