完善高清化ui

This commit is contained in:
unanmed 2022-12-31 19:54:22 +08:00
parent 4ea4592d6f
commit cc6ee7e7af

View File

@ -1738,9 +1738,8 @@ ui.prototype._drawTextContent_draw = function (ctx, tempCtx, content, config) {
if (config.index >= config.blocks.length) return false; if (config.index >= config.blocks.length) return false;
var block = config.blocks[config.index++]; var block = config.blocks[config.index++];
if (block != null) { if (block != null) {
const scale = config.isHD // It works, why?
? devicePixelRatio * core.domStyle.scale const scale = config.isHD ? devicePixelRatio ** 2 : 1;
: 1;
core.drawImage( core.drawImage(
ctx, ctx,
tempCtx.canvas, tempCtx.canvas,