It seems that Aspose PDF renderer does not recognize all of the CSS rules we apply to the HTML template we use.
List items should be displayed without bullets, progress bars in the lower right corner don't get populated (they should have green background if any width is given to the child element).
We are using the code we found in the documentation under "Convert HTML to PDF Format", which can be viewed in the file "code". The HTML template we use is in the "source.html" file.
Also we provide you with the example renders from the same HTML source using the Aspose.Pdf, Renderer (Grails plugin) and a free web tool called pdfcrowd.
We changed the HTML for the pdfcrowd render just to show that the progress bars in the lower right corner should display green color based on the percent completed (which is not visible in the Aspose render).
The HTML for aspose and renderer renders contains only blank progress bars, but in case they had any value inside, only the renderer would show the green background.
Information:
aspose-pdf-10.4.1
we use groovy: Here is how we call your API:
boolean htmlToPdf(InputStream inputStream, File output, String description) {
try {
com.aspose.pdf.HtmlLoadOptions htmloptions = new com.aspose.pdf.HtmlLoadOptions();
com.aspose.pdf.Document doc = new com.aspose.pdf.Document(inputStream, htmloptions);
mkdirs(output)
doc.save(output.absolutePath);
} catch (Exception ex) {
notifyOnConversionFailure("htmlToPdf failed on [${description}]", ex.getMessage())
log.fatal ex.getMessage()
}
}