Closed ollimeier closed 2 weeks ago
An better solution would be to do
mouseRect = rectangle.normalizeRect(rectangle.roundRect({ ... }))`
At line 53. This fixes the problem right at the source, and avoids having to possibly reverse twice in the case of ctrlKey.
It could be that this makes the default winding direction the opposite to what it is now. But that could be fixed by inverting the ctrlKey reverse logic.
An better solution would be to do
mouseRect = rectangle.normalizeRect(rectangle.roundRect({ ... }))`
At line 53. This fixes the problem right at the source, and avoids having to possibly reverse twice in the case of ctrlKey.
It could be that this makes the default winding direction the opposite to what it is now. But that could be fixed by inverting the ctrlKey reverse logic.
OK, works well. But in that case, the starting point is always at the same position (left bottom corner). I liked that you can have control over the starting point depending where you start dragging. But that's probably just me???
@justvanrossum The proposed change causes some negative side effects to other functionalities like 'from center' or 'square'. Is there something I do wrong? Or should I rework other parts as well? Please see the following screen recording:
https://github.com/googlefonts/fontra/assets/21055547/6633c39a-baca-4e61-8680-cc91c7fe2e73
I liked that you can have control over the starting point depending where you start dragging.
You are entirely right, I didn't think of that. Forget my suggestion: your solution is good as it is.
I liked that you can have control over the starting point depending where you start dragging.
You are entirely right, I didn't think of that. Forget my suggestion: your solution is good as it is.
Is this an approval? May I merge it?
Fixes #1455
I tested it with the rectangle as well as with the circle + ctrlKey. The 'default' winding direction is counter clockwise.