title: TCPDF getting spacing issue with writeHTML
body: <p>I am using html to create pdf. Below is my code:</p>
  <pre><code>$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
  
  
  $pdf-&gt;SetMargins(15, 20, 14, 0);
  $pdf-&gt;SetAutoPageBreak(TRUE, 0);
  $pdf-&gt;setCellPaddings(0,0,0,0);
  $pdf-&gt;setFooterMargin(0);
  $pdf-&gt;setPrintHeader(false);
  $pdf-&gt;setPrintFooter(false);
  
  // add a page
  $pdf-&gt;AddPage();
  
      $html = '
      &lt;div style=&quot;background-color: #f8f8f8;&quot;&gt;
  
      &lt;div style=&quot;font-size: 24px; color: #333; font-weight: 600; font-family:Arial,Helvetica,sans-serif;&quot;&gt;Example&lt;/div&gt;
  
      &lt;p style=&quot;color: #828282; font-size: 14px; font-family: sans-serif;&quot;&gt;Lorem Ipsum is simply dummy text of the printing and typesetting industry. 
      Lorem Ipsum has been the industry standard dummy text ever since the 1500s, 
      when an unknown printer took a galley of type and scrambled it to make a type
      specimen book. It has survived not only five centuries, but also the leap 
      into electronic typesetting, remaining essentially unchanged. It was popularised 
      in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages,
      and more recently with desktop publishing software like Aldus PageMaker including 
      versions of Lorem Ipsum.&lt;/p&gt;
    &lt;/div&gt;';
  
  $pdf-&gt;writeHTML($html, false, false, true, false, '');
  
  $pdf-&gt;Output('example_001.pdf', 'I');
  </code></pre>
  <p>For some reason there is a space between heading and text as you can see<a href="https://i.stack.imgur.com/wKCnf.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/wKCnf.png" alt="enter image description here" /></a></p>
  <p>Also, whenever i add line-height style to make some space between lines in paragraph, it just leaves even more gap.</p>