← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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