active control points after the draw curve tools

Next
 From:  FiL (FILIPPOL)
6802.1 
When I draw a curve, a line or a polyline, every time, after this operation I adjust the curve with the control points.
It will possible that the freeform curve tool ends (and in general for all the drawcurve tools) with the visible control points?

Filippo

_________________________

That's a brilliant day to design!

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
6802.2 In reply to 6802.1 
Hi Filippo,

> It will possible that the freeform curve tool ends (and in general for all the
> drawcurve tools) with the visible control points?

It's possible to do this by editing the curve drawing script command to add a line of script that turns on control points.

To do this go to the \commands sub-folder inside of MoI's main installation folder and edit the file DoCurve.js inside of a text editor.

At the end of the file, find this:

code:
	else
	{
		curvefactory.commit();
	}


And change it to this by inserting the one new line before the .commit() :

code:
	else
	{
		curvefactory.getCreatedObjects().setProperty( 'showpoints', true );
		curvefactory.commit();
	}



Then when you draw a freeform curve it will have control points turned on for it when the command finishes.

I would not really recommend doing this to every single command though, for other commands it's possible to set up a shortcut key that will turn on control points for whatever was the last created object. To do that set up the following script on a shortcut key and press that key when you want to turn on a just created curve's control points (you do not need to select the curve first):

script: /* turn on points for last created object */ var a = moi.command.lastCommandRevisionStart; var b = moi.command.lastCommandRevisionEnd; var objects = moi.geometryDatabase.getObjects(); for ( var i = 0; i < objects.length; ++i ) { var obj = objects.item(i); if ( obj.databaseRevision> a && obj.databaseRevision <= b ) obj.showPoints = true; }


- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
 From:  FiL (FILIPPOL)
6802.3 In reply to 6802.2 
The first one is what I need.
The second script is usefull for all the other shapes: circle, ellipse...
Thank Michael

Grazie

Filippo

_________________________

That's a brilliant day to design!

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All