← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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