knyllers Posted November 14, 2011 Share Posted November 14, 2011 Hello,I have a report created in ireport 4.1.1 that is being exported both as pdf and html.I have a page footer that contains an image as background with some text as foreground. The pdf displays this ok, but the html won't display the image, just the text. The image is seen as a thin line in the left margin, below the text. I would assume that it's fairly common to have a text over an image, so I'm hoping there's a simple solution to this. Thanks for helping.Regards,Henrik Link to comment Share on other sites More sharing options...
satyadoorva Posted November 14, 2011 Share Posted November 14, 2011 <background> <band height="822" splitType="Stretch"> <image> <reportElement x="0" y="5" width="575" height="812"/> <imageExpression><![CDATA["/images/watermark.jpg"]]></imageExpression> </image> </band> </background> try and let me know if it helps. Thanks Link to comment Share on other sites More sharing options...
knyllers Posted November 16, 2011 Author Share Posted November 16, 2011 Thanks for the response,the ireport compiler won't let me put a <background> tag either outside nor inside the <band> tag. This is however a smaller issue. Thanks for the help though.I have some other problems with the generated html as well.A text field that is defined with height 20 looses this feature when exporting to html, resulting in the text box being as high as the font size. This causes ygpqj letters not showing their bottom half. If I add height 20px to the generated html, the overflow stops working and longer texts get cut.Is there a problem with the html export or do I need specific attributes set for it to work properly?For instance, this jrxml: <textField> <reportElement x="470" y="0" width="69" height="20" forecolor="#666666"/> <textElement> <font fontName="DejaVu Sans" size="9"/> </textElement> <textFieldExpression><![CDATA[$F{baggage}]]></textFieldExpression></textField>Becomes this html: <td><p style="overflow: hidden; line-height: 1.0; text-indent: 0px; "><span style="font-family: 'DejaVu Sans', Arial, Helvetica, sans-serif; color: #666666; font-size: 9px;">20Kg</span></p></td>Any ideas?Regards,Henrik Link to comment Share on other sites More sharing options...
svenn Posted November 16, 2011 Share Posted November 16, 2011 The HTML exporter builds everything as a table. If you report is to complicated it may not work the way you would expect it to.See herehttp://jasperforge.org//uploads/publish/jasperreportswebsite/trunk/faq.html#FAQ9 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now