HTML to PDF / DOCX / RTF Java converter library Forums PD4ML v3 Archived Forums (Read Only) HTML/CSS rendering issues css style control of checkbox will lose after convert to pdf

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #26599

    Hi, All. I came across some issues.
    In html, I use some checkbox tag, it displays well in IE6 broswer. However,after being converted to pdf, the checkbox displays much larger than in html. And all css styles of checkbox I set in html will lose after being converted to pdf.
    Did someone meet this issue? pls kindly give a hand.

    #28639

    maybe you can change size of the image that used to display checkbox by pd4ml.

    #28640

    It would be nice to take a look to the resulting PDF. Could you please attach it (with its source HTML) or send to support pd4ml com

    > checkbox displays much larger than in html
    What does “larger” mean? Is it comparing to other objects or texts of the document, or does it appear bigger in Acroread comparing to the web browser view?

    #28641

    As the attached picture, when use checkbox in a row, the height of row became much higher than normal height.
    checkbox is “larger” than texts of the document..
    <br /> <table cellspacing="0px" cellpadding="0px" style="margin-left:20px;" width = "100%"><br /> <tr><br /> <td><br /> <span class="cn">请单选</span><span class="en">Select One Option ONLY</span><br /> </td><br /> </tr><br /> <tr><br /> <td><input type="checkbox"/><span class="cn">单名帐户*</span><span class="en"> Sole A/C</span><br /> </td><br /> </tr><br /> </table>
    How to control the size of checkbox? it seems css style of checkbox will lose after html being converted to pdf. I want the checkbox being displayed same size as texts besides it.

    #28642

    I converted the HTML snippet and the result looks ok. See attached.

    Probably in your case there are some extra styles, that reduce the font size. I cannot tell exactly as I seen neither entire HTML document, not its PDF output.

    #28643

    @PD4ML wrote:

    I converted the HTML snippet and the result looks ok. See attached.

    Probably in your case there are some extra styles, that reduce the font size. I cannot tell exactly as I seen neither entire HTML document, not its PDF output.

    Sorry for so late to replay..details xml:
    <?xml version = "1.0" encoding = "UTF-8"?><br /> <html><br /> <meta content = "text/html; charset=UTF-8" http-equiv = "content-type"/><br /> <head><br /> <style type = "text/css"><br /> .cn {<br /> font-family: SimSun;<br /> color:#114488;<br /> margin-right:2px;<br /> font-size:8px;<br /> }<br /> .en {<br /> font-family: Arial;<br /> color:#000000;<br /> font-size:8px;<br /> }<br /> </style><br /> </head><br /> <body><br /> <table cellspacing="0px" cellpadding="0px" style="margin-left:20px;" width = "100%"><br /> <tr><br /> <td><br /> <span class="cn">请单选</span><span class="en">Select One Option ONLY</span><br /> </td><br /> </tr><br /> <tr><br /> <td><input type="checkbox"/><span class="cn">单名帐户*</span><span class="en"> Sole A/C</span><br /> </td><br /> </tr><br /> </table><br /> </body><br /> </html>
    The height of checkbox is too large, isn’t it?
    I want the checkbox has same height as the text besides it.
    ps:I saw that pd4ml use “java:/resources/icons/cb-off-big.gif ” & “java:/resources/icons/cb-off-big.gif” to render checkbox, could I use the smaller one –>”cb-off.gif”? if I could, then how to do it?

    #28644

    > The height of checkbox is too large, isn’t it?
    As for me, everything is correct. The font size 8px is too small (comparing to the default checkbox height 16px). I checked the HTML in a web browser and got more-less the same size difference of cb height and font size.

    Anyway the forthcoming PD4ML beta release will allow to control checkbox shape dimensions with CSS.

Viewing 7 posts - 1 through 7 (of 7 total)

The forum ‘HTML/CSS rendering issues’ is closed to new topics and replies.