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