Class: GraphicsGD
Source Location: /GraphicsGD.php
TeeBase
|
--GraphicsGD
GraphicsGD class
Author(s):
Version:
Copyright:
- (c) 1995-2013 by Steema Software SL. All Rights Reserved. <info@steema.com>
|
|
|
Child classes:
|
Inherited Variables
|
Inherited Methods
|
Class Details
Class Variables
Class Methods
static method applyDark [line 3373]
static Color applyDark(
c
$c, howMuch
$howMuch)
|
|
Converts the Color parameter to a darker color. The HowMuch parameter indicates the quantity of dark increment. It is used by Bar Series and Pie Series to calculate the right color to draw Bar sides and Pie 3D zones.
Tags:
Parameters:
static method doReflection [line 3377]
static void doReflection(
$im)
|
|
Tags:
Parameters:
static method getDefaultPattern [line 3230]
static HatchStyle getDefaultPattern(
index
$index)
|
|
Returns a valid Windows Brush Style from anpalette of many possible Brush styles.
Tags:
Parameters:
static method getScreenHeight [line 3426]
static int getScreenHeight(
)
|
|
Returns the height, in pixels, of the Chart Panel. It should be used when using Canvas methods to draw relative to the Panel height. Note: You should NOT use TChart.Height.
Tags:
static method getScreenWidth [line 3435]
static int getScreenWidth(
)
|
|
Returns the width, in pixels, of the Chart Panel.
Tags:
static method pointAtDistance [line 3087]
static void pointAtDistance(
$From,
$To,
$distance)
|
|
Tags:
Parameters:
static method pointInEllipse [line 3130]
static boolean pointInEllipse(
p
$p, rect
$rect)
|
|
Returns true if point P is inside the ellipse bounded by Rect.
Tags:
Parameters:
static method pointInHorizTriangle [line 3078]
static boolean pointInHorizTriangle(
p
$p, y0
$y0, y1
$y1, x0
$x0, x1
$x1)
|
|
Returns true if point P is inside the horizontal triangle.
Tags:
Parameters:
static method pointInPolygon [line 3148]
static boolean pointInPolygon(
p
$p, poly
$poly)
|
|
Returns true if point P is inside Poly polygon.
Tags:
Parameters:
static method pointInRect [line 3046]
static boolean pointInRect(
rect
$rect, x
$x, y
$y)
|
|
Obsolete. Please use Rectangle.<!-- -->Contains method.
Tags:
Parameters:
static method pointInTriangle [line 3061]
static boolean pointInTriangle(
p
$p, x0
$x0, x1
$x1, y0
$y0, y1
$y1)
|
|
Returns true if point P is inside the vert triangle of x0y0, midxY1, x1y0.
Tags:
Parameters:
static method rectCenter [line 3311]
static void rectCenter(
$r)
|
|
Tags:
Parameters:
static method _pointInEllipse [line 3119]
static boolean _pointInEllipse(
p
$p, left
$left, top
$top, right
$right, bottom
$bottom)
|
|
Returns true if point P is inside the ellipse bounded by Left, Top, Right, Bottom.
Tags:
Parameters:
constructor GraphicsGD [line 105]
GraphicsGD GraphicsGD(
IBaseChart
$c, integer
$width, integer
$height)
|
|
Creates a new Graphics object
Tags:
Parameters:
destructor __destruct [line 135]
method arc [line 2483]
method arrow [line 268]
void arrow(
filled
$filled, fromPoint
$fromPoint, toPoint
$toPoint, headWidth
$headWidth, headHeight
$headHeight, z
$z)
|
|
Draws a line with an arrow head of ArrowWidth and ArrowHeight dimensions in pixels.
Tags:
Parameters:
method calc3DPoint [line 497]
void calc3DPoint(
$x,
$y, [
$z = 0])
|
|
Tags:
Parameters:
method calc3DPos [line 395]
Point calc3DPos(
x
$x, y
$y, z
$z)
|
|
Calculates and returns the XY position in pixels of the XYZ 3D coordinate. Can be used when custom drawing using 3D XYZ coordinates are returned from the axes or not.
Tags:
Parameters:
method calc3DPosDouble [line 429]
void calc3DPosDouble(
$x,
$y,
$z,
$pointDouble)
|
|
Calculates and returns the XY position as double of the XYZ 3D coordinate. Can be used when custom drawing using 3D XYZ coordinates are returned from the axes or not. Returns PointDouble
Tags:
Parameters:
method calcPerspective [line 501]
void calcPerspective(
$r)
|
|
Tags:
Parameters:
method calcTrigValues [line 516]
method changed [line 548]
method clipCube [line 1018]
void clipCube(
rect
$rect, minZ
$minZ, maxZ
$maxZ)
|
|
Creates a cubic Windows GDI clipping region.
Tags:
Parameters:
method clipPolygon [line 609]
void clipPolygon(
polygonPoints
$polygonPoints)
|
|
Creates a Windows GDI clipping region and selects it into TChart.<!-- -->Canvas device context handle.
Tags:
Overridden in child classes as:
- Graphics3DFlex::clipPolygon()
Parameters:
method clipRectangle [line 578]
method cone [line 628]
void cone(
vertical
$vertical, r
$r, z0
$z0, z1
$z1, darkSides
$darkSides, [conePercent
$conePercent = 0])
|
|
Paints a cone with Cone Percent. Use ONLY with OPENGL</b>. This parameter varies the apex size as a percentage of the base.
Tags:
Parameters:
method convexHull [line 2677]
Calculates the boundary points of the convex hull of a set of 2D xy points. Original
Tags:
Parameters:
method createImage [line 1056]
Creates and initialize the image
Tags:
method cube [line 931]
void cube(
left
$left, top
$top, right
$right, bottom
$bottom, z0
$z0, z1
$z1, darkSides
$darkSides)
|
|
Draws a Cube with Dark Sides.
Tags:
Overridden in child classes as:
- CanvasSVG::cube()
- Draws a Cube with Dark Sides.
Parameters:
method cuber [line 916]
void cuber(
$rect,
$z0,
$z1,
$darkSides)
|
|
Tags:
Parameters:
method culling [line 1046]
method cylinder [line 641]
void cylinder(
vertical
$vertical, r
$r, z0
$z0, z1
$z1, darkSides
$darkSides)
|
|
Draws cylinder toggle Boolean for vertical or horizontal cylinder.
Tags:
Parameters:
method doRev [line 1083]
method draw [line 211]
void draw(
r
$r, image
$image, mode
$mode, [transparent
$shapeBorders = null],
$transparent)
|
|
Paints the image in rectangle r.
Tags:
Overridden in child classes as:
- CanvasSVG::draw()
Parameters:
method drawBeziers [line 341]
Draws Bezier splines for the Point array p
Tags:
Parameters:
method drawBeziersRect [line 332]
void drawBeziersRect(
z
$z, p
$p)
|
|
Draws Bezier splines for the Point array p at displacement z
Tags:
Parameters:
method drawRoundedBorders [line 2377]
method ellipse [line 1134]
method ellipsePoints [line 1240]
void ellipsePoints(
$p0,
$p1)
|
|
Tags:
Parameters:
method ellipseRect [line 1098]
Draws an Ellipse bounding Rectangle r.
Tags:
Parameters:
method ellipseRectZ [line 1108]
void ellipseRectZ(
r
$r, z
$z)
|
|
Ellipse bounding Rectangle r at z depth.
Tags:
Parameters:
method ellipseRectZAngle [line 1251]
void ellipseRectZAngle(
r
$r, z
$z, [angle
$angle = 0])
|
|
Ellipse bounding rectangle r with Z offset at angle.
Tags:
Parameters:
method fontTextHeight [line 1263]
int fontTextHeight(
f
$f)
|
|
Determines the Font Height to be used for outputted text when using the Drawing.
Tags:
Parameters:
method getBackColor [line 1797]
Sets / returns the color used to fill spaces when displaying text or filling with brushes of different style other than bsSolid. Brush.Visible must be set to true.
Tags:
method getBrush [line 2826]
Determines the kind of brush used to fill the Canvas draw rectangle background. The Brush.Visible method must be set to true.
Tags:
method getColorPaletteLength [line 2876]
void getColorPaletteLength(
)
|
|
Tags:
method getDefaultColor [line 2853]
Color getDefaultColor(
index
$index)
|
|
Returns a color from global ColorPalette array variable.
Tags:
Parameters:
method getDirty [line 2880]
method getFont [line 2891]
Determines the Font for outputted text when using the Drawing Canvas.
Tags:
method getFontDPI [line 2616]
method getFontHeight [line 2909]
Defines the Height of the Font in pixels.
Tags:
method getImageInterlace [line 3347]
void getImageInterlace(
)
|
|
Tags:
method getImageReflection [line 3355]
void getImageReflection(
)
|
|
Tags:
method getIZoomfactor [line 3167]
method getMetafiling [line 2917]
method getMonochrome [line 2925]
method getPen [line 2955]
Indicates the kind of pen used to draw Canvas lines.
Tags:
method getRotationCenter [line 3001]
Sets the Pixel location (using X,Y,Z) of the centre of rotation for use with the Aspect Rotation and Elevation properties.
Tags:
method getSmoothingMode [line 3267]
boolean getSmoothingMode(
)
|
|
The anti-alias mode for the Graphics Pen when Custom drawing. For example: AntiAlias - Specifies antialiased rendering. Default - Specifies the default mode. HighQuality - Specifies high quality, low speed rendering. HighSpeed - Specifies high speed, low quality rendering. Invalid - Specifies an invalid mode.
Tags:
method getSupports3DText [line 3297]
boolean getSupports3DText(
)
|
|
Returns if Canvas supports 3D Text or not.
Tags:
method getSupportsFullRotation [line 3306]
boolean getSupportsFullRotation(
)
|
|
Returns if Canvas can do rotation and elevation of more than 90 degree.
Tags:
method getTextAlign [line 2937]
void getTextAlign(
value
0)
|
|
Gets / Sets the alignment used when displaying text using TextOut or TextOut3D. Default value: Near
Tags:
Parameters:
method getXCenter [line 3183]
The X coordinate of the pixel location of the center of the 3D Canvas. The origin of the pixel coordinate system is in the top left corner of the parent window.
Tags:
method getYCenter [line 3207]
The Y coordinate of the pixel location of the center of the 3D Canvas. The origin of the pixel coordinate system is in the top left corner of the parent window.
Tags:
method horizontalLine [line 1533]
method imagegradientellipse [line 799]
method imagegradientellipsealpha [line 829]
method initWindow [line 1267]
void initWindow(
$a,
$r,
$maxDepth)
|
|
Tags:
Parameters:
method internalApplyDark [line 1295]
void internalApplyDark(
$c,
$quantity)
|
|
Tags:
Parameters:
method line [line 1311]
method lineTo [line 1402]
Draws a line to Point with z depth offset.
Tags:
Parameters:
method moveTo [line 1466]
Sets the value of PenPos to Point p before calling LineTo.
Tags:
Parameters:
method moveTo3D [line 1500]
Sets the value of PenPos to 3D Point p before calling LineTo.
Tags:
Parameters:
method moveToXY [line 1456]
void moveToXY(
x
$x, y
$y)
|
|
Sets the value of PenPos to x and y co-ordinates before calling LineTo.
Tags:
Parameters:
method moveToXYZ [line 1478]
void moveToXYZ(
x
$x, y
$y, z
$z)
|
|
Sets the value of PenPos to x, y and z co-ordinates before calling LineTo.
Tags:
Parameters:
method moveToZ [line 1490]
void moveToZ(
p
$p, z
$z)
|
|
Sets the value of PenPos to Point p with z depth offset before calling LineTo.
Tags:
Parameters:
method OrientRectangle [line 1623]
void OrientRectangle(
$R)
|
|
Parameters:
method outlinedBox [line 1592]
void outlinedBox(
integer
$x1, integer
$y1, integer
$x2, integer
$y2, Color
$color0, Color
$color1)
|
|
Draw a filled gray box with thick borders and darker corners.
Tags:
Overridden in child classes as:
- CanvasSVG::outlinedBox()
Parameters:
method paintBevel [line 1644]
void paintBevel(
$bevel,
$rect,
$width,
$one,
$two)
|
|
Tags:
Parameters:
method pie [line 1688]
void pie(
xCenter
$xCenter, yCenter
$yCenter, xRadius
$xOffset, yRadius
$yOffset, z0
$xRadius, z1
$yRadius, startAngle
$z0, endAngle
$z1, darkSides
$startAngle, drawSides
$endAngle, donutPercent
$darkSides,
$drawSides,
$donutPercent,
$bevelPercent,
$edgeStyle,
$last)
|
|
Draws a 3D Pie slice using start Angle and end Angle and donut percent.
Tags:
Overridden in child classes as:
- CanvasSVG::pie()
Parameters:
method plane [line 1833]
void plane(
p1
$p1, p2
$p2, z0
$z0, z1
$z1)
|
|
Draws a polygon (Point p1, Point p2) at Z depth offset.
Tags:
Overridden in child classes as:
- CanvasSVG::plane()
Parameters:
method planeFour3D [line 1866]
void planeFour3D(
z0
$z0, z1
$z1, p
$p)
|
|
Draws a polygon of four points.
Tags:
Parameters:
method pointFromCircle [line 3319]
void pointFromCircle(
$rectBounds,
$degrees,
$zPos, [
$clockWise = false])
|
|
Tags:
Parameters:
method PointToStr [line 3439]
method polygon [line 1937]
method polygonFourDouble [line 2018]
method polygonPoints [line 2012]
void polygonPoints(
$p0,
$p1,
$p2)
|
|
Tags:
Parameters:
method polygonZ [line 2005]
void polygonZ(
z
$z, p
$p)
|
|
Draws a polygon with z position offset.
Tags:
Parameters:
method polyLine [line 2113]
method printCentered [line 2188]
void printCentered(
Image
$img, integer
$py, Color
$color, string
$text, string
$fontFileName)
|
|
Print text centered horizontally on the image.
Tags:
Parameters:
method printDiagonal [line 2203]
void printDiagonal(
Image
$img, integer
$px, integer
$py, Color
$text, string
$angle)
|
|
Print text in diagonal.
Tags:
Overridden in child classes as:
- CanvasSVG::printDiagonal()
Parameters:
method printText [line 2136]
void printText(
Image
$img, integer
$px, integer
$py, Color
$text, [string
$align = -1], string
5, bitfield
6)
|
|
Print text.
Tags:
Parameters:
method projection [line 2226]
void projection(
maxDepth
$maxDepth, r
$r)
|
|
Internal use. Calculates the projection co-ordinates for rectangle Bounds.
Tags:
Parameters:
method pyramid [line 1728]
void pyramid(
vertical
$vertical, left
$left, top
$top, right
$right, bottom
$bottom, z0
$z0, z1
$z1, darkSides
$darkSides)
|
|
Draws a vertical or horizontal Pyramid with optional dark shaded sides.
Tags:
Parameters:
method pyramidRect [line 1711]
void pyramidRect(
vertical
$vertical, r
$r, z0
$z0, z1
$z1, darkSides
$darkSides)
|
|
Draws a vertical or horizontal Pyramid with optional dark shaded sides.
Tags:
Parameters:
method pyramidTrunc [line 1815]
void pyramidTrunc(
Rectangle
$r, int
$startZ, int
$endZ, int
$truncX, int
$truncZ)
|
|
Draws a pyramid with a truncated apex of variable thickness.
Tags:
Parameters:
method rectangle [line 2236]
method rectangleWithZ [line 2319]
method rectangleY [line 2337]
void rectangleY(
left
$left, top
$top, right
$right, z0
$z0, z1
$z1)
|
|
Horizontal Rectangle from Left to Right, from Z0 to Z1 position, at Top Y.
Tags:
Overridden in child classes as:
- CanvasSVG::rectangleY()
Parameters:
method rectangleZ [line 2311]
void rectangleZ(
left
$left, top
$top, bottom
$bottom, z0
$z0, z1
$z1)
|
|
Horizontal Rectangle from Left to Right, from Z0 to Z1 position, at Top Y.
Tags:
Overridden in child classes as:
- CanvasSVG::rectangleZ()
Parameters:
method rectFromPolygon [line 3013]
Returns the bounding rectangle for a given array of XY points.
Tags:
Parameters:
method rotateLabel [line 2510]
void rotateLabel(
x
$x, y
$y, z
$z, text
$text, rotDegree
$rotDegree)
|
|
Draws a rotated text String at the specified x,y and z coordinates with the RotDegree rotation angle. RotDegree values must be between 0 and 360. The string is drawn on the Chart Drawing Canvas.
Tags:
Overridden in child classes as:
- Graphics3DFlex::rotateLabel()
- Graphics3DHTML5::rotateLabel()
Parameters:
method rotateRectangle [line 2529]
void rotateRectangle(
$r,
$angle)
|
|
Tags:
Parameters:
method roundrectangle [line 2348]
void roundrectangle(
$x1,
$y1,
$x2,
$y2,
$radius, [
$filled = 1])
|
|
Overridden in child classes as:
- CanvasSVG::roundrectangle()
Parameters:
method setBackColor [line 1801]
void setBackColor(
$value)
|
|
Tags:
Parameters:
method setBrush [line 2840]
void setBrush(
value
$value)
|
|
Determines the kind of brush used to fill the Canvas draw rectangle background. The Brush.Visible method must be set to true.
Tags:
Parameters:
method setColorPalette [line 2862]
void setColorPalette(
palette
$palette)
|
|
Specifies a color from global ColorPalette array variable.
Tags:
Parameters:
method setDirty [line 2884]
method setFont [line 2900]
void setFont(
value
$value)
|
|
Determines the Font for outputted text when using the Drawing Canvas.
Tags:
Parameters:
method setGraphics [line 2913]
void setGraphics(
$value)
|
|
Tags:
Parameters:
method setImageInterlace [line 3351]
void setImageInterlace(
$vlaue)
|
|
Tags:
Parameters:
method setImageReflection [line 3359]
void setImageReflection(
$value)
|
|
Tags:
Parameters:
method setIZoomfactor [line 3171]
void setIZoomfactor(
$value)
|
|
Tags:
Parameters:
method setMetafiling [line 2921]
void setMetafiling(
$value)
|
|
Tags:
Parameters:
method setPen [line 2964]
void setPen(
value
$value)
|
|
Determines the kind of pen used to draw Canvas lines.
Tags:
Parameters:
method setSmoothingMode [line 3284]
void setSmoothingMode(
value
$value)
|
|
Sets the anti-alias mode for the Graphics Pen when Custom drawing. For example: AntiAlias - Specifies antialiased rendering. Default - Specifies the default mode. HighQuality - Specifies high quality, low speed rendering. HighSpeed - Specifies high speed, low quality rendering. Invalid - Specifies an invalid mode.
Tags:
Parameters:
method setTextAlign [line 2941]
void setTextAlign(
$value)
|
|
Tags:
Parameters:
method setXCenter [line 3195]
void setXCenter(
value
$value)
|
|
Specifies the X coordinate of the pixel location of the center of the 3D Canvas. The origin of the pixel coordinate system is in the top left corner of the parent window.
Tags:
Parameters:
method setYCenter [line 3219]
void setYCenter(
value
$value)
|
|
Specifies the Y coordinate of the pixel location of the center of the 3D Canvas. The origin of the pixel coordinate system is in the top left corner of the parent window.
Tags:
Parameters:
method sliceArray [line 2562]
void sliceArray(
$source,
$length)
|
|
Tags:
Parameters:
method textHeight [line 2666]
int textHeight(
text
$text)
|
|
Returns the vertical size in pixels of the text String.
Tags:
Parameters:
method textOut [line 2583]
void textOut(
x
$x, y
$y, z
$z, text
$text, [
$align = -1])
|
|
Displays the 2D non-rotated label at the specified X Y screen coordinates. Text is outputted to the correct internal drawing Graphics2D. The X and Y coordinates must be valid and fit inside the Chart rectangle. It uses the current drawing Font attributes. Writes text at the named x and y co-ordinates.
Tags:
Overridden in child classes as:
- Graphics3DFlex::textOut()
- Graphics3DHTML5::textOut()
Parameters:
method textWidth [line 2646]
int textWidth(
f
$text, [text
$f = null])
|
|
Returns the horizontal text size in pixels of ChartFont f.
Tags:
Parameters:
method transparentEllipsePoints [line 1119]
void transparentEllipsePoints(
$p0,
$p1)
|
|
Tags:
Parameters:
method transparentEllipseZ [line 1113]
void transparentEllipseZ(
$x1,
$y1,
$x2,
$y2,
$z)
|
|
Tags:
Parameters:
method triangle [line 2476]
void triangle(
p0
$p0, p1
$p1, p2
$p2, [z
$z = 0])
|
|
Draws a triangle (point p0, pointp1, pointp2) at Z position.
Tags:
Parameters:
method unClip [line 550]
method verticalLine [line 1567]
method zLine [line 1512]
void zLine(
x
$x, y
$y, z0
$z0, z1
$z1)
|
|
Draws a Line from (X,Y,Z0) to (X,Y,Z1).
Tags:
Overridden in child classes as:
- Graphics3DFlex::zLine()
- Draws a Line from (X,Y,Z0) to (X,Y,Z1).
- CanvasSVG::zLine()
Parameters:
method _calc3DPos [line 466]
Point _calc3DPos(
source
$source)
|
|
Calculates and returns the XY position in pixels of the point p Z 3D coordinate. Can be used when custom drawing using 3D XYZ coordinates are returned from the axes or not.
Tags:
Parameters:
method _line [line 1355]
void _line(
x0
$x0, y0
$y0, x1
$x1, y1
$y1, [z
$z = 0])
|
|
Draws a Line between co-ordinates with z depth offset.
Tags:
Parameters:
method _plane [line 1851]
void _plane(
p1
$p1, p2
$p2, p3
$p3, p4
$p4, z
$z)
|
|
Draws a polygon (Point p1, Point p2, Point p3, Point p4) at Z depth offset.
Tags:
Overridden in child classes as:
- CanvasSVG::_plane()
- Draws a polygon (Point p1, Point p2, Point p3, Point p4) at Z depth offset.
Parameters:
method _rectangle [line 2297]
void _rectangle(
$x,
$y,
$width,
$height)
|
|
Tags:
Parameters:
method _rotateLabel [line 2525]
void _rotateLabel(
p
$p, text
$text, rotDegree
$rotDegree)
|
|
Draws a rotated text String at the specified Point x,y coordinates with the RotDegree rotation angle. RotDegree values must be between 0 and 360. The string is drawn on the Chart Drawing Canvas.
Tags:
Parameters:
method _textHeight [line 2627]
int _textHeight(
f
$f, text
$text)
|
|
Returns the vertical text size in pixels of ChartFont f.
Tags:
Parameters:
method __calc3DPos [line 480]
Point __calc3DPos(
source
$source, z
$z)
|
|
Calculates and returns the XY position in pixels of the point p Z 3D coordinate. Can be used when custom drawing using 3D XYZ coordinates are returned from the axes or not.
Tags:
Parameters:
method __get [line 83]
method __line [line 1365]
void __line(
p0
$p0, p1
$p1)
|
|
Draws a Line between point p0 and point p1.
Tags:
Parameters:
method __lineTo [line 1411]
Draws a line to Point with z = 0 depth offset.
Tags:
Parameters:
method __set [line 90]
method ___calc3DPos [line 493]
Point ___calc3DPos(
source
$source)
|
|
Calculates and returns the XY position in pixels of the point p with Z = 0 3D coordinate. Can be used when custom drawing using 3D XYZ coordinates are returned from the axes or not.
Tags:
Parameters:
method ___line [line 1378]
void ___line(
pen
$pen, p0
$p0, p1
$p1)
|
|
Draws a Line between point p0 and point p1 using specific pen.
Tags:
Overridden in child classes as:
- Graphics3DFlex::___line()
- Draws a Line between point p0 and point p1 using specific pen.
- CanvasSVG::___line()
Parameters:
method ___lineTo [line 1425]
void ___lineTo(
x
$x, y
$y, [z
$z = 0])
|
|
Draws line from present position to end co-ordinates with z depth offset.
Tags:
Parameters:
method ____lineTo [line 1434]
Draws a Line to 3D Point.
Tags:
Parameters:
method _____lineTo [line 1444]
void _____lineTo(
x
$x, y
$y)
|
|
Draws line from present position to end co-ordinates with z depth offset.
Tags:
Parameters:
|
|