← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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