Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Post questions on how to use or achieve an effect in Inkscape.
outeast
Posts: 2
Joined: Sun Feb 12, 2017 4:24 am

Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby outeast » Sun Feb 12, 2017 4:45 am

First, hello! Just started using Inkscape today, so serious n00b. Also: old dog, have difficulty learning new tricks. Please don't just yell FTFM at me :).

BACKGROUND:
I'm trying to make simple templates for cut-and-fold paper models of buildings. I need to be able to change specific dimensions - for example, making a house longer. This mainly requires resizing rectangles. As long as my rectangles are still square with the canvas, that's dead simple. However, my nets will have some rectangles at angles to each other. I need to be able to resize/stretch these rectangles, too.

ISSUE:
I draw a rectangle, get it to the required size either manually or using the toolbar values, and rotate using transform. Once my rectangle has been rotated, though, I can't grab the corner and resize/stretch it as usual - instead it is boxed by (dunno what else to call it) a transform frame that stays in line with the canvas, not the rectangle. If I try to stretch it, the rectangle distorts. The same goes if I use the toolbar values: they now define the transform box, not the rectangle.

This seems to be a really simple operation, but I've been trying to figure it out for 90 minutes now and made not a whit of progress! As I get more familiar with Inkscape I'm sure I'll learn how to solve such problems, but at the moment there's too much unfamiliar terminology and the help pages are beginning to look like Alice's rabbit hole...

Any help, pointers, links much appreciated.

Outeast
Last edited by outeast on Sun Feb 12, 2017 7:17 am, edited 1 time in total.

theozh
Posts: 437
Joined: Fri Mar 23, 2012 6:30 pm

Re: Resizing a rotated object [n00b question]

Postby theozh » Sun Feb 12, 2017 6:20 am

Hi Outeast, welcome to Inkscape and the forum.

Well, I agree, it's seems not to be straight forward to resize a rotated rectangle in terms of height and width of the rectangle. I assume you don't want to calculate the stretch factor depending on the rotation angle by yourself.
And I assume you simpy want to type in the new height and width.

One way could be:
1. select your rectangle and press Shift+Ctrl+X. The XML Editor will pop up.
2. select the line with height (or width)
3. in the bottom field type in your new value and press the set button

Hope this also works for you.
Maybe there are even better or simpler solutions...

ResizeRotatedRectangle.png
ResizeRotatedRectangle.png (13.23 KiB) Viewed 3182 times
Win7/64, Inkscape 0.92.2

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Resizing a rotated object [n00b question]

Postby brynn » Sun Feb 12, 2017 6:40 am

You can scale to a specific size using Object menu > Transform > Scale

However, it also scales using the bounding box....well, technically the dashed line rectangle is called the selection cue (I've recently been reminded) but we usually call it the bounding box. There is no way to scale a rectangle which has been rotated, by the rectangle's length and width - only by the bounding box or the outer dimensions of the rectangle after its rotated.

But there might be an extension which would scale all the objects at the same time, keeping them all to the same scale, no matter if some objects are rotated or not. I can't remember for sure, but I don't think it ships with Inkscape. You'll need to install it, I think.

Well, look in Extensions menu for Scaling, about 2/3 down the menu. If you don't see it, then go here to download it: https://github.com/Moini/inkscape-realscale-extension/. And here is how to install it: https://inkscape.org/en/learn/faq/#how- ... n-sets-etc

The instructions are pretty clear. But if I recall, it scales everything in the drawing relative to their real size, all at once.

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Resizing a rotated object [n00b question]

Postby Lazur » Sun Feb 12, 2017 6:52 am

Instead of object select, use the node tool. That way you can access the rectangle's handles.
Or better, switch to the rectangle tool. Then you can type in the height and width, without altering the object's scale.

That way you can construct/measure coordinates in a given direction and distance.
-Create rectangle, rotate it, and type in the values.- Remember not to involve the object bounding box transformation handles for scaling if you want to keep things in proportion.

outeast
Posts: 2
Joined: Sun Feb 12, 2017 4:24 am

Re: Resizing a rotated object [n00b question]

Postby outeast » Sun Feb 12, 2017 7:16 am

Thank you all!

theozh, your solution works perfectly. I would *never* have found that just by poking around!

Lazur, I read your reply only after testing theozh's - I'll try it out tomorrow (late here and I'm done in).

Brynn, your extensions pointer is something I'll explore.

I'm really grateful. You guys are tremendous.

theozh
Posts: 437
Joined: Fri Mar 23, 2012 6:30 pm

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby theozh » Sun Feb 12, 2017 7:32 am

@Lazur... yes, thanks! Select the rectangle and click on the rectangle tool and type in new height/width values... so "easy"!
I knew that there must/should be a simpler solution ;-)
Win7/64, Inkscape 0.92.2

Moini
Posts: 3381
Joined: Mon Oct 05, 2015 10:44 am

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby Moini » Sun Feb 12, 2017 9:38 am

Huh? If the rotated rectangles are still rectangles, why not use the rectangle tool for resizing? Am I missing something?
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)

Raspi
Posts: 229
Joined: Fri Oct 21, 2016 12:51 am

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby Raspi » Sun Feb 12, 2017 5:19 pm

I was quite thrilled by theozh solution with the XML editor and was wondering why there isnt a direct functionality until i realized it only works as long as the rectangle is an object and not a path.

Still dont understand what Lazur wants to do with the Node Tool. Using the Node Tool doesnt seem to solve the problem. Whatever way i select nodes, the rectangle gets distorted.

theozh
Posts: 437
Joined: Fri Mar 23, 2012 6:30 pm

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby theozh » Sun Feb 12, 2017 8:53 pm

@Moini, well, afterwards it's "obvious" ;)
In our "defence": if you are fixated on what the tool descripton says "Create Squares and Rectangles (F4)" you do not necessarily expect that you can also edit existing ones. Anyway, for completeness it would be nice if you could also edit the rotation angle of the original rectangle.
Otherwise, I see a problem when you have rotated the rectangle with the rotation handles via mouse by an odd number (e.g. 17.732°). How to rotate such a rectangle back to exactly 0° or a specific angle other than via the XML-Editor?

Another inconsistency: then I am missing this editing possibility with the ellipses tool. How do you change the size of an rotated ellipse by one or both of its main axes?

@Raspi
using the Node Tool might be good if you want the rectangle's corners snap to another point. With this the rotated rectangle will not be skewed as it would be using the scaling handles.
Last edited by theozh on Mon Feb 13, 2017 2:59 am, edited 1 time in total.
Win7/64, Inkscape 0.92.2

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby Lazur » Sun Feb 12, 2017 9:01 pm

Raspi wrote:Still dont understand what Lazur wants to do with the Node Tool. Using the Node Tool doesnt seem to solve the problem. Whatever way i select nodes, the rectangle gets distorted.


Image

Hold Ctrl+Shift for proportional editing and Ctrl alone if you want to resize only on one axis.

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby Lazur » Sun Feb 12, 2017 9:14 pm

theozh wrote:@Moni, well, afterwards it's "obvious" ;)
In our "defence": if you are fixated on what the tool descripton says "Create Squares and Rectangles (F4)" you do not necessarily expect that you can also edit existing ones. Anyway, for completeness it would be nice if you could also edit the rotation angle of the original rectangle.
Otherwise, I see a problem when you have rotated the rectangle with the rotation handles via mouse by an odd number (e.g. 17.732°). How to rotate such a rectangle back to exactly 0° or a specific angle other than via the XML-Editor?

Another inconsistency: then I am missing this editing possibility with the ellipses tool. How do you change the size of an rotated ellipse by one or both of its main axes?

@Raspi
using the Node Tool might be good if you want the rectangle's corners snap to another point. With this the rotated rectangle will not be skewed as it would be using the scaling handles.



In other programs the approach is a bit different. For example in blender you can rotate objects, the rotation angle is preserved in a gui box, and you have to manually apply it if you don't want touse that value further on. My guess is it's the xml editor then the only way to remove the transformation.
If it wasn't only rotated then it will have a transformation matrix that represents scaling, skewing and translating as well in one so no guarantee removing it would bring you the result expected.

Using guides and snapping can help rotating back manually though.


Resizing an ellipse works similarly as resizing the rectangle. Pull the ellipse tool's square handles to resize it in one axis direction.
Proportional scaling is not present as I can see Ctrl draws you a circle from the ellipse.

Raspi
Posts: 229
Joined: Fri Oct 21, 2016 12:51 am

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby Raspi » Sun Feb 12, 2017 9:23 pm

Lazur wrote:Hold Ctrl+Shift for proportional editing and Ctrl alone if you want to resize only on one axis.

Okay, i was thinking of a path, not a rectangular object.
Most of the time you have to convert to paths pretty early in the workflow.

theozh
Posts: 437
Joined: Fri Mar 23, 2012 6:30 pm

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby theozh » Sun Feb 12, 2017 9:32 pm

Lazur wrote:Resizing an ellipse works similarly as resizing the rectangle. Pull the ellipse tool's square handles to resize it in one axis direction.

Oh, I see. However, it's getting difficult if you want to set specific values instead of mouse drag&drop precision...
Win7/64, Inkscape 0.92.2

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby Lazur » Sun Feb 12, 2017 9:40 pm

Hmm it may call for a feature request, not sure why you cannot change those in the ellipse tool's settings.
Rx and ry are present in the xml editor.

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby brynn » Fri Feb 17, 2017 1:32 am

Lazur wrote:Hmm it may call for a feature request, not sure why you cannot change those in the ellipse tool's settings.
Rx and ry are present in the xml editor.


If you're still talking about rectangles, you can set Rx and Ry in Rectangle tool control bar. (As Moini mentioned.)

But you have to use the Rectangle tool, rather than Node tool. It seems like sort of a fluke that one can edit the rectangle shape by using the Node tool.

Moini
Posts: 3381
Joined: Mon Oct 05, 2015 10:44 am

Re: Resizing a rotated object [n00b question] [SOLVED! Thanks!!]

Postby Moini » Fri Feb 17, 2017 3:00 am

As a workaround, for an unrotated ellipse, width and height values can be used. The different radii cannot currently be set directly, that's right.
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)


Return to “Help with using Inkscape”