← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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