FIX LINES TO SNAP POINTS...

FIX LINES TO SNAP POINTS...

marko_ribar
Advisor Advisor
1,192 Views
6 Replies
Message 1 of 7

FIX LINES TO SNAP POINTS...

marko_ribar
Advisor
Advisor
As it's stated in title, I want to set SNAPUNIT system variable... Values can differ in X and Y directions...
Then routine will ask to select LINES and then they will be modified so that each end point coincide with SNAP points when SNAP is turned ON...
I haven't started anything as I don't know how to approach to this task, so your input would be appreciated with welcome...

M.R.
 
Marko Ribar, d.i.a. (graduated engineer of architecture)
0 Likes
Accepted solutions (1)
1,193 Views
6 Replies
Replies (6)
Message 2 of 7

marko_ribar
Advisor
Advisor

I double posted this problem, so just to inform here is the link to the topic you should check too :

http://www.theswamp.org/index.php?topic=56389.0 

Marko Ribar, d.i.a. (graduated engineer of architecture)
0 Likes
Message 3 of 7

marko_ribar
Advisor
Advisor

If the end point of 2D LINE is somewhere in between all 4 surrounding SNAP POINTS - here is the priority order (left->right;bottom->up)... So this order : lower left SNAP POINT, upper left SNAP POINT, lower right SNAP POINT, upper right SNAP POINT...

Marko Ribar, d.i.a. (graduated engineer of architecture)
0 Likes
Message 4 of 7

marko_ribar
Advisor
Advisor
Accepted solution

I've found a solution with help of Stefan... My kudos to him...

 

http://www.theswamp.org/index.php?topic=56389.msg602376#msg602376 

Marko Ribar, d.i.a. (graduated engineer of architecture)
0 Likes
Message 5 of 7

CodeDing
Advisor
Advisor

@marko_ribar ,

 

You don't need to create any custom functions for this. There's actually an AutoLISP funciton built-in to handle this.

It's the (osnap ...) function. That looks like what you're asking for (see the link).

 

Best,

~DD

0 Likes
Message 6 of 7

CodeDing
Advisor
Advisor

@marko_ribar ,

 

It was brought to my attention that this is referring to Grid snap, NOT Object snap. I misunderstood.

 

Best,

~DD

0 Likes
Message 7 of 7

vladimir_michl
Advisor
Advisor

There is a good old utility - FixOffGrid - for this (by Joe Burke).

 

Vladimir Michl, www.cadstudio.cz - www.cadforum.cz

0 Likes