Skip to content

"Reset to Center" and "Zoom to Drawing" Functions#264

Open
tafode wants to merge 2 commits intombrlabs:mainfrom
tafode:feature/zoom
Open

"Reset to Center" and "Zoom to Drawing" Functions#264
tafode wants to merge 2 commits intombrlabs:mainfrom
tafode:feature/zoom

Conversation

@tafode
Copy link
Contributor

@tafode tafode commented Mar 22, 2024

As described in #233 I have created two new buttons in the toolbar. One for resetting the camera to center/home (position 0/0 with Zoom 1) and one that zooms out so that the whole drawing is shown.

image

I'm not sure if the Icons are clear enough. So I'm open for suggestions. Additionally they don't match exactly the style of the others.

Known issues with this solution:

  • If it would be necessary to zoom out further than 100 to see the whole drawing, it stops at the limit of 100 and only shows a part of the drawing.
  • In some cases, if the window is very small, a small part of the drawing may be hidden under the toolbar when zoom to drawing.

@tafode tafode closed this Aug 31, 2024
@tafode tafode reopened this Sep 2, 2024
@tafode
Copy link
Contributor Author

tafode commented Sep 2, 2024

I'm not sure if this feature is still needed/wanted, but I have re-implemented the logic, so that it works now with the new Godot 4.3 version.

@mkh-user
Copy link
Contributor

mkh-user commented Oct 3, 2025

It isn't better to move these functions to status bar labels like other applications with changing them to buttons?
image

@tafode
Copy link
Contributor Author

tafode commented Oct 3, 2025

@mkh-user would also be an option, but I'm not sure the feature willl be included at all. The Pull Request is 1.5 years old and so far I guess there were more important things. 🙂

But I'm open to your suggestion. Maybe @mbrlabs can add his thoughts.

@mkh-user
Copy link
Contributor

mkh-user commented Oct 3, 2025

Yes, I know and I agree. 👍
But there have only been 8 commits in the last month (four by yourself 😅), so I don't think the schedule is that tight. If we have @mbrlabs' opinion, maybe I can help too if you are busy.

@tafode
Copy link
Contributor Author

tafode commented Oct 3, 2025

I didn't mean to say that I don't have time for it. I just wanted to say that there were more important features that were reviewed/merged.

It shouldn't be a problem for me to move the functions to the status bar, I just want to know from the maintainer first whether the functions are wanted at all and, if so, where. Before I invest more of my time.

If you have the time and desire to help with the project, you are more than welcome to go through the issues, choose something, and implement it.

@mkh-user
Copy link
Contributor

mkh-user commented Oct 3, 2025

So I think we have the same opinion. My main reason for my first message was to check on whether this feature was going to be added or removed, given that there is still an open issue regarding this.

Thanks for the guidance on how to implement the issues, see #355 for this one 🙃

@mbrlabs
Copy link
Owner

mbrlabs commented Oct 4, 2025

I'm not opposed to adding these features, but i don't think the toolbar is the right place because you probably won't use these enough to justify such a prominent place. It's also kind of hard to pick icons for these that make sense.

I thought they could maybe go into the menu somewhere but i never thought about the status bar as buttons. Good idea, i would merge that! However please make sure that they are transparent and look like the lables right now. I would also add a bit of a hover effect (maybe a faint border outline) and a "Reset" tooltip.

@tafode
Copy link
Contributor Author

tafode commented Oct 5, 2025

So, now the reset is triggered by the buttons in the statusbar, I removed the resetting of the zoom to 1 when clicking on position, as this makes no sense in the current implementation. Also re-named everything to be consistent resetting position / zoom.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants