Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #33998

    Hello,

    Could you please explain how correlate PageSize and HtmlWidth settings of PD4ML class?
    Are there some rules specifying that, for example HtmlWidth should be less than PageSize’s width?
    Currently we have the following defaults in our code:
    pd4ml.setPageSize(new PageSize(595, 842)); pd4ml.setHtmlWidth(850);

    And now we face issues with that defaults for some html files, PD4ML just get stuck and doesn’t reply, no errors are logged. But if I set HtmlWidth to 849 which is still greater than PageSize’s width – everything works fine.

    We didn’t face such issues with PD4ML 4.0.9fx1, issue appears when I switch to PD4ML 4.0.9fx2-SNAPSHOT, so I also preparing a sample to report an issue. But I’m wondering if this is correct usage of PD4ML or not, so probably we should modify our defaults as well?

    #33999

    I’ve reported an issue describing the use case in more details.

    #34000

    Could you please explain how correlate PageSize and HtmlWidth settings of PD4ML class?

    PageSize is the target page format, which dimensions given in physical units (mm, in, pt etc). htmlWidth can bee seen as a width of a virtual “web browser” frame. htmlWidth is mapped to pageSize.width (minus horizontal margins).

    See /pd4ml-v4-programmers-manual/#customizing

    PD4ML just get stuck and doesn’t reply

    We’ll analyze and reply regarding the issue via the Helpdesk

    #34001

    PageSize is the target page format, which dimensions given in physical units (mm, in, pt etc). htmlWidth can bee seen as a width of a virtual “web browser” frame. htmlWidth is mapped to pageSize.width (minus horizontal margins).

    See /pd4ml-v4-programmers-manual/#customizing

    Thank you for the link, it made things more clear for me.
    So, as I understand, there is no any strict recommendation that HtmlWidth should be less than PageSize.width, it just impacts the scale how PDF is generated (the more HtmlWidth the smaller scale). Correct?

    #34002

    So, as I understand, there is no any strict recommendation that HtmlWidth should be less than PageSize.width, it just impacts the scale how PDF is generated (the more HtmlWidth the smaller scale). Correct?

    No. htmlWidth value should take into account only the HTML content. Let’s say you have a 1000px-wide HTML table. If you define htmlWidth=850, the not fitting 150px of the table are going to be cut in the rendered layout. The visible 850px will be mapped to the target paper width, independently if the format is A1 or A4 or A6.

    #34003

    Thank you for clarification.
    But it should not fail anyway, regardless of htmlWidth value passed. For now I see that different documents are not getting converted with various htmlWidth values (e.g. Doc1 gets converted fine with htmlWidth=842 but gets stuck with 850, Doc2 gets converted with htmlWidth=850 but gets stuck with 842 (or any other), and so on…). Are there any updates on this issue?

    #34004

    Of course, it should not fail or get stuck depending on htmlWidth value. We plan to address the issue tomorrow – in the last days there was no time frame for work on it. Sorry, this is taking so long.

    #34005

    Hello,

    Could you please provide an update on the issue?
    I’m trying daily snapshot builds, but the last one (4.0.9fx2-20201028-0554) still doesn’t work.

    Thanks,
    Nina

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

You must be logged in to reply to this topic.