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

Properly remember snapping options per-project #74682

Merged
merged 1 commit into from
Apr 3, 2023

Conversation

KoBeWi
Copy link
Member

@KoBeWi KoBeWi commented Mar 9, 2023

This PR makes snapping options properly remembered and re-used. No more resetting the grid to 8x8 for no reason, the editor will remember the settings you set last time and use it for each new scene (both for 2D and 3D.
TextureRegionEditor will also remember its snapping settings.

Closes godotengine/godot-proposals#1348 and closes godotengine/godot-proposals#4362 (if these options are remembered properly within the project then a setting isn't really necessary anymore, but idk)

Edit by Akien: Confirmed this is a sufficient fix for those proposals, so changed to closing keywords.

@KoBeWi KoBeWi added this to the 4.x milestone Mar 9, 2023
@KoBeWi KoBeWi requested a review from a team as a code owner March 9, 2023 20:15
@akien-mga akien-mga requested a review from Calinou March 9, 2023 20:34
@oxeron
Copy link

oxeron commented Mar 19, 2023

Will this feature be back ported to 3.5 branch ?

@akien-mga akien-mga modified the milestones: 4.x, 4.1 Apr 3, 2023
@akien-mga akien-mga merged commit 632491f into godotengine:master Apr 3, 2023
@akien-mga
Copy link
Member

Thanks!

@KoBeWi KoBeWi deleted the snappy_snapping branch April 3, 2023 14:22
@YuriSizov
Copy link
Contributor

Cherry-picked for 4.0.3.

@YuriSizov
Copy link
Contributor

Will this feature be back ported to 3.5 branch ?

If someone implements it :) It should be doable.

@capnm
Copy link
Contributor

capnm commented Apr 7, 2023

@YuriSizov I don't see why (please double check) but this commit causes looping in

while ((transform * ruler_transform).get_scale().x < 50 || (transform * ruler_transform).get_scale().y < 50) {
ruler_transform.scale_basis(Point2(2, 2));
}

See #75749
Reverting it fixed for me the issue at current tip.

@YuriSizov
Copy link
Contributor

Thanks for looking into it, let's keep the discussion to one place and continue it in your bug report.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add an editor setting to control the TextureRegion editor step value Add Default Settings for 2D Snap Step
5 participants