title: DIV height doesn't working in pdfhtm iText?
body: <p>I'm trying to put the image inside a Div. However, the height attribute doesn't get applied inside the generated PDF.</p>
  
  <p>I wish to restrict the image height according to the DIV height. If the image is of smaller dimensions then the image shouldn't stretch, keeping the image dimension as it is. </p>
  
  <p><strong>HTML:</strong> </p>
  
  <pre><code>   &lt;div style="height: 396.0pt !important; border: 1px solid red;"&gt; 
     &lt;img border="0" src="C:/naveed personal/eclipse-jee-oxygen-M2-win32-x86_64/eclipse/Docs_a0Lg000000XzFhgEAF_4/015g0000001O9Qf.JPG"&gt; 
    &lt;/div&gt; 
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/NCP6O.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/NCP6O.jpg" alt="PDF"></a></p>