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

Draw circle from the corner instead of the center? #125

Open
winteriscariot opened this issue Sep 26, 2024 · 1 comment
Open

Draw circle from the corner instead of the center? #125

winteriscariot opened this issue Sep 26, 2024 · 1 comment

Comments

@winteriscariot
Copy link

In most graphics and drawing apps, circles/ellipses are usually drawn from the corner, not the center; usually a modifier (ctrl or shift i think usually) will expand from the center

What would it take to get the circle to start from the corner, like the rectangle? I find it's easier to circle the things I want that way (it's how swappy works, but i find satty a better app overall)

Thanks!

@gabm
Copy link
Owner

gabm commented Dec 30, 2024

What would it take to get the circle to start from the corner, like the rectangle? I find it's easier to circle the things I want that way (it's how swappy works, but i find satty a better app overall)

a bit of math :) the graphics library (femtovg) wants to draw circles with "center - radius".. you need to calculate the top left position. Its not complicated - go ahead, if you want to give it a shot.

Modifier keys are also available, so we can use those as you described.

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

No branches or pull requests

2 participants