getWindowSize method

({({int height, int width}) cells, ({int height, int width}) pixels}) getWindowSize()

Returns the current size of the terminal window in cells and pixels.

Implementation

({({int width, int height}) cells, ({int width, int height}) pixels})
getWindowSize() {
  final (w, h) = getSize();
  return (cells: (width: w, height: h), pixels: (width: 0, height: 0));
}