Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zooming in the tileset editor simply resizes the image instead of resizing and panning to the mouse like in the map editor #2039

Closed
Larkenx opened this issue Dec 1, 2018 · 5 comments
Assignees
Labels
Projects
Milestone

Comments

@Larkenx
Copy link

@Larkenx Larkenx commented Dec 1, 2018

Here's a gif showing the difference between the map editor zooming vs tileset zooming. I don't know if it's a common use case, but my tileset image is just one huge image, so I am very often zooming and panning around the map. Being able to zoom in with the mouse would be immensely helpful for my workflow, because otherwise if I zoom while I am looking at a particular area of the tileset, I have to rescroll over.

2018-11-30_23-07-01

@Larkenx Larkenx changed the title Zooming in the tileset editor simply changes the size instead of panning to the mouse like in the map editor Zooming in the tileset editor simply changes resizes the image instead of resizing and panning to the mouse like in the map editor Dec 1, 2018
@Larkenx Larkenx changed the title Zooming in the tileset editor simply changes resizes the image instead of resizing and panning to the mouse like in the map editor Zooming in the tileset editor simply resizes the image instead of resizing and panning to the mouse like in the map editor Dec 1, 2018
@bjorn

This comment has been minimized.

Copy link
Owner

@bjorn bjorn commented Dec 1, 2018

Yeah, this has bothered me ever since I implemented zooming for tileset views. The reason is mostly that the map view is implemented using a QGraphicsView whereas the tileset view is implemented using QTableView. The implementations of the zooming are totally different, and it wasn't easy to get the table view to zoom from the mouse cursor (zooming even resets the selection...).

It is definitely something to try improving though. Either by finding some approach that makes this functionality working with a QTableView, or by reimplementing the tileset view based on a QGraphicsView. I've been considering the latter, because it would bring also other advantages.

@Bobjt

This comment has been minimized.

Copy link

@Bobjt Bobjt commented Apr 1, 2019

At least you have a working solution with QGraphicsView . Are you not able to use it on tilesets?

@bjorn

This comment has been minimized.

Copy link
Owner

@bjorn bjorn commented Apr 2, 2019

@Bobjt The functionality is easy with a QGraphicsView, but rewriting the tileset view based on QGraphicsView is not trivial and may not be ideal either because it would not give us dynamic wrapping, which is another missing feature that would be quite useful for image collection tilesets.

I'll try have a go soon at writing a QGraphicsView based tileset view, that will only be used for tileset image based tilesets for now.

@Bobjt

This comment has been minimized.

Copy link

@Bobjt Bobjt commented Apr 2, 2019

Knowing is only half the battle, ay Bjorn? :) Cool! I'm not sure but I think image-based tilesets are what I'm using. Crossing my fingers the change isn't too grueling after all.

@bjorn bjorn added this to Tiled 1.3 (next feature release) in Roadmap May 31, 2019
@bjorn bjorn self-assigned this Sep 4, 2019
@bjorn bjorn added the usability label Sep 4, 2019
@bjorn bjorn closed this in 667d396 Sep 4, 2019
Roadmap automation moved this from Tiled 1.3 (next feature release) to Recently Completed Sep 4, 2019
@bjorn

This comment has been minimized.

Copy link
Owner

@bjorn bjorn commented Sep 4, 2019

So yeah, I've found a way without rewriting the whole thing, and at the same time even fixed the selection reset when changing the scale!

@bjorn bjorn added this to the Tiled 1.3 milestone Sep 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Roadmap
  
Recently Completed
3 participants
You can’t perform that action at this time.