Home Devices
New Blog Posts: Merging Reports - Part 1 and Part 2

HTML Export (17.03)

edited October 2016 in Devices
A few things:

1. When exporting to HTML some components, even though they are
Transparent, are saved as non-transparent GIFs. Seems to be TppLabel and
TppVariable controls. If they are on top of a non white background then
the output looks wrong. Is this a bug/oversight or is the only solution
to change the colour of the control in the report? Not even sure why
these controls get exported as images when TppDBText doesn't?

2. If you turn OFF "autosize" then the export seems to create a double
DIV, possibly by design, and the data in the inner one gets clipped on
the right. So in the example below the "left: 9px" attribute is the
culprit - removing it, or turning it off in Chrome's debugger, solves
the display problem.


300,00 €



3. I've been trying to understand how TppXHTMLStyle works so that,
perhaps, simple layout changes to the overall output could be loaded
from a CSS file. For example, it might be nice if the entire output was
centred in a browser (possibly by wrapping all the html in an outer
centred DIV ???). But I can't see how a true CSS file ever comes into
play. What is the correct mechanism for doing stuff like this?

TIA, Paul

Comments

  • edited October 2016
    Hi Paul,

    - There are only a few standard web fonts, if those are not used, then text
    is generated as a graphic. For details check out
    TppXHTMLUtilities.IsStandardWebFont in ppXHTMLUtilities.pas

    - Label, Variable, DBText, Memo, DBMemo all generate DrawText commands. The
    Html Device just process the DrawText commands. However there are many cases
    depending on characteristics of the text: AutoSize, Mutliline, Transparent,
    Border, Fill, Font etc.

    - I researched the Transparent issue and have created a patch for RB 17.03.

    - If you have other issues, please email support@ with an example.

    - the CSS appears at the top of the html file, there is no separate CSS
    file. The ppXHTMLStyle.pas contains the classes that generate the html. If
    you have specific questions please email support@




    Best regards,

    -
    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
This discussion has been closed.