Draw a shape or path in your project
You can draw shapes, paths, and controls to design the user interface of your application. Items that you draw become objects in your application.
To draw a shape
In the Tools panel, select one of the shape tools: Rectangle or Ellipse .
Tip
To view all the drawing tools, right-click the tool that is visible in the Tools panel. The Line tool creates a path object, which is covered later in this topic.
On the artboard, draw the shape by dragging with your mouse.
Notice that as you draw the shape, the width and height dimensions appear as follows:
Tip
Holding down SHIFT while you drag will keep the height and width the same. Doing this will produce a square when you draw a rectangle, or a circle when you draw an ellipse.
Tip
Holding down ALT while you drag will put the center point at the first point where you click, instead of making the top-left corner of the shape the first point that you click.
After you release the mouse button, translation handles appear for scaling, rotating, moving, skewing, and other actions that you can perform on the shape object. Your pointer changes to indicate which action you can perform, as shown in the following figure.
Save your changes (CTRL+S).
Next steps
To draw a path
In the Tools panel, select one of the path tools: Pen or Pencil .
Tip
To view all the path tools, right-click the tool that is visible in the Tools panel.
On the artboard, draw a path by doing one of the following:
With the Pencil tool, drag on the artboard to produce a pixel everywhere that your pointer touches.
With the Pen tool, click the artboard to produce points (or vertices) that will make up a path object. Optionally, drag to produce curves at each point. To close the path, click the first point. To exit the Pen tool without closing the path, select another tool or select an object in the Objects and Timeline panel.
After you finish drawing the path, translation handles appear for scaling, rotating, moving, skewing, and other actions that you can perform on the path object. Your pointer changes to indicate which action you can do with the Selection tool .
To modify individual points on the path, click Direct Selection . The path object displays individual points and line segments that you can click and move.
For a list of ways to modify paths, see Pen tool modifier keys and Direct Selection tool modifier keys.
Save your changes (CTRL+S).
Next steps
To draw a line
In the Tools panel, select Line .
Tip
If you can't see the Line tool, right-click the tool container in the Tools panel, and then select the Line tool.
On the artboard, draw the line by dragging with your mouse.
Tip
Holding down SHIFT while you drag will constrain the line to angles that are multiples of 15 degrees.
Tip
Holding down ALT while you drag will make the first point that you click the center point, instead of making the middle of the line the center point.
After you release the mouse button, translation handles appear for scaling, rotating, moving, skewing, and other actions that you can perform. Your pointer changes to indicate which action you can do with the Selection tool .
To modify the starting or ending point of the line, click Direct Selection . The line, which is a path object, displays individual points that you can click and move.
For a list of ways to modify paths, see Pen tool modifier keys and Direct Selection tool modifier keys.
Save your changes (CTRL+S).