AutoCAD basics and lessons from experts
In AutoCAD, polylines are complex shapes. Unlike lines and arcs, polylines can have multiple segments. AutoCAD treats polylines as single objects, making it easier to manipulate and change them. Because polylines can have multiple segments but are treated as objects, they can provide additional information, such as area.
Creating Polylines
Start a polyline from the ribbon or type pline or PL (a keyboard shortcut) in the command line.
Creating a polyline is basically like drawing a line. The difference is the result is a single multisegment object as opposed to multiple single-line objects.
Within the drawing canvas, enter coordinates for or select the starting point (or snap to an existing object). As you move the cursor away from this point, AutoCAD’s rubber band previews the new segment. Continue to pick points, creating new segments with each selection.
With the shape complete:
- To create an open object, press Enter, the space bar or Escape. You can also right-click and select Enter from the menu to end the command.
- To create a closed object, right-click and then select Close from the menu (or press C on the keyboard). AutoCAD automatically connects the last point chosen with the polyline’s starting point.
Pro Tip: After starting the command, press Enter to select the last point used.
Arcs
With polylines, you can toggle into creating arc segments by selecting Arc from the right-click menu or by using the A shortcut. Once in arc mode, toggle back to line mode by selecting Line from the right-click menu or by using the L shortcut.
You can toggle between modes anytime during your polyline creation, creating polylines with a mix of straight and curved segments.
The default method will create the arc segment by three points. AutoCAD uses the last point chosen as the starting point for the arc segment. The arc will be drawn from the first point, through the second point and ending at the third point.
While in arc mode, right-click for other arc creation options. These options mimic the options for creating non-polyline arcs:
- Center—create the arc with the selected center point and endpoint
- Angle—specify the included angle and point the endpoint for the arc
- Direction—create the arc by specifying the tangent direction from the arc’s starting point
- Radius—set the radius and pick the endpoint of the arc
Pro Tip: Hold the Ctrl key while creating arc segments to flip the direction.
Other Options
With polylines, you can apply Width. Not to be confused with line weight, width can be used to highlight or emphasize polylines or segments of polylines.
While drawing the polyline, use the Width option (the W shortcut) for the width. All segments after this will use this same value—until you change it. You can vary the width per polyline segment.
Width is the distance from edge to edge on the polyline. Halfwidth is the distance from the center of the polyline to one of its edges.
Use the Length option to create a new line segment of a specified length.
Pro Tip: At any point during the procedure, select Undo to undo only the most recently formed segment. Undo is accessible via the Quick Access Toolbar (QAT), Ctrl + Z or the U keyboard shortcut. Using Undo after executing the polyline command, however, will undo the entire polyline.
Making Changes
Like most 2D objects in AutoCAD, you can move, copy, rotate, scale, stretch and perform other Modify operations on them. Using the Properties palette, make changes including adjusting the layer, setting the width and closing the polyline.
Like other 2D objects, you can change the polyline’s layer, color, line type and line weight.
Because polylines can have multiple segments, use the grips to work with the vertices as well as toggle segments between lines and arcs.
While hovering over a rectangular grip, select
- Stretch to move the segment
- Add vertex to add a new point along the polyline, introducing a new segment
- Convert to arc to change the line segment to an arc
- Convert to line to change the arc segment to a line
While hovering over a square grip, use
- Stretch vertex to move the point, lengthening or shortening the segment
- Add vertex to add a new point along the polyline, introducing a new segment
- Remove vertex to delete the point
- Extend vertex to add a new point (and segment) from the selected end grip
Polyline Edit
As we have already explored, polylines have many options. You can manipulate these options during polyline creation or after a polyline has been created. To work with polylines after creation, use Polyline Edit (PEDIT).
Pro Tip: With Polyline Edit, when selecting a line, arc or spline, AutoCAD prompts “Do you want to turn it into one?” Choose Yes to convert the object into a polyline.
Use JOIN to connect separate polylines into a single, continuous polyline. This can be useful when you need to manipulate multiple lines and arcs as one object. For objects to join the polyline, their endpoints must touch.
Edit Vertex allows you to move, add or delete points (vertices) in the polyline. This option starts with the first vertex in the polyline. Use Next and Previous to navigate through the polyline. AutoCAD shows the active vertex with an X. However, in most cases, it is easier to make changes with grips than Edit Vertex.
Apply Fit when you want to take a line-segmented polyline and create a smooth curve consisting of arcs joining each pair of vertices. Decurve is the opposite process, converting a curved polyline into a straight-line segmented polyline.
Where Fit creates arcs passing through every vertex, the Spline option uses the vertices as control points to approximate a spline-fit polyline. The curve pulls toward each point but does not necessarily pass through them. This differs from the true B-splines created by the SPLINE command.
Additionally, use:
- Close to close the polyline by connecting the end of the last segment with the beginning of the first segment
- Lengthen to extend or shorten the polyline
- Ltype gen enabled, which allows AutoCAD to generate the line type in a continuous pattern through the vertices of the polyline
- Reverse to change the polyline direction
- Width to set the new width for all segments
Pro Tip: Many of PEDIT’s options are also available when you right-click on a polyline.
Multiple Polyline Edit
After starting PEDIT, but before selecting an object, select Multiple (“M” shortcut) to enter multi-polyline edit mode. While in multiple mode, you can select multiple objects to convert to polylines and apply changes to multiple selected objects.
Most of the options function the same. The only difference is that the changes apply to all the selected objects. One exception to this is Join, where AutoCAD prompts for the fuzz distance and optional Jointype. You can join nonconnected polylines if the fuzz distance is large enough to include the endpoints. Use Jointype to manage how AutoCAD connects the polylines, whether by adding new segments, extending existing ones or a combination of both.
Polylines and Other Commands
There are many AutoCAD commands that create polylines; for example, RECTANGLE, which actually creates a polyline in the form of a rectangle.
PEDIT and the other polyline editing tools are available for any polyline, regardless of how it was created.
Break and Break at Point work with polylines as they do with other 2D objects. Just as with other objects, the result is two separate polylines.
Join connects the endpoints of linear and curved objects to create a single object. When you have a mix of object types, the key is the source object. When picking a polyline first, you can join lines and arcs in addition to existing polylines. Therefore, you can create a single polyline resulting from joining coplanar lines, arcs and polylines.
Pro Tip: If using AutoCAD Mechanical take a look at its join feature (AMJOIN), which connects nonparallel lines, polylines and arcs, even if they are overlapping.
When using Fillet and Chamfer, you can apply the feature to single segments, like between line segments. Using the Polyline option, however, you can apply a fillet/chamfer with a uniform radius/bevel on all the vertices with a single command.
Using polylines can significantly improve efficiency in use of AutoCAD because a polyline allows more options, control and flexibility over creating individual lines and arc.