← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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