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