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