scaleToWindow icon indicating copy to clipboard operation
scaleToWindow copied to clipboard

Jumping Canvas

Open schema0708 opened this issue 7 years ago • 2 comments

Hi,

I'm having a weird issue when resizing the browser for some reason if I resize it the canvas will jump to the top portion of the browser looks like a glitch. I'm using the latest version of PixiJS, please let me know if there's a fix?.

Thanks

schema0708 avatar May 07 '18 05:05 schema0708

I have the same problem. There could be a 30px margin on the top. During resizing, the margin sometimes disappears and sometimes appears, looks like the canvas seemed jumping.

I solve the problem according to this link: https://stackoverflow.com/questions/2489070/how-do-i-remove-the-top-margin-in-a-web-page

there may be some margin-top on other element on the page, add some element without margin, like span, could remove that margin.

jdk137 avatar Feb 21 '19 08:02 jdk137

Maybe it's an affect caused by default browser margins and padding? Maybe try this in your CSS?

* {
  margin: 0;
  padding: 0;
}

kittykatattack avatar Feb 21 '19 10:02 kittykatattack