← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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