PDF Generating Tool Support Forum

HOME   Login   Register    Search




  Subject: css style control of checkbox will lose after convert to pdf
   PostPosted: 26 Aug 2011, 10:07 
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.


  Subject: Re: css style control of checkbox will lose after convert to pdf
   PostPosted: 28 Aug 2011, 16:10 
maybe you can change size of the image that used to display checkbox by pd4ml.


  Subject: Re: css style control of checkbox will lose after convert to pdf
   PostPosted: 29 Aug 2011, 19:26 
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?


  Subject: Re: css style control of checkbox will lose after convert to pdf
   PostPosted: 30 Aug 2011, 11:25 
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..
Code:
<table cellspacing="0px" cellpadding="0px" style="margin-left:20px;" width = "100%">
<tr>
<td>
<span class="cn">请单选</span><span class="en">Select One Option ONLY</span>
</td>
</tr>
<tr>
<td><input type="checkbox"/><span class="cn">单名帐户*</span><span class="en"> Sole A/C</span>
</td>
</tr>
</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.


Attachments:
checkbox.PNG
checkbox.PNG [ 9.96 KiB | Viewed 532 times ]
  Subject: Re: css style control of checkbox will lose after convert to pdf
   PostPosted: 30 Aug 2011, 12:01 
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.


Attachments:
checkbox.png
checkbox.png [ 13.32 KiB | Viewed 534 times ]
  Subject: Re: css style control of checkbox will lose after convert to pdf
   PostPosted: 16 Sep 2011, 05:08 
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:
Code:
<?xml version = "1.0" encoding = "UTF-8"?>
<html>
   <meta content = "text/html; charset=UTF-8" http-equiv = "content-type"/>
   <head>
      <style type = "text/css">
         .cn {
            font-family: SimSun;
            color:#114488;
            margin-right:2px;
            font-size:8px;
         }
         .en {
            font-family: Arial;
            color:#000000;
            font-size:8px;
         }
      </style>
   </head>
   <body>
      <table cellspacing="0px" cellpadding="0px" style="margin-left:20px;" width = "100%">
         <tr>
         <td>
         <span class="cn">请单选</span><span class="en">Select One Option ONLY</span>
         </td>
         </tr>
         <tr>
         <td><input type="checkbox"/><span class="cn">单名帐户*</span><span class="en"> Sole A/C</span>
         </td>
         </tr>
      </table>
   </body>
</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?


Attachments:
t.PNG
t.PNG [ 11.79 KiB | Viewed 476 times ]
  Subject: Re: css style control of checkbox will lose after convert to pdf
   PostPosted: 16 Sep 2011, 12:55 
> 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.



[Reply]     [ 7 posts ] 

Copyright ©2004-10 zefer|org. All rights reserved. Bookmark and Share