alongOffset method

Offset alongOffset(
  1. Offset other
)

Returns the offset that is this fraction in the direction of the given offset.

Implementation

Offset alongOffset(Offset other) {
  final double centerX = other.dx / 2.0;
  final double centerY = other.dy / 2.0;
  return Offset(centerX + x * centerX, centerY + y * centerY);
}