addUpperGoldLabels method Null safety

  1. @override
double addUpperGoldLabels(
  1. List<Widget> result,
  2. Rect pos,
  3. {required double th,
  4. required double tw,
  5. required double bh,
  6. required double bw}
)
override

Implementation

@override
double addUpperGoldLabels(List<Widget> result, Rect pos,
    {required double th,
    required double tw,
    required double bh,
    required double bw}) {
  double y = pos.top;
  result.add(screen.box(
      Rect.fromLTWH(pos.left + tw - 0.05, y + 0.07, 2 * tw + bw + 0.10, 0.22),
      CustomPaint(
          painter: UpperLabel('CLEAR', fTextSmallLabelStyle,
              height * (0.065 + 0.155) / bh))));
  result.add(screen.box(
      Rect.fromLTWH(
          pos.left + 2 * tw - 0.05, y + th + 0.18, 3 * tw + bw + 0.10, 0.25),
      CustomPaint(
          painter:
              UpperLabel('SHOW', fTextStyle, height * (0.14 + 0.11) / bh))));
  result.add(screen.box(
      Rect.fromLTWH(pos.left + 2 * tw - 0.05, y + 5 * th + 0.08,
          2 * tw + bw + 0.1, 0.22),
      CustomPaint(
          painter: UpperLabel('SET COMPL', fTextSmallLabelStyle,
              height * (0.065 + 0.155) / bh))));
  return 0.28;
}