Locked lesson.
About this lesson
Exercise files
Download this lesson’s related exercise files.
Outline.docx58.7 KB Outline - Solution.docx
58.8 KB
Quick reference
Outline
You can create an outline with the outline-style property.
When to use
Any time you want an outline, use the outline-style property.
Instructions
Outlines go outside of a border but inside of a margin. To create an outline, use one of the following:
outline-style: dashed;
outline-style: dotted;
outline-style: double;
outline-style: groove;
outline-style: hidden;
outline-style: inherit;
outline-style: inset;
outline-style: none;
outline-style: outset;
outline-style: ridge;
outline-style: solid;
To change the color, size, and position, use the following:
outline-color: red;
outline-width; 10px;
outline-offset: 10px;
To use outline shorthand:
outline: 10px dotted black;
The order of the shorthand is: Width, Style, Color.
Hints & tips
- Outline-Style will create an outline.
- Outlines go outside a border but inside a margin.
Lesson notes are only available for subscribers.