Jump to content

beginner's question


Recommended Posts

Where can i find an "idiot's guide to Vectorscripts"?

For example:

I am in the habit of using construction lines a great deal when

drawing. I understand that i can create construction lines by going

to "edit", "make guide", but that is cumbersome.

I have tried writing scripts for tools called v-line and h-line, but

some aspect of the process eludes me. The goal is to click on the

script, then on a point in the drawing. The script would then make a

vertical (v-line) or horizontal (h-line) line, extending from that

point to to the limits of the screen in both directions, and convert

the line to a guide. This is my first attempt at script writing. I

picked something i thought would be pretty easy, but i must be

missing something. Can somebody help me out?

Link to comment
  • 1 month later...

Is this the sort of thing you're looking for? You might want to change the units to matcth yiour drawings. This gives vertical and horizontal guidelines, but the lock command doesn't lock the PIO in place. I don't know why.














Link to comment

But if you just want to avoid cumber, you can use the workspace editor (File > Workspaces > Workspace Editor) to assign a single keystroke to the Make Guide command. Just type the keystroke you want to assign to it, to the right of the command as it appears in your workspace (that's the window on the right side of the editor).

Link to comment

Steve, this is helpful. I compiled this script on my machine, and when i ran it , it gave me an error message about the menu cmmand, but went ahead and drew a vertical and horizontal guide intersecting at the origin. (and locked them). I will try to modify your script into two versions, one of which will give me a horizontal guide of a given length with its center point at the next click, and a similar vertical guide.

Thanks for taking the time

Link to comment


Your idea will simplify the process of turning a given line into a guide, which is good, but i want to be able to click on a point and get a vertical or horizontal guide without drawing the line first.

Thanks for your suggestion. I think i will use it until i get the other script working the way i want.


Link to comment

If you turn on "Snap to Loci" in VW Preferences, then placing a locus automatically displays infinite length horizontal and vertical lines through it. They don't evoke screen hints, but things do seem to snap to them in some ways.

But if you use loci for other purposes this probably won't work for you, because all those loci will have the same long hairy lines, cluttering up the drawing unbearably.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...