Anuncios

The Autodesk Community Forums has a new look. Read more about what's changed on the Community Announcements board.

Kent1Cooper
en respuesta a: g.stratoudaki


@g.stratoudaki wrote:

....

when I draw a polyline I can't change  the linetype or the color of each segment separately as the thickness.

How I can do that with pedit commant  or with another command or a combination of commands ?

....


Be careful about your terminology.  What you can change separately for each segment is the width, not the thickness.  Thickness has a specific meaning in AutoCAD, and it's not  the same as width in Polylines -- it's up off the page in the Z direction.  A Polyline's thickness is the same for the entire object, as are its color and linetype and linetype scale and Layer and so on.  A Polyline has both width(s) and  thickness, and either or both can be zero or otherwise.

 

No, you can't assign linetype or color for segments individually with PEDIT.  You would have to either:

 

A)  As @cadffm said in Post 3, Explode the Polyline, and do it to the resulting lines and arcs.  You will, however, lose any width(s)  that the segments had in the original Polyline, since Lines and Arcs can't have width.

 

B)  If you want to keep non-zero width(s), you can break up the Polyline into separate one-segment Polylines, using something like PolylineSubdivide.lsp with its PSD command, available here.  You will, however, lose the beveling of ends where they meet the other former segments.

 

EDIT:

 

C)  If a Polyline is made up of line segments only  that have the same width throughout, and continuous linetype, you can duplicate that with the TRACE command.  That will result in separate Trace objects for each segment, and will maintain the beveled ends of the separate pieces where they meet, and they can be given different colors [or put on different Layers, etc.].  However, Traces can't have non-continuous linetypes [you can assign one, but it won't display that way], and they can't be arc-shaped, only straight.  But if the conditions are as described, duplicating such a Polyline with TRACE could probably be automated easily enough into a command with AutoLisp.

 

In any case, if you want the results to be one object as the original Polyline was, you would need to define them together into a Block, or if you want them sort of like one object, you could Group them together.

Kent Cooper, AIA