[ 
https://issues.apache.org/jira/browse/FOP-3108?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17715846#comment-17715846
 ] 

Dave Roxburgh edited comment on FOP-3108 at 4/24/23 2:11 PM:
-------------------------------------------------------------

The issue was caused by patterns/shading used in the embedded page not being 
transformed for their new size and position on the target page.

xmlgraphics-fop-pdf-images - d127cbbc613e29d01861c0f44084ad136c2b640b

The attached patch_one_instance.diff will resolve the issues described in this 
ticket where the external document page is embedded in the target document one 
time only. Every embedded page instance references the same shading function 
and so it is most likely to be incorrect for all but the last one (for which it 
has been corrected).

Further work is required to properly duplicate the shading function and 
redirect references to the correct new function instance such that every 
external page instance refers to a shading function that has been modified to 
its own requirements.[^patch_one_instance.diff]


was (Author: JIRAUSER298677):
The attached patch_one_instance.diff will resolve the issues described in this 
ticket where the external document page is embedded in the target document one 
time only. Every embedded page instance references the same shading function 
and so it is most likely to be incorrect for all but the last one (for which it 
has been corrected).

Further work is required to properly duplicate the shading function and 
redirect references to the correct new function instance such that every 
external page instance refers to a shading function that has been modified to 
its own requirements.[^patch_one_instance.diff]

> fo:external-graphic - PDF with gradient component not displayed correctly 
> after scaling
> ---------------------------------------------------------------------------------------
>
>                 Key: FOP-3108
>                 URL: https://issues.apache.org/jira/browse/FOP-3108
>             Project: FOP
>          Issue Type: Bug
>    Affects Versions: 2.7, 2.8
>            Reporter: Mark Gibson 
>            Priority: Major
>         Attachments: img-with-gradient.pdf, out1.pdf, 
> patch_one_instance.diff, pdf-external-graphic-scaling-with-gradients.fo
>
>
> Using PDF-Images to inject a PDF as an image (fo:external-graphic). Image/PDF 
> has a gradient fill component.  When scaling the image, the gradient does not 
> display properly.  Resulting from shifted gradient to no gradient depending 
> on scale.
> *width scaling* All issues are found when scaling width by %
> *height scaling* Doesn't seem to even scale the image
>  
> Files attached for testing:
>  * *{{pdf-external-graphic-scaling-with-gradients.fo}}* - the FO file, with a 
> selection of image inclusions at different scales and scaling methods
>  * *{{img-with-gradient.pdf}}* - the PDF image being injected in to rendered 
> pdf, containing a gradient filled component.
>  * *{{out1.pdf}}* - the result of running fop on above
> Tested on Windows using FOP 2.7 and 2.8
> Command used to execute is
> {{fop.bat -fo pdf-external-graphic-scaling-with-gradients.fo -pdf out1.pdf}}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to