Drag[en]gine Script Module DragonScript Script API  1.0
ImageBorderCanvasCreator Class Reference

Canvas creator creating a single image bordered by 8 border images canvas. More...

Inheritance diagram for ImageBorderCanvasCreator:
CanvasCreator

Public Member Functions

BorderSize borderSize ()
 Calculate size of border elements. 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 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...
 
void setColorMatrix (ColorMatrix colorMatrix)
 Set color matrix to use for created canvas or null to use none. 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...
 

Detailed Description

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.

Stores 9 images:

  • corner top left
  • corner top right
  • corner bottom left
  • corner bottom right
  • side left
  • side top
  • side right
  • side bottom
  • center

create a canvas view with size and 9 image canvas added to it in the appropriate location. corners 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.

Author
Roland Pl├╝ss
Version
1.0

Member Function Documentation

§ borderSize()

BorderSize 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.

§ createCanvas()

Canvas createCanvas ( Point  size)

Create canvas for a specific widget size.

Implements CanvasCreator.

§ getColorMatrix()

ColorMatrix getColorMatrix ( )

Color matrix to use for created canvas or null to use none.

§ getImageCenter()

Image getImageCenter ( )

Center image.

§ getImageCornerBottomLeft()

Image getImageCornerBottomLeft ( )

Bottom left corner image.

§ getImageCornerBottomRight()

Image getImageCornerBottomRight ( )

Bottom right corner image.

§ getImageCornerTopLeft()

Image getImageCornerTopLeft ( )

Top left corner image.

§ getImageCornerTopRight()

Image getImageCornerTopRight ( )

Top right corner image.

§ getImageSideBottom()

Image getImageSideBottom ( )

Bottom side image.

§ getImageSideLeft()

Image getImageSideLeft ( )

Left side image.

§ getImageSideRight()

Image getImageSideRight ( )

Right side image.

§ getImageSideTop()

Image getImageSideTop ( )

Top side image.

§ new()

Create canvas creator.

§ setColorMatrix()

void setColorMatrix ( ColorMatrix  colorMatrix)

Set color matrix to use for created canvas or null to use none.

§ setImageCenter()

void setImageCenter ( Image  image)

Set center image.

§ setImageCornerBottomLeft()

void setImageCornerBottomLeft ( Image  image)

Set bottom left corner image.

§ setImageCornerBottomRight()

void setImageCornerBottomRight ( Image  image)

Set bottom right corner image.

§ setImageCornerTopLeft()

void setImageCornerTopLeft ( Image  image)

Set top left corner image.

§ setImageCornerTopRight()

void setImageCornerTopRight ( Image  image)

Set top right corner image.

§ setImageSideBottom()

void setImageSideBottom ( Image  image)

Set bottom side image.

§ setImageSideLeft()

void setImageSideLeft ( Image  image)

Set left side image.

§ setImageSideRight()

void setImageSideRight ( Image  image)

Set right side image.

§ setImageSideTop()

void setImageSideTop ( Image  image)

Set top side image.


The documentation for this class was generated from the following file: