[
https://issues.apache.org/jira/browse/COCOON-2133?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12555291#action_12555291
]
Robin Wyles commented on COCOON-2133:
-------------------------------------
I'd be happy to provide a test-case but I can't see how to set one up to test a
Reader. Looking at SitemapComponentTestCase I don't see a corresponding "read"
method and I can't find any test-cases for other readers in any other blocks.
If you can let me know how I might implement this test-case then I'll write it.
In the meantime I attach a revised patch that fixes a bug with the previous
patch where scaling with allowEnlarge property would be ignored when only one
dimension needs to be reduced in size.
> Addition of "allow-enlarge" parameter to ImageOp resize operation
> -----------------------------------------------------------------
>
> Key: COCOON-2133
> URL: https://issues.apache.org/jira/browse/COCOON-2133
> Project: Cocoon
> Issue Type: Improvement
> Components: Blocks: ImageOp
> Affects Versions: 2.1.11, 2.2-dev (Current SVN)
> Reporter: Robin Wyles
> Priority: Minor
> Attachments: ResizeOperation.patch, RevisedResizeOperationPatch.txt
>
>
> The addition of an "allow-enlarge" parameter to the resize operation allows
> the user to control whether an image should be enlarged by the operation.
> This new parameter is declared in the sitemap like so:
> <map:read type="imageop" src="image.jpg">
> <map:parameter name="prefix-preserve-ratio" value="true"/>
> <map:parameter name="prefix-allow-enlarge" value="false"/>
> <map:parameter name="prefix-width" value="320"/>
> <map:parameter name="prefix-height" value="240"/>
> </map:read>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.