CSS Worksheet: Colour and Text Properties
Code tip (Letters, behind, size, place): color = colour of the letters; background-color = colour behind them. font-size = how big (e.g. 20px); font-weight: bold = thick letters; font-family = the font. text-align: left / center / right places the text on its line.
NameDateTime takenScore ___ / 40
- 1.🖌️ Which CSS property picks the font style? (a) text-align (b) font-size (c) font-family (d) color
- 2.What does font-family do? (a) picks the font style (b) centres a heading (c) colours behind the text (d) sets the letter colour
- 3.🖌️ Which CSS property colours behind the text? (a) background-color (b) font-weight (c) font-size (d) text-align
-
4.🖌️ Where does the text sit on its line?
h2 {
text-align: left;
background-color: blue;
font-size: 40px;
color: purple;
} (a) in the middle (b) on the left (c) on the right - 5.What does color do? (a) makes the text bold (b) colours behind the text (c) centres a heading (d) sets the letter colour
-
6.🖌️ What colour is behind the letters?
h1 {
font-size: 32px;
background-color: blue;
color: yellow;
text-align: center;
} (a) yellow (b) white (c) blue -
7.🖌️ What colour is behind the letters?
h2 {
background-color: yellow;
font-size: 20px;
text-align: center;
color: purple;
} (a) purple (b) red (c) yellow - 8.What does font-weight do? (a) centres a heading (b) colours behind the text (c) makes the text bold (d) makes letters bigger
- 9.🖌️ Which CSS property centres a heading? (a) background-color (b) color (c) font-size (d) text-align
-
10.🖌️ What colour is behind the letters?
h2 {
text-align: left;
font-size: 20px;
color: white;
background-color: green;
} (a) white (b) blue (c) green - 11.What does text-align do? (a) colours behind the text (b) makes the text bold (c) centres a heading (d) sets the letter colour
-
12.🖌️ Where does the text sit on its line?
h1 {
font-size: 16px;
color: yellow;
background-color: black;
text-align: center;
} (a) in the middle (b) on the left (c) on the right -
13.🖌️ What colour are the letters?
h2 {
color: purple;
text-align: right;
font-size: 12px;
background-color: blue;
} (a) purple (b) white (c) blue - 14.🖌️ Which CSS property makes letters bigger? (a) font-size (b) text-align (c) font-weight (d) color
- 15.What does background-color do? (a) makes the text bold (b) colours behind the text (c) picks the font style (d) makes letters bigger
-
16.🖌️ Where does the text sit on its line?
p {
background-color: green;
text-align: right;
color: purple;
font-size: 12px;
} (a) on the left (b) on the right (c) in the middle -
17.🖌️ How big is the text, in px?
p {
background-color: blue;
font-size: 20px;
text-align: center;
color: purple;
} -
18.🖌️ What colour is behind the letters?
h1 {
font-size: 12px;
background-color: white;
text-align: left;
color: green;
} (a) white (b) green (c) red -
19.🖌️ Where does the text sit on its line?
li {
color: orange;
background-color: white;
text-align: right;
font-size: 40px;
} (a) on the right (b) in the middle (c) on the left -
20.🖌️ What colour is behind the letters?
h1 {
font-size: 12px;
background-color: purple;
color: blue;
text-align: right;
} (a) blue (b) green (c) purple -
21.🖌️ Where does the text sit on its line?
h2 {
text-align: center;
background-color: purple;
font-size: 24px;
color: orange;
} (a) on the right (b) in the middle (c) on the left -
22.🖌️ What colour is behind the letters?
p {
text-align: right;
background-color: red;
color: blue;
font-size: 20px;
} (a) blue (b) red (c) green -
23.🖌️ What colour is behind the letters?
h2 {
text-align: center;
background-color: black;
color: blue;
font-size: 12px;
} (a) blue (b) purple (c) black -
24.🖌️ What colour is behind the letters?
p {
font-size: 12px;
color: green;
background-color: orange;
text-align: right;
} (a) black (b) green (c) orange -
25.🖌️ What colour are the letters?
h1 {
background-color: yellow;
font-size: 20px;
text-align: right;
color: blue;
} (a) green (b) yellow (c) blue - 26.What does font-size do? (a) sets the letter colour (b) makes letters bigger (c) picks the font style (d) colours behind the text
-
27.🖌️ Where does the text sit on its line?
li {
color: purple;
text-align: center;
background-color: red;
font-size: 28px;
} (a) on the right (b) on the left (c) in the middle -
28.🖌️ Where does the text sit on its line?
h1 {
background-color: black;
text-align: right;
font-size: 32px;
color: blue;
} (a) on the right (b) on the left (c) in the middle -
29.🖌️ Where does the text sit on its line?
p {
color: purple;
font-size: 20px;
background-color: red;
text-align: left;
} (a) on the right (b) on the left (c) in the middle -
30.🖌️ How big is the text, in px?
h1 {
font-size: 40px;
text-align: right;
background-color: white;
color: yellow;
} - 31.🖌️ Which CSS property makes the text bold? (a) background-color (b) font-size (c) font-weight (d) color
-
32.🖌️ How big is the text, in px?
li {
background-color: orange;
text-align: center;
font-size: 40px;
color: purple;
} -
33.🖌️ What colour are the letters?
li {
text-align: left;
color: white;
font-size: 20px;
background-color: blue;
} (a) blue (b) white (c) yellow -
34.🖌️ What colour are the letters?
h2 {
font-size: 40px;
text-align: right;
background-color: orange;
color: black;
} (a) orange (b) white (c) black -
35.🖌️ How big is the text, in px?
h1 {
text-align: center;
color: red;
background-color: white;
font-size: 16px;
} -
36.🖌️ What colour are the letters?
h1 {
text-align: left;
font-size: 24px;
background-color: yellow;
color: red;
} (a) white (b) yellow (c) red -
37.🖌️ What colour is behind the letters?
li {
color: yellow;
text-align: center;
font-size: 32px;
background-color: blue;
} (a) red (b) blue (c) yellow -
38.🖌️ What colour are the letters?
h1 {
background-color: orange;
text-align: center;
font-size: 12px;
color: red;
} (a) red (b) white (c) orange -
39.🖌️ What colour are the letters?
p {
background-color: purple;
color: green;
text-align: left;
font-size: 28px;
} (a) green (b) purple (c) red -
40.🖌️ How big is the text, in px?
h2 {
text-align: right;
background-color: yellow;
color: green;
font-size: 20px;
}
Answer key
- font-family
- picks the font style
- background-color
- on the left
- sets the letter colour
- blue
- yellow
- makes the text bold
- text-align
- green
- centres a heading
- in the middle
- purple
- font-size
- colours behind the text
- on the right
- 20
- white
- on the right
- purple
- in the middle
- red
- black
- orange
- blue
- makes letters bigger
- in the middle
- on the right
- on the left
- 40
- font-weight
- 40
- white
- black
- 16
- red
- blue
- red
- green
- 20
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids