radius method

double radius(
  1. num r
)

根据宽度或高度中的较小值进行适配 Adapt according to the smaller of width or height

Implementation

double radius(num r) => r * min(scaleWidth, scaleHeight);