offset static method

Map<String, dynamic>? offset(
  1. Offset? offset
)

Returns an Offset from the specified map.

The map must have an x key and a y key, doubles.

Implementation

static Map<String, dynamic>? offset(Offset? offset) {
  if (offset == null) return null;
  return {'x': offset.dx, 'y': offset.dy};
}