← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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