[BUG][EDITOR] Displayed area is wrong size after resizing level.

Started by namida, May 25, 2019, 09:39:14 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

namida

I cannot consistently reproduce this, but I've seen it happen multiple times now. I will mention the common factors between cases where I've noticed this to occur, in case it helps.

Upon resizing the level's horizontal size, via typing the number into the input box, sometimes, the actual on-screen display of the level will be drawn as if the level was slightly narrower than it actually is - I'd estimate about 8px on each side (left and right) is cut off. Vertical size is not affected. Anything that causes the level image to be redrawn again (modifying, zooming) will fix this.

EDIT: On further observation, I have noticed that while sometimes it's both sides, sometimes it's only one side or the other. It always seems to be 8px-ish, though (same amount every time, I think, just not sure if it is exactly 8px). EDIT: And to clarify, I'm meaning 8px of level pixels, not screen pixels.

This is a purely visual glitch; the level's data is indeed the correct size.

Other things that may be relevant:
- This is happening in the current stable release version of the editor, not a built-from-source copy.
- In all cases where this has occurred, no pieces have existed completely outside the new boundaries.
- This has occurred both in cases where the screen start would be outside the new boundaries, and where it would be inside it.
- I haven't seen it occur when resizing via clicking the increase / decrease arrow buttons next to the input; only when typing directly.
- I haven't done any vertical resizing since noticing this bug, so cannot say for sure if it can happen vertically too or not.

EDIT: I have now seen this occur upon loading a level, too.
My projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)
Non-Lemmings: Commander Keen: Galaxy Reimagined (a Commander Keen fangame)

Nepster

Wild guess: The editor cannot decide between displaying scroll bars or not. It first decides that it needs a vertical scroll bar, shrinks the level area accordingly, then notices that it actually doesn't need the scroll bar and forgets to enlarge the level area again.

namida

I can't really confirm or rule out anything, but that doesn't sound right based on the symptoms, especially that it's occurred with levels nowhere near needing a scroll bar - unless perhaps it's calculating based on the wrong zoom level.

Here's a mockup screenshot that gives an example of what's happening. The top is the actual level map. The bottom is a mockup (therefore: probably not the exact size that's actually happening with the bug) of what kind of thing I've been seeing - note that in this image I've mocked-up the bug happening on both sides of the level, but I've seen all three possible cases - left-only, right-only and both sides. Also note that while this screenshot is taken in an all-experimental-features build, I've seen this issue in the stable version too.
My projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)
Non-Lemmings: Commander Keen: Galaxy Reimagined (a Commander Keen fangame)