How do I move a sketch in an axis?

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
chrisb
Veteran
Posts: 54197
Joined: Tue Mar 17, 2015 9:14 am

Re: How do I move a sketch in an axis?

Post by chrisb »

I have added some hopefully clarifying words to the documentation https://www.freecadweb.org/wiki/Part_At ... ent_Offset.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: How do I move a sketch in an axis?

Post by GeneFC »

tonydiethelm2 wrote: Thu Mar 14, 2019 5:20 am I linked to the bug description. There's an example... You apparently didn't read what I wrote.
My reading comprehension is fine, thank you.

I responded to your "example.fcstd" file. There was no rotation, period.

I find it rather amazing that folks like you seem to think it is OK to come on this forum and flame everybody who tries to help. Good luck on learning all the nuances on your own.

I am out of here.

Gene
User avatar
bejant
Veteran
Posts: 6075
Joined: Thu Jul 11, 2013 3:06 pm

Re: How do I move a sketch in an axis?

Post by bejant »

tonydiethelm2 wrote: Thu Mar 14, 2019 5:20 am Ok, well, this is a bit silly. I linked to the bug description. There's an example... You apparently didn't read what I wrote.

Tweak one along the axis using the attachment offset. They'll rotate.

This is a known bug. Why am I fighting y'all on this?
To me is seems that everyone else is explaining, trying to help you understand, while you are the person being argumentative.

You apparently haven't understood the replies here. I think the reply from NormandC explains it pretty well.


tonydiethelm2 wrote: Thu Mar 14, 2019 5:20 am Out of curiosity, how do I fill out a feature request?
Don't do that until you discuss the perceived issue in the forum first, and have a consensus that the issue is actually a bug in FreeCAD. Too many times people put things in the bug tracker that are actually user error.

tonydiethelm2 wrote: Thu Mar 14, 2019 2:40 am Ok, so.... Y'all are saying that to move a sketch on the XZ plane out on the global Y axis, I need to change the Z axis
Yes. To see the Local Coordinate System for one of your Sketches, select it in the history tree and choose the "Create new local coordinate system" tool. It will place a color-coded and labeled axis cross at the local origin of the chosen Sketch, as shown in the image from GeneFC.

tonydiethelm2 wrote: Thu Mar 14, 2019 2:40 am Ok, so.... Y'all are saying that to move a sketch on the XZ plane out on the global Y axis, I need to change the Z axis.
Yes, because you created a LCS on the XZ Plane for each of your Sketches:
20190314a.png
20190314a.png (31.79 KiB) Viewed 1415 times


So to move each in the global Y direction you need to change the local Z coordinate.


tonydiethelm2 wrote: Thu Mar 14, 2019 2:40 am Change an offset. The rectangles change their orientation for me. According to the bug documentation, that's only visual, not real.... and a recompute is supposed to fix that. And it does for me.
The visual issue is known and I think (but am not certain) there already was a ticket for that, which existed before your ticket.

tonydiethelm2 wrote: Thu Mar 14, 2019 2:40 am But I'm getting sick of recomputes, and sick of missing something and fiddling with something that's visually wrong and doesn't need to be fiddled with.
The visual issue is intended to be fixed. Until someone volunteers the fix you might want to try and understand what people here have been trying to explain to you.

tonydiethelm2 wrote: Thu Mar 14, 2019 2:40 am I don't want to argue about bugs, I just want to move my sketch without a hassle.
Again, you need to re-read and understand the help that people have already offered. Until that happens you are causing your own hassle.

I see GeneFC posted while I was writing this and doing other things...

=====


Edit: Quite fitting for pi day... posted at 3:14 0n 3-14...

20190314-HappyPiDay.png
20190314-HappyPiDay.png (29.95 KiB) Viewed 1403 times

Woo hoo!! :lol:
User avatar
bejant
Veteran
Posts: 6075
Joined: Thu Jul 11, 2013 3:06 pm

Re: How do I move a sketch in an axis?

Post by bejant »

I had forgotten about this, and am not sure if this was mentioned before in this thread (TLDR again), but to avoid the Local Coordinate System of your Sketches you can detach each from the XZ Plane. Here's how:
  • In the Part Design WB click a Sketch in the history tree to select it.
  • From the Part Design pull-down menu (top row of the FreeCAD window) choose Reorient Sketch.
  • In the pop-up window click the Yes button to confirm that you want to detach it.
  • In the next pop-up window click the Cancel button to keep the Sketch wherever it exists in the 3D space.
Now you can move the Sketch by global coordinates, and after doing that to the first Sketch, the Dependency Graph looks like this (compare with the DG in my reply directly above):
20190316b.png
20190316b.png (29 KiB) Viewed 1396 times

Repeat for the other two Sketches if you like.

OS: Ubuntu 18.04.2 LTS
Word size of OS: 32-bit
Word size of FreeCAD: 32-bit
Version: 0.18.16000 (Git)
Build type: Release
Branch: master
Hash: 337c9c936f4c686fd476c5eeb3397d0d09f6b258
Python version: 2.7.15rc1
Qt version: 5.9.5
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/UnitedStates (en_US)

blue = edit (I had unknowingly either omitted or deleted a key word)
Last edited by bejant on Mon Mar 18, 2019 1:06 pm, edited 1 time in total.
tonydiethelm2
Posts: 42
Joined: Fri Oct 19, 2018 5:46 pm

Re: How do I move a sketch in an axis?

Post by tonydiethelm2 »

GeneFC wrote: Thu Mar 14, 2019 2:56 pm
tonydiethelm2 wrote: Thu Mar 14, 2019 5:20 am I linked to the bug description. There's an example... You apparently didn't read what I wrote.
Gene... It's a well known, documented, and discussed bug. If you open the file, there won't be any rotation. I specifically said what caused the rotation. I told you how to cause it.

Would you like a screencap? It doesn't really matter at this point I suppose....

I'm not trying to flame people. This is easily reproducible. You didn't read what I wrote.

It's fine man, but I'm not an asshole being an asshole to people trying to help me. I'm a guy trying to make a ukulele for my daughter and climbing a steep learning curve. And having my sketches rotate on me was throwing me for a loop.

https://freecadweb.org/tracker/view.php?id=3861

Here's the link I originally posted detailing exactly what happens. Don't trust me. Trust your own people. And maybe don't be so quick to judge...
Last edited by tonydiethelm2 on Mon Mar 18, 2019 3:33 am, edited 1 time in total.
tonydiethelm2
Posts: 42
Joined: Fri Oct 19, 2018 5:46 pm

Re: How do I move a sketch in an axis?

Post by tonydiethelm2 »

chrisb wrote: Thu Mar 14, 2019 9:11 am I have added some hopefully clarifying words to the documentation https://www.freecadweb.org/wiki/Part_At ... ent_Offset.
Thanks, that does help. Thank you.
tonydiethelm2
Posts: 42
Joined: Fri Oct 19, 2018 5:46 pm

Re: How do I move a sketch in an axis?

Post by tonydiethelm2 »

bejant wrote: Thu Mar 14, 2019 3:14 pm To me is seems that everyone else is explaining, trying to help you understand, while you are the person being argumentative.
I'm editing this for.... I rambled.

I'm incredibly grateful for the help I'm receiving here. ChrisB in particular.

I asked for help working around a visual bug. I linked the FreeCAD bug tracker link for the bug. It's a real bug. I got back
"It's all you, there's no bug". That's frustrating, since I linked y'all's own bug report.

I did not get that attachment offset worked relative to the plane created for my sketch. It's non intuitive, but sure, Ok. I get that. Understanding fixed. But that wasn't my problem. There's no argument there. I was/am searching for a workaround listed in the bug description in the tracker.

The visual rotation of the sketches is real.

And apparently I just need to manage it.... or, as someone else in a different thread pointed out, don't use the attachment offsets. Use datum planes. which I'm still poking and prodding.

Your post about using reorient sketch? I'm poking that too.

I'm not trying to argue with folks. But being told there's no bug when I link the bug is.... It's frustrating man.

Is expressing that "argumentative"? What would you like me to do?
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: How do I move a sketch in an axis?

Post by GeneFC »

Against my better judgment I will reply. Sorry for the long quotes, but it seems necessary. Emphasis added.
tonydiethelm2 wrote: Mon Mar 18, 2019 3:01 am I'm not trying to argue with folks. But being told there's no bug when I link the bug is.... It's frustrating man.

Is expressing that "argumentative"? What would you like me to do?
My post that seems to get you a bit torqued was:
GeneFC wrote: Thu Mar 14, 2019 3:30 am All three of your rectangles are parallel. There is no rotation at all. If there really was a bug (questionable) in the references in your first post it is unrelated to the effect your are seeing.

As explained above, the offset of a sketch is based on the local coordinate system for the sketch, not some global coordinate system. Sketches are planar (two-dimensional), and they exist in the x-y plane of their local coordinate system. If you want to move a sketch along a direction normal to its plane, that is the z-direction.

A recent feature in FreeCAD 0.18.xxxx offers display of local coordinate systems for objects. This image shows the LCS for your example file.


Capture.PNG


Your example file shows correct behavior. Like it or not, that is the way FreeCAD works.

Gene
This was in direct response to your preceding post:
tonydiethelm2 wrote: Thu Mar 14, 2019 2:40 am
Here's an example. Open it up, it's just a bunch of rectangles. Change an offset. The rectangles change their orientation for me. According to the bug documentation, that's only visual, not real.... and a recompute is supposed to fix that. And it does for me. But I'm getting sick of recomputes, and sick of missing something and fiddling with something that's visually wrong and doesn't need to be fiddled with.

I have no idea why my example rectangle is negative in the "Z" Y direction, relative to the unchanged rectangle.

All I want to do is use loft to create a simple guitar neck along the Y axis. Argh. This should be the easiest thing in the world.

The bug report says there's a better way to do it. If there is, does anyone know? I don't want to argue about bugs, I just want to move my sketch without a hassle.
I opened your example, it was indeed a bunch of rectangles. I changed offsets. The rectangles moved but did *not* rotate. I then showed the local coordinate systems.

By the way, the "questionable" remark was based on the comments from wmayer in the tracker, not from my independent analysis. (If you don't know who wmayer is you may want to dig in a bit.)

I am not sure what else you were expecting. I did not say you were stupid; I said the rectangles did not rotate. There may or may not be a "bug", but if there is one it did not show up in your example. I have no idea what else you may have been trying; I worked with the example you posted.

Gene
tonydiethelm2
Posts: 42
Joined: Fri Oct 19, 2018 5:46 pm

Re: How do I move a sketch in an axis?

Post by tonydiethelm2 »

GeneFC wrote: Mon Mar 18, 2019 7:51 pm Against my better judgment I will reply. Sorry for the long quotes, but it seems necessary. Emphasis added.
Well, I do appreciate your reply, and I have to admit I'm pulling out my hair here and it's probably making me stupid crabby.

I made sure those rectangles rotated for me before I posted that. Maybe you're rocking a different version of FreeCAD than I am? Maybe you got lucky? I don't know. It doesn't really matter. I'm working around it.

I really do appreciate the help here. I don't take it for granted.

I'm trying to grok using planes instead of offset attachments, which might be a decent workaround. We'll see.
tonydiethelm2
Posts: 42
Joined: Fri Oct 19, 2018 5:46 pm

Re: How do I move a sketch in an axis?

Post by tonydiethelm2 »

oops, delete.
Last edited by tonydiethelm2 on Tue Mar 19, 2019 4:35 am, edited 1 time in total.
Post Reply