replayTextBackground_(
    context,
    p1,
    p2,
    p3,
    p4,
    fillInstruction,
    strokeInstruction,
  ) {
    context.beginPath();
    context.moveTo.apply(context, p1);
    context.lineTo.apply(context, p2);
    context.lineTo.apply(context, p3);
    context.lineTo.apply(context, p4);
    context.lineTo.apply(context, p1);
    if (fillInstruction) {
      this.alignAndScaleFill_ = /** @type {number} */ (fillInstruction[2]);
      context.fillStyle = /** @type {string} */ (fillInstruction[1]);
      this.fill_(context);
    }
    if (strokeInstruction) {
      this.setStrokeStyle_(
        context,
        /** @type {Array<*>} */ (strokeInstruction),
      );
      context.stroke();
    }
  }
@param {CanvasRenderingContext2D} context Context.
@param {import("../../coordinate.js").Coordinate} p1 1st point of the background box.
@param {import("../../coordinate.js").Coordinate} p2 2nd point of the background box.
@param {import("../../coordinate.js").Coordinate} p3 3rd point of the background box.
@param {import("../../coordinate.js").Coordinate} p4 4th point of the background box.
@param {Array<*>} fillInstruction Fill instruction.
@param {Array<*>} strokeInstruction Stroke instruction.