get canvasBounds() {
    if (this._canvas) {
      const { left, top, right, bottom } = this._canvas.getBoundingClientRect();
      return {
        viewMin: this.clientPointToViewPoint({ clientX: left, clientY: top }),
        viewMax: this.clientPointToViewPoint({ clientX: right, clientY: bottom }),
        left, top, right, bottom,
        canvasWidth: this._canvas.width,
        canvasHeight: this._canvas.height,
      };
    } else {
      return undefined;
    }
  }
@returns {CanvasBounds | undefined} the boundaries of the canvas linked to
this coordinate system, or undefined if no canvas is set.