Image resize and rotate [message #677404] |
Wed, 08 June 2011 12:27 |
Stefano Messages: 2 Registered: June 2011 |
Junior Member |
|
|
Hello,
I'm trying to rotate an Image (GraphicsAlgorithm extension) that I create with the following code (mainly taken from your tutorial):
ContainerShape containerShape = peCreateService.createContainerShape(targetDiagram, true);
GraphicsAlgorithm visibleGA;
Rectangle invisibleRectangle;
{
invisibleRectangle = gaService.createRectangle(containerShape);
gaService.setLocationAndSize(invisibleRectangle, context.getX(), context.getY(), width + 2*xBorder, height + 2*yBorder);
Image visibleGA = gaService.createImage(container, SLDImageProvider.IMG_CONTACTOR);
visibleGA.setStretchH(true);
visibleGA.setStretchV(true);
visibleGA.setProportional(true);
gaService.setLocationAndSize(visibleGA, xBorder, yBorder, width, height);
}
This code does not seem to enable the resizing of the Image nor the stretching of the image to the height and width dimensions.
Could you possibly help me understand how to allow the resizing?
Also I'd like to understand how to rotate the image: if there is standard way to do this, could you give a example please?
Thank you very much.
S
|
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03601 seconds