Jump to content
Developer Wiki and Function Reference Links ×

scale lineweights script


Dan Kessler

Recommended Posts

Does anyone have, or know of a script that would allow me to select multiple entities in a drawing and scale their lineweight up or down by a percentage that I specify?

As an example, if I created a drawing at 1/4" scale and decided later that I wanted it to be 1/8"... Is it possible to have a script that would allow me to scale all lineweights by a factor of 0.5 so that the lineweight aren't twice as thick as they should be?

Maybe this is more easily done through Classes? Could it be possible to have a script scale each Classes' lineweight up or down by a factor that I specify?

Link to comment

hello,

I have the following script/command which scales the lineweights of all selected objects. if you want to use classes you need to somehow let vectorscript know which class to search for as well as the scale factor. I like the following because a simple predefined dialog is all thats needed.

PROCEDURE Lineweight;

VAR

pen

:INTEGER;

factor

:REAL;

h:

HANDLE;

BEGIN

factor:=RealDialog('Enter Scale Factor','.5');

h:=LSActlayer;

While h<> NIL DO BEGIN

pen:=getlw(h);

pen:=round(pen*factor);

setlw(h,pen);

h:=PrevSObj(h);

END;

END;

RUN(Lineweight);

i hope this is helpful.

-jason

Link to comment

Walther,

I agree that we could all benefit from Nemetschek including those options within the "scale objects" command and scale tool. More importantly to me, though, is if they would add the scale lineweights option to the layer scale window. Often I find myself drawing something and later changing it's layer's scale.

Dan

[ 02-13-2003, 03:18 PM: Message edited by: Dan Kessler ]

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.

Guest
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...