Forum Replies Created

Viewing 15 posts - 451 through 465 (of 4,333 total)
  • Author
    Posts
  • in reply to: Dynamic change of PDF page orientation
    #27597

    As I wrote before the scale factor is computed this way:
    scale = (pageFormat.width – insets.left – insets.right) / htmlWidth

    In your case a switch from portrait to landscape means change of pageFormat.width from 595 to 842. You need to correspondingly/proportionally increase htmlWidth parameter.

    in reply to: Troubleshooting
    #26342

    Problem


    The function call of “Pd4ml.render” take long for processing HTML with large PDF attachment.

    System Info


    Windows 2003 Standard Edition
    Lotus Domino 7.03 FP1
    PD4ML Java Library Pro

    Background


    Our program is designed to generate PDF from Lotus Notes Email Document.
    There are few steps to doing that:
    1) Export a lotus Notes Document with attachment to DXL format file.
    2) Use javax.xml.transform.Transformer class to convert DXL file to HTML file.
    3) use pd4ml.render() function to convert HTML file to PDF.

    Currently, we found that the time required to completed the function call “pd4ml.render” when the input HTML is transformed from Notes Document with a large size of PDF file attached. (e.g. 12MB PDF file need 11 minute to finish this function call).

    Please kindly advise whether there is any method to speed up this case.

    Part of the Code (full code of the agent is attached)


    pd4ml.enableDebugInfo();
    java.net.URL base = new java.net.URL("http:/yahoo.com");
    java.io.StringReader isr = new java.io.StringReader("file:" + readEncFile(inputHTMLFileName, "UTF8"));
    System.out.println("17");
    pd4ml.render(isr, fos, base, "UTF8");  //The time between the printout of 17 and 18 shown up is about 11 min
    System.out.println("18");

    in reply to: General questions / FAQ
    #26343

    Hi
    how can i give other language Support in PDF i have sent [汎用-集計] japanese character in Pdf i got ??-??
    how can i resolve this problem

    Thanks in Advance
    Regards
    Dinesh.N

    in reply to: Double byte support
    #27886

    You need to utilize TTF embedding feature of PD4ML Pro:

    pd4ml-html-css-pdf-tips-tricks-f7/ttf-embedding-t42.html

    in reply to: "Pd4ml.render" take long time to process
    #27877

    Please request the most recent XSL stylesheet and the reference agent code from support pd4ml.com by email.

    I suspect the following: the default XSL stylesheet of the demo Notes database represents attachment files as
    <pd4ml:attachment src="data:a-lot-of-base64-data">

    It takes a lot of time to parse such huge attribute value (if we are talking about tens of megabytes) and constantly reallocate string to store it.

    The most recent XSL allows either to temporarily store the attachment to TMP directory and to refer to it from the attachment tag: <pd4ml:attachment src="file:/tmp/xxxyyyzzz.bin"> or to represent the attachment as tag body <pd4ml:attachment>data:a-lot-of-base64-data</pd4ml:attachment>. Both approaches are intended to solve the performance issue.

    in reply to: Double byte support
    #27887

    Thanks For your replay

    i tried but i have got some problem
    what i do why couldn’t i cache font properties.
    Here i have sent my exception
    Thanks in Advance,

    not yet in cache: file:c:/egurkha/manager/fonts/pd4fonts.properties
    using content encoding from HTTP header: UTF-8
    loading CSS file http://192.168.10.170:7077/final/reporter/eg_styles/repstyle_purple.css
    not yet in cache: http://192.168.10.170:7077/final/reporter/eg_styles/repstyle_purple.css
    'verdana' is not in pd4fonts.properties file
    reject TTF lookup for: 'verdana'
    'arial' is not in pd4fonts.properties file
    reject TTF lookup for: 'arial'
    'helvetica' is not in pd4fonts.properties file
    reject TTF lookup for: 'helvetica'
    not yet in cache: file:c:/egurkha/manager/fonts/CODE2000.TTF
    read 'code2000' from file:c:/egurkha/manager/fonts/CODE2000.TTF
    'arial bold' is not in pd4fonts.properties file
    reject TTF lookup for: 'arial bold'
    'verdana bold' is not in pd4fonts.properties file
    reject TTF lookup for: 'verdana bold'
    'helvetica bold' is not in pd4fonts.properties file
    reject TTF lookup for: 'helvetica bold'
    image not yet in cache: http://192.168.10.170:7077/final/reporter/images/spacer.gif
    not yet in cache: http://192.168.10.170:7077/final/reporter/images/spacer.gif
    image size: 43
    image not yet in cache: http://192.168.10.170:7077/final/reporter/images/purple/print.gif
    not yet in cache: http://192.168.10.170:7077/final/reporter/images/purple/print.gif
    image size: 1117
    'courier new' is not in pd4fonts.properties file
    reject TTF lookup for: 'courier new'
    image not yet in cache: http://192.168.10.170:7077/final/reporter/images/purple/tray-corner.gif
    not yet in cache: http://192.168.10.170:7077/final/reporter/images/purple/tray-corner.gif
    image size: 352
    done in 6610ms.
    done.

    Regards
    Dinesh.N

    in reply to: Troubleshooting
    #26344

    Hello,

    we have documents where an image is inside of a <td> in a tablerow and in another <td> of the same row we have some multiline-text. See problem_html.jpg with an image of the look.
    When this image now requires pd4ml to put it on the next side because of the noimagesplit-option and the text in the other td also continues to this page, the text isn’t continued at the top of the side but at the bottom of the image. See problem_pdf.jpg for an image of the same part.
    I’ve also included the original htm-code inside of problem.zip.

    Is this a problem of pd4ml or can we change anything inside our html-code to prevent pd4ml from doing this?

    in reply to: "Pd4ml.render" take long time to process
    #27878

    Dear Sir/Madam,

    Firstly, thank for your prompt reply.

    I have asked your company’s email support service to give me the new XSL. Your colleague, Igor had gave me the new XSL file. However, there some problem found.:

    1) I found that new XSL file does not have the tag (<pd4ml:attachment src="file:/tmp/xxxyyyzzz.bin">) which you mentioned in last reply.

    2) The XSL file that your colleague, Igor sent to me that need me to try to un-remark the line No. 298 and 308 in order to use. I have tried to keep the remark and un-remark these 2 lines. But both does not improve my pd4ml.render() function. It still cause 10-11 minutes to complete. Also, it need me to increase Min heap size of domino to around 800MB in order to successfull run. My original setting of around 500MB Min heap size will cause the domino agent throw out of memory exception.

    3) Then I try to change my agent to use the one that Igor send to me. However, I found that my current Jar library does not the API “generatePDFA”.

    Please kindly advise what further step I can do in order to improve the speed.

    Thank you very much!

    Attached the XSL and agent code that Igor sent to me.

    in reply to: "Pd4ml.render" take long time to process
    #27879

    Please forward the questions again to Igor. Missing of generatePDFA() method, means you use old version of PD4ML (probably it is cached in the database).

    It would also help if you uncomment DXL dump method in the agent code and send the output to us. It should help us to reproduce the issue and to provide you with a tuned XSL stylesheet.

    in reply to: Problem using noimagesplit-Option
    #27891

    In order to avoid such issues, I would recommend not to use enableImgSplit(false).

    A better approach would be to apply “page-break-inside: avoid” CSS property to particular table rows. In most of the cases it is also harmless to apply

    TR {page-break-inside: avoid} to entire document.

    in reply to: General questions / FAQ
    #26345

    Hello… I am evaluating this product. I tried to run a few examples and compare it with others. So far this is really good. However, one of the url I tested was not properly converted. It seems that some CSS instructions were not followed.

    The url I am referring is http://www.blazersedge.com. I viewed the source and it has at least five CSS links but noticed that only one css was loaded by PD4ML. Can you please set me to the right directions how to convert this page properly?

    version: PD4ML 360 (eval)
    using content encoding from HTTP header: utf-8
    loading CSS file http://cdn3.sbnation.com/stylesheets/blogs/mobile.v12913.css
    not yet in cache: http://cdn3.sbnation.com/stylesheets/blogs/mobile.v12913.css
    image not yet in cache: http://cdn2.sbnation.com/community_logos/14415/blazersedge-mid.jpg
    not yet in cache: http://cdn2.sbnation.com/community_logos/14415/blazersedge-mid.jpg
    image size: 7456
    image not yet in cache: http://cdn2.sbnation.com/entry_photo_images/313246/79521_trail_blazers_grizzlies_basketball_small.jpg
    not yet in cache: http://cdn2.sbnation.com/entry_photo_images/313246/79521_trail_blazers_grizzlies_basketball_small.jpg
    image size: 3460
    image not yet in cache: http://ad.sbnation.com/avw.php?zoneid=2413&n=xWziKDS4
    not yet in cache: http://ad.sbnation.com/avw.php?zoneid=2413&n=xWziKDS4
    image size: 43
    image not yet in cache: http://ad.sbnation.com/avw.php?zoneid=2415&n=g5WdFW4c
    not yet in cache: http://ad.sbnation.com/avw.php?zoneid=2415&n=g5WdFW4c
    image size: 43
    image not yet in cache: http://assets.sbnation.com/assets/315397/penn_medium.jpg
    not yet in cache: http://assets.sbnation.com/assets/315397/penn_medium.jpg
    image size: 68186
    image not yet in cache: http://assets.sbnation.com/assets/315479/cho_medium.jpg
    not yet in cache: http://assets.sbnation.com/assets/315479/cho_medium.jpg
    image size: 32250
    image not yet in cache: http://cdn2.sbnation.com/entry_photo_images/311344/40561_acc_miami_duke_basketball_small.jpg
    not yet in cache: http://cdn2.sbnation.com/entry_photo_images/311344/40561_acc_miami_duke_basketball_small.jpg
    image size: 2116
    image not yet in cache: http://s24.sitemeter.com/meter.asp?site=s24blazersedge
    not yet in cache: http://s24.sitemeter.com/meter.asp?site=s24blazersedge
    image size: 669
    image not yet in cache: http://sm9.sitemeter.com/meter.asp?site=sm9sbnnet
    not yet in cache: http://sm9.sitemeter.com/meter.asp?site=sm9sbnnet
    image size: 173
    image not yet in cache: http://b.scorecardresearch.com/p?c1=2&c2=6846907&c3=&c4=&c5=&c6=&c15=&cj=1
    not yet in cache: http://b.scorecardresearch.com/p?c1=2&c2=6846907&c3=&c4=&c5=&c6=&c15=&cj=1
    image size: 43
    done in 5756ms.

    in reply to: Evaluating PD4ML
    #27892

    Obviously the site returns layouts and styles, optimized for particular client browser – which is actually good practice.

    PD4ML does not declare itself in HTTP request as any of the major browsers, so it receives a very basic HTML/CSS version (probably a version for mobile clients). As for me the HTML is converted correctly. See attached.

    in reply to: Evaluating PD4ML
    #27893

    No it was not… I have attached how another converter does it. Also, now I noticed that PD4ML from this website is in MOBILE BROWSER mode (look at the debug output again). If so, how do we resolve this?

    Well… I can’t attached the file since it’s 1mb in size.

    in reply to: Evaluating PD4ML
    #27894

    A lot of “other” converters use MS IE or Mozilla native DLLs to load and render HTML. So the site returns versions, adapted for the browsers.

    PD4ML uses our proprietary HTML rendering engine (100% Java, also ported to managed .NET code). It is PDF-output-oriented and it does not support JavaScript. Despite the product name “HTML-to-PDF converter”, PD4ML is not intended for web sites capture. Our goal is on PDF side: it is to allow you to define PDF layouts of any level of complexity with a language everybody knows – HTML.

    If you plan to convert popular interactive web sites to PDF, most probably the result will disappoint you. A specialized PDF print driver will do the job better.

    in reply to: Evaluating PD4ML
    #27895

    Thanks for the insight. You’ve been very helpful. Thanks again.

Viewing 15 posts - 451 through 465 (of 4,333 total)