Improve rendering of dotted underlines

Fixes #4060
This commit is contained in:
Daniel Imms
2022-12-23 14:04:12 -08:00
parent d34bb5ed79
commit d17df65fad
+1 -1
View File
@@ -587,7 +587,7 @@ export class TextureAtlas implements ITextureAtlas {
); );
break; break;
case UnderlineStyle.DOTTED: case UnderlineStyle.DOTTED:
this._tmpCtx.setLineDash([this._config.devicePixelRatio * 2, this._config.devicePixelRatio]); this._tmpCtx.setLineDash([Math.round(lineWidth), Math.round(lineWidth)]);
this._tmpCtx.moveTo(xChLeft, yTop); this._tmpCtx.moveTo(xChLeft, yTop);
this._tmpCtx.lineTo(xChRight, yTop); this._tmpCtx.lineTo(xChRight, yTop);
break; break;