Drag[en]gine Script Module DragonScript
1.23
|
Canvas creator creating a single image bordered by 8 border images canvas. More...
Public Member Functions | |
BorderSize | borderSize () |
Calculate size of border elements. More... | |
CanvasCreator | copyCanvasCreator () |
Create copy of canvas creator. More... | |
Canvas | createCanvas (Point size) |
Create canvas for a specific widget size. More... | |
ColorMatrix | getColorMatrix () |
Color matrix to use for created canvas or null to use none. More... | |
Image | getImageAttachBottom () |
Bottom attach image. More... | |
Image | getImageAttachLeft () |
Left attach image. More... | |
Image | getImageAttachRight () |
Right attach image. More... | |
Image | getImageAttachTop () |
Top attach image. More... | |
Image | getImageCenter () |
Center image. More... | |
Image | getImageCornerBottomLeft () |
Bottom left corner image. More... | |
Image | getImageCornerBottomRight () |
Bottom right corner image. More... | |
Image | getImageCornerTopLeft () |
Top left corner image. More... | |
Image | getImageCornerTopRight () |
Top right corner image. More... | |
Image | getImageSideBottom () |
Bottom side image. More... | |
Image | getImageSideLeft () |
Left side image. More... | |
Image | getImageSideRight () |
Right side image. More... | |
Image | getImageSideTop () |
Top side image. More... | |
ImageBorderCanvasCreator | new () |
Create canvas creator. More... | |
ImageBorderCanvasCreator | new (ImageBorderCanvasCreator creator) |
Create copy of canvas creator. More... | |
void | setColorMatrix (ColorMatrix colorMatrix) |
Set color matrix to use for created canvas or null to use none. More... | |
void | setImageAttachBottom (Image image) |
Set bottom attach image. More... | |
void | setImageAttachLeft (Image image) |
Set left attach image. More... | |
void | setImageAttachRight (Image image) |
Set right attach image. More... | |
void | setImageAttachTop (Image image) |
Set top attach image. More... | |
void | setImageCenter (Image image) |
Set center image. More... | |
void | setImageCornerBottomLeft (Image image) |
Set bottom left corner image. More... | |
void | setImageCornerBottomRight (Image image) |
Set bottom right corner image. More... | |
void | setImageCornerTopLeft (Image image) |
Set top left corner image. More... | |
void | setImageCornerTopRight (Image image) |
Set top right corner image. More... | |
void | setImageSideBottom (Image image) |
Set bottom side image. More... | |
void | setImageSideLeft (Image image) |
Set left side image. More... | |
void | setImageSideRight (Image image) |
Set right side image. More... | |
void | setImageSideTop (Image image) |
Set top side image. More... | |
void | setParameter (String name, Object value) |
Set parameter. More... | |
Public Member Functions inherited from Dragengine.Gui.CanvasCreators.DefaultCanvasCreator | |
DefaultCanvasCreator | new (DefaultCanvasCreator creator) |
Create copy of canvas creator. More... | |
Protected Member Functions | |
void | addImageCanvas (CanvasView content, Image image, int x, int y, int width, int height) |
Convenience method to create and add image canvas. More... | |
Canvas creator creating a single image bordered by 8 border images canvas.
Creates an image canvas with an image stretched to fit the entire widget with 4 corner and 4 side canvas image located around it. Optionally up to 4 attach images can be used to add non-stretching middle sections to sides. Think of of a cartoon speech bubble. The section pointing down at the speaking actor would be an attach image.
Stores up to 13 images:
create a canvas view with size and up to 13 image canvas added to it in the appropriate location. corners and attaches are all fixed size. sides are stretched to touch the respective corners. center is stretched to touch all sides. if any image is null it is not used and assumed to have 0 size.
|
protected |
Convenience method to create and add image canvas.
BorderSize Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.borderSize | ( | ) |
Calculate size of border elements.
Returns the minimum and maximum width and height of side and corner images if existing for the appropriate border side.
CanvasCreator Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.copyCanvasCreator | ( | ) |
Create copy of canvas creator.
Reimplemented from Dragengine.Gui.CanvasCreators.DefaultCanvasCreator.
Create canvas for a specific widget size.
Reimplemented from Dragengine.Gui.CanvasCreators.DefaultCanvasCreator.
ColorMatrix Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getColorMatrix | ( | ) |
Color matrix to use for created canvas or null to use none.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageAttachBottom | ( | ) |
Bottom attach image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageAttachLeft | ( | ) |
Left attach image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageAttachRight | ( | ) |
Right attach image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageAttachTop | ( | ) |
Top attach image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageCenter | ( | ) |
Center image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageCornerBottomLeft | ( | ) |
Bottom left corner image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageCornerBottomRight | ( | ) |
Bottom right corner image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageCornerTopLeft | ( | ) |
Top left corner image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageCornerTopRight | ( | ) |
Top right corner image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageSideBottom | ( | ) |
Bottom side image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageSideLeft | ( | ) |
Left side image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageSideRight | ( | ) |
Right side image.
Image Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.getImageSideTop | ( | ) |
Top side image.
ImageBorderCanvasCreator Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.new | ( | ) |
Create canvas creator.
Reimplemented from Dragengine.Gui.CanvasCreators.DefaultCanvasCreator.
ImageBorderCanvasCreator Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.new | ( | ImageBorderCanvasCreator | creator | ) |
Create copy of canvas creator.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setColorMatrix | ( | ColorMatrix | colorMatrix | ) |
Set color matrix to use for created canvas or null to use none.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageAttachBottom | ( | Image | image | ) |
Set bottom attach image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageAttachLeft | ( | Image | image | ) |
Set left attach image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageAttachRight | ( | Image | image | ) |
Set right attach image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageAttachTop | ( | Image | image | ) |
Set top attach image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageCenter | ( | Image | image | ) |
Set center image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageCornerBottomLeft | ( | Image | image | ) |
Set bottom left corner image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageCornerBottomRight | ( | Image | image | ) |
Set bottom right corner image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageCornerTopLeft | ( | Image | image | ) |
Set top left corner image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageCornerTopRight | ( | Image | image | ) |
Set top right corner image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageSideBottom | ( | Image | image | ) |
Set bottom side image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageSideLeft | ( | Image | image | ) |
Set left side image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageSideRight | ( | Image | image | ) |
Set right side image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setImageSideTop | ( | Image | image | ) |
Set top side image.
void Dragengine.Gui.CanvasCreators.ImageBorderCanvasCreator.setParameter | ( | String | name, |
Object | value | ||
) |
Set parameter.
Supported parameters: | name | value | Setter | | center | Image | setImageCenter | | sideLeft | Image | setImageSideLeft | | sideTop | Image | setImageSideTop | | sideBottom | Image | setImageSideBottom | | sideRight | Image | setImageSideRight | | cornerTopLeft | Image | setImageCornerTopLeft | | cornerTopRight | Image | setImageCornerTopRight | | cornerBottomLeft | Image | setImageCornerBottomLeft | | cornerBottomRight | Image | setImageCornerBottomRight | | attachLeft | Image | setImageAttachLeft | | attachTop | Image | setImageAttachTop | | attachBottom | Image | setImageAttachBottom | | attachRight | Image | setImageAttachRight | | colorMatrix | ColorMatrix | setColorMatrix |
Reimplemented from Dragengine.Gui.CanvasCreators.DefaultCanvasCreator.