javascript - How to mimic HTML layout with pdfmake -
i having dynamically generated html layout mimic in pdf report, having trouble columns specification. assume html looks this:
+------------------------------------------------------+ | | | section 1 | | | +------------------------+-----------------------------+ | | | | section 2 | section 3 | | | | +------------------------+-----------------------------+ | | | section 4 | | | +---------------+-------------------+------------------+ | | | | | section 5 | section 6 | section 7 | | | | | +---------------+-------------------+------------------+
and content of resulting pdf should arranged same. now, since don't know actual layout in advance, looping section section , creating column every section. @ point, able calculate width of column. problem is, since column, @ same row, , make wrap, columns add 100% width take separate row. there way implement in makepdf, or should take different approach?
i use wkhtmltopdf
render pdf's html. if want that's really close how html look, go wkhtmltopdf
.
Comments
Post a Comment