Faster graph zoom by using a snapshot-preview#1728
Open
elidiot18 wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi,
Browsing the graph of a large database can be tedious because each tiny bit of zoom requires to rerender all visible objects. In this commit I display a raster snapshot temporarily and render the real canvas only when the user has finished zooming (400ms need to pass without a new mouse wheel).
Note that I also changed the zooming anchor to mouse-centered because it feels more natural to me but this is a personal choice. I also updated the shift+click zooming.
It makes it easier to work with large dbs but introduces some pixelisation for normal size dbs, maybe it should only be activated if the db is detected as "large".
Note that the same should could also be done for rotating the graph.
Enregistrement.de.l.ecran.2026-07-02.204330.mp4