paragraph indent : text indent « CSS « HTML / CSS






paragraph indent

  

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/2000/REC-xhtml1-20000126/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <meta http-equiv="content-type" content="text/html; charset=utf-8" />
  <title>Headings example 4</title>
  <style type="text/css">
    body {
      font: 12px/1.5em Georgia, serif;
    }
    h1 { 
      font: italic 1em/1.5em Georgia, serif;
      margin: 0.75em 0 0 0;
    }
    p {
      margin: 0 0 0 1em;
      width: 33em;
    }
  </style>
</head>
<body>
  <h1>The most important heading</h1>
  <p>  this is a test. this is a test. this is a test. 
  this is a test. this is a test. this is a test. 
  this is a test. this is a test. this is a test. 
  this is a test. this is a test. this is a test. 
  this is a test. this is a test. this is a test. 
  this is a test. </p>
</body>
</html>

   
  








Related examples in the same category

1.'text-indent' Example
2.text-indent: 25%
3.text-indent: -5%
4.text-indent: -25px (positive value)
5.text-indent: 25px;
6.
  • text indent: -0.75em
  • 7.text-indent: 3em
    8.text-indent: 10%;
    9.text-indent: -25px;
    10.text-indent:3em;
    11.text-indent: -15px;
    12.text-indent: -25px;(negative value)
    13.text-indent: 25%;(percentage)
    14.text-indent: 20px;
    15.Paragraphs separated by indenting
    16.Set text indent to 37%
    17.Set text indent to 35px
    18.Set text-indent to 2.5em
    19.Negative text indent value: -60px
    20.uses a negative value for text-indent and a positive value for padding-left.
    21.Set text indent to -5em