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