 2, y - caretLength);
        canvasContext2D.strokeStyle = 'green';
        canvasContext2D.stroke();
    }

    function renderUnderlineDecoration(rangeStart, rangeEnd, style, thickness) {
        let lineStartX = anchorX + rangeStart * charWidth;
        let offsetX = 2; // space between underlines of different phrases
        let lineEndX = anchorX + rangeEnd * charWidth - offsetX;
        let offsetY = 7; // space between chars and the underline
        let lineY = anchorY + offsetY;
       