VxTriangle

Draws a triangle that represents a shape

Use VxTriangle() or .triangle() to draw a triangular shape.

The triangle with 3 sides.

VxTriangle(
height: 120,
width: 180,
backgroundColor: Vx.indigo700
)

Extension

.triangle(
height: 120,
width: 180,
backgroundColor: Vx.indigo700
)

Properties

Prop (Type)DefaultDescription
backgroundColor (Color)ThemeData.primaryColorLight or Themedata.primarycolordarkThe color to fill the triangle
child (Widget)Any child widget
width (double)MediaQuery.of(context).size.shortestSide / 2Width of the triangle
height (double)MediaQuery.of(context).size.shortestSide / 2Height of the triangle
strokeWidth (double)Width to provide stroke.