← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

HTML and CSS lesson 14: Colour and text properties · Set 417 · 40 questions
TalentJR

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

Answer key

  1. colours behind the text
  2. font-size
  3. in the middle
  4. blue
  5. font-family
  6. background-color
  7. makes the text bold
  8. 40
  9. text-align
  10. on the right
  11. in the middle
  12. 24
  13. white
  14. on the left
  15. black
  16. on the right
  17. on the right
  18. purple
  19. in the middle
  20. centres a heading
  21. makes letters bigger
  22. blue
  23. 20
  24. 36
  25. font-weight
  26. red
  27. 12
  28. orange
  29. on the right
  30. black
  31. picks the font style
  32. on the left
  33. black
  34. orange
  35. 40
  36. 12
  37. 32
  38. black
  39. orange
  40. on the right

Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids