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