resize method

Future<CommandCompletion> resize(
  1. LogicalSize logicalSize
)

Sets the map's size.

A map with a render session takes its size from the session, so resize the session with RenderSessionHandle.resize() instead.

See mln_map_resize in the C API reference.

Errors:

  • Status.invalidState when the map has a render session.
  • Status.invalidState when a render session attached to the map before the resize applied.

Implementation

Future<CommandCompletion> resize(LogicalSize logicalSize) => _command(
  (arena, completion) => raw.mln_map_resize(
    _handle.raw,
    _writeLogicalSize(logicalSize, arena).ref,
    completion,
    nativeDiagnostic,
  ),
);