← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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