shape rotation
shape rotation
How do i take a shape that has a random rotation and make it perfectly straight up and down on screen? 90 degrees? Do i use snaps? Align tools? If I take a rectangle that has been rotated to a random degree how do i get it straight again? More specifically I am trying to draw a 5 pointed star with one point at the top so it is oriented perfectly straight up and down - evenly spaced right to left from center if that makes sense ... my star shape defaults with a slight rotation so using cnrl to rotate in increments is off (none fall at 90d/straight up and down)
- Espermaschine
- Posts: 892
- Joined: Thu Jun 05, 2014 9:10 pm
Re: shape rotation
I use a guide and snap to node/handle.
For the star hold down the Ctrl key while you draw the star, pulling the cursor up. Depending on the rotation steps you have under Properties, the top will be perfectly straight.
You get the perfect star when the Spoke Ratio is at 0.383, i think. But again, you can use a guide to help make the handle snap to a guide.
http://tavmjong.free.fr/INKSCAPE/MANUAL ... Stars.html
For the star hold down the Ctrl key while you draw the star, pulling the cursor up. Depending on the rotation steps you have under Properties, the top will be perfectly straight.
You get the perfect star when the Spoke Ratio is at 0.383, i think. But again, you can use a guide to help make the handle snap to a guide.
http://tavmjong.free.fr/INKSCAPE/MANUAL ... Stars.html
Re: shape rotation
To do that, the object needs to have at least 1 straight side that can be used for alignment, or in the case of the 5 point star, it has 2 nodes that will lie horizontal to each other.
However, there's a problem with the 5 point star, to my understanding, and that is, it's not radially symmetrical....at least the Inkscape default star. It doesn't fit in a square. So its rotation center is in a different place, depending on the angle you dragged the mouse when you drew it (at least that's my understanding, but I could be wrong).
So to draw a 5 point star, making sure 2 points of the star lie horizontally, I hold the Ctrl key while I draw. That means the mouse will only move perfectly in a vertical or horizontal direction. If you hold the Ctrl key and drag downwards, it draws an upsidedown star. So then you can just flip it vertically, and have the star aligned horizontally. Or draw it by dragging upwards.
If it's a star that's already been drawn, and perhaps heavily modified, so it would not be easy to re-draw, I'm not sure how to get it rotated around so that the bottom 2 points lie horizontal to each other. Possibly snapping the rotation center to the object's center, but I'm not positive that would be a mathematically precise result. I know I've tried in the past, but I get so confused with the non-symmetrical shape, I usually just give up, and draw the star using Ctrl.
(Oops, sorry Esper. While I was writing my post, you were apparently editing yours!)
However, there's a problem with the 5 point star, to my understanding, and that is, it's not radially symmetrical....at least the Inkscape default star. It doesn't fit in a square. So its rotation center is in a different place, depending on the angle you dragged the mouse when you drew it (at least that's my understanding, but I could be wrong).
So to draw a 5 point star, making sure 2 points of the star lie horizontally, I hold the Ctrl key while I draw. That means the mouse will only move perfectly in a vertical or horizontal direction. If you hold the Ctrl key and drag downwards, it draws an upsidedown star. So then you can just flip it vertically, and have the star aligned horizontally. Or draw it by dragging upwards.
If it's a star that's already been drawn, and perhaps heavily modified, so it would not be easy to re-draw, I'm not sure how to get it rotated around so that the bottom 2 points lie horizontal to each other. Possibly snapping the rotation center to the object's center, but I'm not positive that would be a mathematically precise result. I know I've tried in the past, but I get so confused with the non-symmetrical shape, I usually just give up, and draw the star using Ctrl.
(Oops, sorry Esper. While I was writing my post, you were apparently editing yours!)
Basics - Help menu > Tutorials
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
- Espermaschine
- Posts: 892
- Joined: Thu Jun 05, 2014 9:10 pm
Re: shape rotation
brynn wrote:If it's a star that's already been drawn, and perhaps heavily modified, so it would not be easy to re-draw, I'm not sure how to get it rotated around so that the bottom 2 points lie horizontal to each other.
snap the rotational center to one node, create a guide that snaps to this node and then rotate the star until the opposite node snaps to the guide as well ?
Re: shape rotation
Oh yeah, that would work!
Basics - Help menu > Tutorials
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Re: shape rotation
JanGB wrote:How do i take a shape that has a random rotation and make it perfectly straight up and down on screen?
If the shape is so random, you can trace a path over it you want to be horizontal after rotation (two clicks with the pen tool),
convert it to a guide (Shift+G), double click it and copy the rotation value,
then select the original object, and in the transformation panel (Shift+Ctrl+M) set the same rotation in the opposite direction.
If I take a rectangle that has been rotated to a random degree how do i get it straight again?
Rectangles keep their transformations stored, by the xml (Shift+Ctrl+X) editor you can edit rotations/transformation matrixes out, might worth a try.
More specifically I am trying to draw a 5 pointed star with one point at the top so it is oriented perfectly straight up and down - evenly spaced right to left from center if that makes sense ... my star shape defaults with a slight rotation
If you hold down Ctrl at drawing, the star will be snapped to angles defined in the preferences, just as with rotation.
There is not really a default rotation, but if you happen to add a slight rotation with Ctrl, you should be able to handle it by rotating and holding Ctrl after.
- Espermaschine
- Posts: 892
- Joined: Thu Jun 05, 2014 9:10 pm
Re: shape rotation
Lazur URH wrote:If the shape is so random, you can trace a path over it you want to be horizontal after rotation (two clicks with the pen tool),
convert it to a guide (Shift+G), double click it and copy the rotation value,
then select the original object, and in the transformation panel (Shift+Ctrl+M) set the same rotation in the opposite direction.
Genius !
Re: shape rotation
^Thanks!
Learned that trick here (of measuring angles), though I cannot recall nor couldn't find it by searching where exactly or when.
But here is something I have never read before by Grobe:
So the pen tool can even be left out of the process, by simply pulling a guide from the rulers and rotating it by holding Shift.
Even though three digit transformation is not as exact as snapping.
Learned that trick here (of measuring angles), though I cannot recall nor couldn't find it by searching where exactly or when.
But here is something I have never read before by Grobe:
Grobe wrote:Workaround:
You need a simple calculator for this.
1
Draw the line with an angle.
2
Make sure "Snap to cusp node" si activated.
3
Put a guideline in parallell with both line segments. Tips: you can adjust it's angle by holding Shift button down while adjust with mouse.
4
Double click on each guideline to get it's absolute angle. Then use a calculator and calculate the difference in angle.
Alternative way: If you have given absolute coordinates, then Geogebra is a good tool to measure angles.
So the pen tool can even be left out of the process, by simply pulling a guide from the rulers and rotating it by holding Shift.
Even though three digit transformation is not as exact as snapping.
Re: shape rotation
Lazur URH wrote:If the shape is so random, you can trace a path over it you want to be horizontal after rotation (two clicks with the pen tool),
convert it to a guide (Shift+G), double click it and copy the rotation value,
then select the original object, and in the transformation panel (Shift+Ctrl+M) set the same rotation in the opposite direction.
I hadn't though about converting it to a guide, that's clever! But I guess that you could also use the measurement tool instead? That would save you a few clicks, as this gives the angle directly. The accuracy will still be limited by the number of digits, so for absolute accuracy use snapping while rotating.
Re: shape rotation
dvlierop wrote:measurement tool
Haven't tested, does it come with a copy function too?
Memorizing something like 37,826° when measured, then typing the numbers to the transform panel doesn't really make it faster in practice otherwise.
Re: shape rotation
Good point, that is a downside of the measurement tool.
I think we should file a feature request for that. It would be cool if we could somehow select one of the measurements and copy that, but I don't know how exactly that should work GUI-wise...
I think we should file a feature request for that. It would be cool if we could somehow select one of the measurements and copy that, but I don't know how exactly that should work GUI-wise...