com.steema.teechart.drawing
Class Graphics3DPDF

java.lang.Object
  extended by com.steema.teechart.TeeBase
      extended by com.steema.teechart.drawing.Graphics3D
          extended by com.steema.teechart.drawing.Graphics3DVectorial
              extended by com.steema.teechart.drawing.Graphics3DPDF
All Implemented Interfaces:
IGraphics3D, java.io.Serializable

public class Graphics3DPDF
extends Graphics3DVectorial

Title: Graphics3DPDF class

Description: Summary description for Graphics3DPDF.

Copyright (c) 2005-2006 by Steema Software SL. All Rights Reserved.

Company: Steema Software SL

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.steema.teechart.drawing.Graphics3D
aspect, bounds, brush, DARKCOLORQUANTITY, DARKERCOLORQUANTITY, DefaultPalette, font, fourPoints, metafiling, monochrome, pen, smoothingMode, stringFormat, textSmooth
 
Fields inherited from class com.steema.teechart.TeeBase
chart
 
Constructor Summary
Graphics3DPDF(PDFData pdfdata, IBaseChart c)
           
 
Method Summary
 void arc(int x1, int y1, int x2, int y2, double startAngle, double sweepAngle)
          Use Arc to draw an elliptically curved line with the current Pen.
 void arc(int x1, int y1, int x2, int y2, int x3, int y3, int x4, int y4)
          Use Arc to draw an elliptically curved line with the current Pen.
 void changed(java.lang.Object o)
           
 void clipEllipse(Rectangle r)
          Creates a Elliptical Windows GDI clipping region.
 void clipPolygon(java.awt.Point[] p)
          Creates a Polygonal Windows GDI clipping region.
 void clipRectangle(Rectangle r)
          Creates a rectangular Windows GDI clipping region.
 void cone(boolean vertical, int left, int top, int right, int bottom, int z0, int z1, boolean darkSides, int conePercent)
           
 void donut(int xCenter, int yCenter, int xRadius, int yRadius, double startAngle, double endAngle, int donutPercent)
          Draws a Donut slice.
 void draw(int x, int y, java.awt.Image image)
          Paints the image at x,y coordinates.
 void draw(Rectangle r, java.awt.Image image)
          Paints the image in rectangle r.
 void draw(Rectangle rect, java.awt.Image image, boolean draw3D)
           
 void drawBeziers(java.awt.Point[] p)
          Draws Bezier splines for the Point array p.
protected  void drawString(int x, int y, java.lang.String text, ChartBrush brush)
           
 void ellipse(int x1, int y1, int x2, int y2)
          Draws an Ellipse between the 2 co-ordinates.
 void ellipse(int left, int top, int right, int bottom, boolean enhanced)
           
 void eraseBackground(int left, int top, int right, int bottom)
          Clears background defined for Rectangle Left, Top, Right, Bottom.
 void fillRectangle(ChartBrush brush, int x, int y, int width, int height)
           
 void gradientFill(int left, int top, int right, int bottom, Color startColor, Color endColor, GradientDirection direction)
          Fills a Screen area with multi-colored lines to obtain a nice shadow effect and coloured backgrounds.
 void horizontalLine(int left, int right, int y)
          Draws a Horizontal Line.
 void initWindow(Aspect a, Rectangle r, int maxDepth)
           
protected  void line(ChartPen p, java.awt.Point a, java.awt.Point b)
           
 void line(int x0, int y0, int x1, int y1)
          Draws a Line between co-ordinates.
 void lineTo(int x, int y)
          Draws a line from the present PenPos to the new co-ordinates.
 java.awt.Dimension measureString(ChartFont f, java.lang.String text)
           
 void moveTo(int x, int y)
          Sets the value of PenPos to x and y co-ordinates before calling LineTo.
 void pie(int x1, int y1, int x2, int y2, double startAngle, double endAngle)
          Draws a Pie slice using StartAngle and End Angle.
 void pixel(int x, int y, int z, Color color)
          Sets the 3D pixel to OLE_Color, using Pen.
 void polygon(ChartBrush b, java.awt.Point[] p)
          Draws a polygon using the specified GDI brush.
 void polygon(java.awt.Point[] p)
          Draws a polygon.
 void polyLine(java.awt.Point[] p)
          Draws a series of line segments to join point array p.
 void prepareDrawImage()
           
 void rectangle(ChartBrush b, Rectangle r)
           
 void rectangle(Rectangle r)
          Draws a Rectangle (Rectangle r).
 void resetState()
           
 void rotateLabel(int x, int y, java.lang.String text, double rotDegree)
          Draws a rotated text String at the specified xy coordinates with the RotDegree rotation angle.
 void roundRectangle(Rectangle r, int roundWidth, int roundHeight)
          Draws a rectangle with rounded corners of personalized curvature and size.
 void setClip(java.awt.Shape region)
           
 void setPixel(int x, int y, int z, Color color)
           
 void showImage()
           
 void sphere(int left, int top, int right, int bottom)
           
 void sphere(int x, int y, int z, int radius, boolean enhanced)
           
protected  void transparentEllipse(int x1, int y1, int x2, int y2)
           
 void unClip()
          Removes any clipping region applied to Chart Drawing.
 void verticalLine(int x, int top, int bottom)
          Draws a Vertical Line from (X,Top) to (X,Bottom).
 
Methods inherited from class com.steema.teechart.drawing.Graphics3DVectorial
addToStream, bufferedFrom, getGraphics, getImagePixels, setGraphics
 
Methods inherited from class com.steema.teechart.drawing.Graphics3D
applyBright, applyDark, arc, arc, arrow, calc3DPoint, calc3DPoint, calc3DPoint, calc3DPos, calc3DPos, calc3DPos, calc3DPos, calcPerspective, calcRect3D, calcTrigValues, calculate2DPosition, calculate2DPosition, clipCube, clipRectangle, cone, cone, cone, convexHull, correctRectangle, crossingLines, cube, cube, cube, cull, cull, cylinder, draw, drawBeziers, ellipse, ellipse, ellipse, ellipse, ellipse, ellipse, ellipse, ellipseEnh, fillRectangle, fontTextHeight, fourPointsFromRect, getAspect, getBackColor, getBrush, getChartPolygon, getChartXCenter, getChartYCenter, getColorPaletteLength, getDefaultColor, getDefaultPattern, getDirty, getFont, getFontHeight, getGradient, getIZoomfactor, getMetafiling, getMonochrome, getPen, getPolygon, getRotationCenter, getScreenHeight, getScreenWidth, getSmoothingMode, getSupports3DText, getSupportsFullRotation, getTextAlign, getTextSmooth, getUseBuffer, getXCenter, getYCenter, horizontalLine, line, line, line, line, lineTo, lineTo, lineTo, lineTo, lineWithZ, moveTo, moveTo, moveTo, moveTo, paintBevel, paintImageBevel, pie, pie, pie, plane, plane, plane, planeFour3D, pointInEllipse, pointInEllipse, pointInHorizTriangle, pointInLineTolerance, pointInLineTolerance, pointInPolygon, pointInRect, pointInTriangle, polygon, polygon, polygonRect, polyLine, projection, pyramid, pyramid, pyramidTrunc, rad2Deg, rectangle, rectangle, rectangle, rectangle, rectangleWithZ, rectangleY, rectangleZ, rectFromPolygon, rectFromRectZ, reset, rotateLabel, rotateLabel, rotateRectangle, roundRectangle, setBackColor, setBrush, setColorPalette, setDirty, setFont, setGradient, setIZoomfactor, setMetafiling, setPen, setRotationCenter, setSmoothingMode, setTextAlign, setTextSmooth, setUseBuffer, setXCenter, setYCenter, sliceArray, sphere, sphere, sphere, textHeight, textHeight, textOut, textOut, textOut, textWidth, textWidth, transparency, transparentColor, transparentEllipse, transparentEllipse, triangle, triangle, unClipRectangle, validState, verticalLine, zLine
 
Methods inherited from class com.steema.teechart.TeeBase
getChart, invalidate, setBooleanProperty, setChart, setColorProperty, setColorProperty, setDoubleProperty, setIntegerProperty, setStringProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Graphics3DPDF

public Graphics3DPDF(PDFData pdfdata,
                     IBaseChart c)
Method Detail

initWindow

public void initWindow(Aspect a,
                       Rectangle r,
                       int maxDepth)
Specified by:
initWindow in interface IGraphics3D
Overrides:
initWindow in class Graphics3D

changed

public void changed(java.lang.Object o)
Specified by:
changed in interface IGraphics3D
Overrides:
changed in class Graphics3D

fillRectangle

public void fillRectangle(ChartBrush brush,
                          int x,
                          int y,
                          int width,
                          int height)
Specified by:
fillRectangle in class Graphics3D

setClip

public void setClip(java.awt.Shape region)
Specified by:
setClip in class Graphics3D

setPixel

public void setPixel(int x,
                     int y,
                     int z,
                     Color color)
Specified by:
setPixel in interface IGraphics3D
Specified by:
setPixel in class Graphics3D

draw

public void draw(Rectangle rect,
                 java.awt.Image image,
                 boolean draw3D)
Specified by:
draw in interface IGraphics3D
Specified by:
draw in class Graphics3D

resetState

public void resetState()

arc

public void arc(int x1,
                int y1,
                int x2,
                int y2,
                double startAngle,
                double sweepAngle)
Use Arc to draw an elliptically curved line with the current Pen.

Specified by:
arc in interface IGraphics3D
Specified by:
arc in class Graphics3D
Parameters:
x1 - int
y1 - int
x2 - int
y2 - int
startAngle - double
sweepAngle - double

arc

public void arc(int x1,
                int y1,
                int x2,
                int y2,
                int x3,
                int y3,
                int x4,
                int y4)
Description copied from class: Graphics3D
Use Arc to draw an elliptically curved line with the current Pen.

Specified by:
arc in class Graphics3D
Parameters:
x1 - int
y1 - int
x2 - int
y2 - int
x3 - int
y3 - int
x4 - int
y4 - int

ellipse

public void ellipse(int x1,
                    int y1,
                    int x2,
                    int y2)
Draws an Ellipse between the 2 co-ordinates.

Specified by:
ellipse in interface IGraphics3D
Specified by:
ellipse in class Graphics3D
Parameters:
x1 - int
y1 - int
x2 - int
y2 - int

transparentEllipse

protected void transparentEllipse(int x1,
                                  int y1,
                                  int x2,
                                  int y2)
Specified by:
transparentEllipse in class Graphics3D

drawString

protected void drawString(int x,
                          int y,
                          java.lang.String text,
                          ChartBrush brush)
Specified by:
drawString in class Graphics3D

clipRectangle

public void clipRectangle(Rectangle r)
Creates a rectangular Windows GDI clipping region.
ClipRectangle creates a Windows GDI clipping region and selects it into TChart.Drawing Canvas device context handle.
Clipping regions are used to prevent a drawing escaping from desired polygon coordinates.
The UnClipRectangle method removes any clipping region applied to TChart Drawing Canvas.
You can use this method to avoid Series or custom drawing to go over the desired rectangle coordinates.
Note: Printing and creating metafiles do not accept clipping regions in logical pixels.

Specified by:
clipRectangle in interface IGraphics3D
Specified by:
clipRectangle in class Graphics3D
Parameters:
r - Rectangle

clipPolygon

public void clipPolygon(java.awt.Point[] p)
Creates a Polygonal Windows GDI clipping region.
ClipPolygon creates a Windows GDI clipping region and selects it into TChart.Drawing Canvas device context handle.
Clipping regions are used to prevent a drawing escaping from desired polygon coordinates.
The UnClipRectangle method removes any clipping region applied to TChart Drawing Canvas.
You can use this method to avoid Series or custom drawing to go over the desired rectangle coordinates.
Note: Printing and creating metafiles do not accept clipping regions in logical pixels.

Specified by:
clipPolygon in interface IGraphics3D
Specified by:
clipPolygon in class Graphics3D
Parameters:
p - Point[]

unClip

public void unClip()
Removes any clipping region applied to Chart Drawing.

Specified by:
unClip in interface IGraphics3D
Specified by:
unClip in class Graphics3D

clipEllipse

public void clipEllipse(Rectangle r)
Creates a Elliptical Windows GDI clipping region.
ClipEllipse creates a Windows GDI clipping region and selects it into TChart.Drawing Canvas device context handle.
Clipping regions are used to prevent a drawing escaping from desired polygon coordinates.
The UnClipRectangle method removes any clipping region applied to TChart Drawing Canvas.
You can use this method to avoid Series or custom drawing to go over the desired rectangle coordinates.
Note: Printing and creating metafiles do not accept clipping regions in logical pixels.

Specified by:
clipEllipse in interface IGraphics3D
Specified by:
clipEllipse in class Graphics3D
Parameters:
r - Rectangle

rotateLabel

public void rotateLabel(int x,
                        int y,
                        java.lang.String text,
                        double rotDegree)
Draws a rotated text String at the specified xy coordinates with the RotDegree rotation angle.
RotDegree values must be between 0 and 360. The string is drawn on the Chart Drawing Canvas.

Specified by:
rotateLabel in interface IGraphics3D
Specified by:
rotateLabel in class Graphics3D
Parameters:
x - int
y - int
text - String
rotDegree - double

pie

public void pie(int x1,
                int y1,
                int x2,
                int y2,
                double startAngle,
                double endAngle)
Draws a Pie slice using StartAngle and End Angle.

Specified by:
pie in class Graphics3D
Parameters:
x1 - int
y1 - int
x2 - int
y2 - int
startAngle - double
endAngle - double

eraseBackground

public void eraseBackground(int left,
                            int top,
                            int right,
                            int bottom)
Clears background defined for Rectangle Left, Top, Right, Bottom.

Specified by:
eraseBackground in class Graphics3D
Parameters:
left - int
top - int
right - int
bottom - int

gradientFill

public void gradientFill(int left,
                         int top,
                         int right,
                         int bottom,
                         Color startColor,
                         Color endColor,
                         GradientDirection direction)
Fills a Screen area with multi-colored lines to obtain a nice shadow effect and coloured backgrounds.

The Chart.Gradient component uses this method internally.

Parameters:
left - int
top - int
right - int
bottom - int
startColor - Color
endColor - Color
direction - GradientDirection

pixel

public void pixel(int x,
                  int y,
                  int z,
                  Color color)
Sets the 3D pixel to OLE_Color, using Pen.Width.

Specified by:
pixel in class Graphics3D
Parameters:
x - int
y - int
z - int
color - Color

polyLine

public void polyLine(java.awt.Point[] p)
Draws a series of line segments to join point array p.

Specified by:
polyLine in interface IGraphics3D
Specified by:
polyLine in class Graphics3D
Parameters:
p - Point[]

polygon

public void polygon(ChartBrush b,
                    java.awt.Point[] p)
Draws a polygon using the specified GDI brush.

Parameters:
b - ChartBrush
p - Point[]

polygon

public void polygon(java.awt.Point[] p)
Draws a polygon.

Specified by:
polygon in interface IGraphics3D
Specified by:
polygon in class Graphics3D
Parameters:
p - Point[]

draw

public void draw(Rectangle r,
                 java.awt.Image image)
Paints the image in rectangle r.
It can also be used to Print the Chart in a customized way:
Or you can use the TeeChart Draw method to render an image at any location.

Parameters:
r - Rectangle
image - Image

draw

public void draw(int x,
                 int y,
                 java.awt.Image image)
Paints the image at x,y coordinates.
It can also be used to Print the Chart in a customized way:
Or you can use the TeeChart Draw method to render an image at any location.

Parameters:
x - int
y - int
image - Image

drawBeziers

public void drawBeziers(java.awt.Point[] p)
Draws Bezier splines for the Point array p.

Specified by:
drawBeziers in interface IGraphics3D
Overrides:
drawBeziers in class Graphics3D
Parameters:
p - Point[]

horizontalLine

public void horizontalLine(int left,
                           int right,
                           int y)
Draws a Horizontal Line.

Specified by:
horizontalLine in interface IGraphics3D
Specified by:
horizontalLine in class Graphics3D
Parameters:
left - int
right - int
y - int

line

protected void line(ChartPen p,
                    java.awt.Point a,
                    java.awt.Point b)
Specified by:
line in class Graphics3D

moveTo

public void moveTo(int x,
                   int y)
Description copied from class: Graphics3D
Sets the value of PenPos to x and y co-ordinates before calling LineTo.

Specified by:
moveTo in interface IGraphics3D
Specified by:
moveTo in class Graphics3D
Parameters:
x - int
y - int

lineTo

public void lineTo(int x,
                   int y)
Draws a line from the present PenPos to the new co-ordinates.
The Line method has 4 overloads to facilitate the setting of the end co-ordinate using Point p or int x, int y, both with or without a z parameter

Specified by:
lineTo in interface IGraphics3D
Specified by:
lineTo in class Graphics3D
Parameters:
x - int
y - int

line

public void line(int x0,
                 int y0,
                 int x1,
                 int y1)
Draws a Line between co-ordinates.

Specified by:
line in interface IGraphics3D
Specified by:
line in class Graphics3D
Parameters:
x0 - int
y0 - int
x1 - int
y1 - int

prepareDrawImage

public void prepareDrawImage()
Specified by:
prepareDrawImage in interface IGraphics3D
Specified by:
prepareDrawImage in class Graphics3D

rectangle

public void rectangle(ChartBrush b,
                      Rectangle r)
Specified by:
rectangle in interface IGraphics3D
Specified by:
rectangle in class Graphics3D

rectangle

public void rectangle(Rectangle r)
Draws a Rectangle (Rectangle r).

Specified by:
rectangle in interface IGraphics3D
Specified by:
rectangle in class Graphics3D
Parameters:
r - Rectangle

showImage

public void showImage()

roundRectangle

public void roundRectangle(Rectangle r,
                           int roundWidth,
                           int roundHeight)
Draws a rectangle with rounded corners of personalized curvature and size.

Specified by:
roundRectangle in interface IGraphics3D
Specified by:
roundRectangle in class Graphics3D
Parameters:
r - Rectangle
roundWidth - int
roundHeight - int

verticalLine

public void verticalLine(int x,
                         int top,
                         int bottom)
Draws a Vertical Line from (X,Top) to (X,Bottom).

Specified by:
verticalLine in interface IGraphics3D
Specified by:
verticalLine in class Graphics3D
Parameters:
x - int
top - int
bottom - int

measureString

public java.awt.Dimension measureString(ChartFont f,
                                        java.lang.String text)
Specified by:
measureString in interface IGraphics3D
Overrides:
measureString in class Graphics3DVectorial

donut

public void donut(int xCenter,
                  int yCenter,
                  int xRadius,
                  int yRadius,
                  double startAngle,
                  double endAngle,
                  int donutPercent)
Description copied from class: Graphics3D
Draws a Donut slice.

Specified by:
donut in interface IGraphics3D
Overrides:
donut in class Graphics3D
Parameters:
xCenter - int center horizontal position
yCenter - int center vertical position
xRadius - int horizontal radius
yRadius - int vertical radius
startAngle - double angle from 0 to 360 of slice begin
endAngle - double angle from 0 to 360 of slice end
donutPercent - int percent from 0 to 100 of donut center hole

cone

public void cone(boolean vertical,
                 int left,
                 int top,
                 int right,
                 int bottom,
                 int z0,
                 int z1,
                 boolean darkSides,
                 int conePercent)
Specified by:
cone in interface IGraphics3D
Overrides:
cone in class Graphics3D

sphere

public void sphere(int x,
                   int y,
                   int z,
                   int radius,
                   boolean enhanced)
Specified by:
sphere in interface IGraphics3D
Overrides:
sphere in class Graphics3D

sphere

public void sphere(int left,
                   int top,
                   int right,
                   int bottom)
Specified by:
sphere in interface IGraphics3D
Overrides:
sphere in class Graphics3D

ellipse

public void ellipse(int left,
                    int top,
                    int right,
                    int bottom,
                    boolean enhanced)
Specified by:
ellipse in interface IGraphics3D
Overrides:
ellipse in class Graphics3D