resolveDimension static method
Implementation
static PDimension resolveDimension(PDimension? dimension, num? w, num? h,
{PCanvasElement? element}) {
if (dimension != null) {
if (element != null) {
PCanvasElement.resolveWithElement(dimension, element);
}
return dimension;
}
if (w == null || h == null) {
throw ArgumentError("Invalid dimension> width: $w ; height: $h");
}
return PDimension(w, h);
}