Hey Christian: You have to scale the box appropriately for the image. In other words, set width and height proportionately to the image's width and height.
This pretty much always works for me. Btw, if the image exceeds the preset page margins, problems can sometimes occur. See if that helps. jw -----Original Message----- From: Beer, Christian [mailto:[EMAIL PROTECTED]] Sent: Friday, October 26, 2001 2:30 AM To: '[EMAIL PROTECTED]' Subject: AW: Problems with images (scaling)... Hi Jim! That worked if the image was too wide! But if it is too tall the image isn't rendered! It is just gone! Ist that a bug in fop? Christian -----Ursprüngliche Nachricht----- Von: Jim Wright [mailto:[EMAIL PROTECTED]] Gesendet: Freitag, 26. Oktober 2001 00:41 An: [EMAIL PROTECTED] Betreff: RE: Problems with images (scaling)... Put the external graphic inside of a properly-sized block container. Skip the scaling, content-height, and content-width stuff. .png and .gif files work fine with this approach. DPI is increased appropriately as image is scaled down, which helps make high-resolution .gifs out of low-res ones. Hope that helps! jw -----Original Message----- From: Beer, Christian [mailto:[EMAIL PROTECTED]] Sent: Thursday, October 25, 2001 4:51 AM To: Fop-liste (E-Mail) Subject: Problems with images (scaling)... I want to put a logo on a letter using FOP. The logo is quite big, but it shall be scaled to fit into 25mm x 85mm. I tried the following code: ----------------------------- <fo:external-graphic width="25mm" height="85mm" src="{CompanyLogo/@src}" scaling="uniform" content-height="scale-to-fit" content-width="scale-to-fit"/> ----------------------------- but FOP says: ----------------------------- Error in content-height property value 'scale-to-fit': org.apache.fop.fo.expr.PropertyException: No conversion defined ----------------------------- the XSL-Dokumentation says: ----------------------------- [...] 7.13.2. "content-height" XSL Definition: Value: auto | scale-to-fit | <length> | <percentage> | inherit Initial: auto Applies to: fo:external-graphic, fo:instream-foreign-object Inherited: no Percentages: intrinsic height Media: visual Values have the following meanings: auto The content-height should be the intrinsic content-height. scale-to-fit A size of the content-height equal to the height of the viewport. This value implies a certain scaling factor to be applied onto the content. [...] ----------------------------- So if I doesn't use the content-height/width attributes, the logo is printed in the requested width but its original height!! That doesn't look very nice! ;-) Please help me! Thanks in advance Christian __________________________________________________ DIRON Wirtschaftsinformatik GmbH & Co. KG Christian Beer ([EMAIL PROTECTED]) Daimlerweg 39-41 Tel. : +49(251)979-200 48163 Muenster Fax : +49(251)979-2020 Germany Email: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, email: [EMAIL PROTECTED]