KASM-1834 disable anti-aliasing when screen ratio is 1:1
This commit is contained in:
parent
e0bb9f6bcf
commit
4c8e8ef1e1
|
@ -461,6 +461,12 @@ export default class Display {
|
|||
this._target.style.width = width;
|
||||
this._target.style.height = height;
|
||||
}
|
||||
|
||||
if (factor === 1 && this._target.style.imageRendering !== 'pixelated') {
|
||||
this._target.style.imageRendering = 'pixelated';
|
||||
} else if (factor !== 1 && this._target.style.imageRendering !== 'high-quality') {
|
||||
this._target.style.imageRendering = 'auto';
|
||||
}
|
||||
}
|
||||
|
||||
_setFillColor(color) {
|
||||
|
|
|
@ -225,6 +225,7 @@ export default class RFB extends EventTargetMixin {
|
|||
this._canvas.style.margin = 'auto';
|
||||
// Some browsers add an outline on focus
|
||||
this._canvas.style.outline = 'none';
|
||||
this._canvas.style.imageRendering = 'pixelated';
|
||||
this._canvas.width = 0;
|
||||
this._canvas.height = 0;
|
||||
this._canvas.tabIndex = -1;
|
||||
|
|
Loading…
Reference in New Issue