← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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