Community Tip - You can subscribe to a forum, label or individual post and receive email notifications when someone posts a new topic or reply. Learn more! X
How do I use Styler to force oversized graphics to fit within the width and/or height of a page?
I cannot edit the graphic or have the authors/illustrators resize the graphic files.
I am using the XSL Print mode and understand that it is no longer supported.
I cannot use the APP Print mode because I've already made custom XSL changes and do not have time to learn how to make custom changes with the APP.
I am using ArborText Editor with Styler Release 7.1.
I have already tried the following XSL, but it has no effect:
<xsl:attribute name="width">8in</xsl:attribute>
<xsl:attribute name="content-width">scale-down-to-fit</xsl:attribute>
<xsl:attribute name="scaling">uniform</xsl:attribute>
I can force graphics to a particular size with the following, but it blows up small graphics:
<xsl:attribute name="width">8in</xsl:attribute>
<xsl:attribute name="content-width">scale-to-fit</xsl:attribute>
<xsl:attribute name="scaling">uniform</xsl:attribute>
Thanks,
-James
I'm not familiar with the XSL publishing, do you mean the XSL-FO publishing feature that was grandfathered about 10 years ago? Both underlying print engines (FOSI and APP) support the feature you need, so there is hope 🙂
Yes, XSL-FO. I apologize for the confusion.
Here are some tips then:
1. How it should work in XSL-FO: https://stackoverflow.com/questions/6220316/scale-down-to-fit-an-image-in-fop
2. What the underlying FOSI <putgraph> supports: http://support.ptc.com/cs/help/arbortext_hc/ae61_hc/index.jspx?id=help357&action=show
Between those two things you should be able to figure this out. First try the out-of-the-box XSL-FO method and if it isn't working, have a look in the ACL code that does the FOSI transformation to find where the <putgraph> is being generated and if it supports the scaling features you require.
Thanks for your replay Gareth!
Unfortunately, the XSL-FO solution does not work. I did originally use the "scale-down-to-fit" value as I had use that previously with the Apache FOP. However, it had no effect.
And while I am not experienced with FOSI, based on the documentation that you provided, it does seem that FOSI does not support a "scale-down-to-fit" for individual graphics. Perhaps this is why the XSL-FO solution does not work? Because ArborText never needed to support it for FOSI?
I'm also not seeing how this could be done with APP.