Print at Dec 16, 2025, 9:58:57 AM

Posted by baurat at Jan 15, 2012, 5:58:24 PM
Strange behaviour when zooming
I have been working with SH for some days, and now I am noticing a strange behaviour when zooming in:
For example, an item (furniture object or a wall) is selected and in the middle of the screen at (36, 36) [I have a big model with some of the neighbour houses].
When clicking at the zoom in (or ctrl+mouse wheel up) to zoom in, the visible area moves and the middle of the screen is now at (-104, 35).
So it seems the x-axis is shifted very much, depending on the x-dimension of the complete model (the bigger the model is, the more the view is shifted).
You can reproduce that: just draw a square 2mx2m and zoom - nop problem. Now, draw a 20m wall to the right side, draw another square at the end and then zoom in again - now the cursor gets lost somewhere between the two squares.

So I propose the following:
- when zooming in with ctrl+mousewheel, the new view is centered at the coordinates of the mouse pointer
- when zooming in with the icon: the center of the old will also be the center of the new view

What do you think?