Java Doc for MorphShape.java in  » Ajax » Laszlo-4.0.10 » org » openlaszlo » iv » flash » api » shape » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Ajax » Laszlo 4.0.10 » org.openlaszlo.iv.flash.api.shape 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.openlaszlo.iv.flash.api.FlashItem
      org.openlaszlo.iv.flash.api.FlashObject
         org.openlaszlo.iv.flash.api.FlashDef
            org.openlaszlo.iv.flash.api.shape.MorphShape

MorphShape
final public class MorphShape extends FlashDef (Code)
MorphShape.

The DefineMorphShape tag defines the start and end states of a morph sequence. A morph object does not use previously defined shapes, it is considered a special type of shape with only one character ID. A morph object should be displayed with the PlaceObject2 tag, where the ratio field specifies how far the morph has progressed.

StartBounds defines the bounding-box of the shape at the start of the morph, and EndBounds defines the bounding-box at the end of the morph

MorphFillStyles contains an array interleaved fill styles for the start and end shapes. The fill style for the start shape is followed the corresponding fill style for the end shape. Similarly, MorphLineStyles contains an array of interleaved line styles.

The StartEdges array specifies the edges for the start shape, and the style change records for both shapes. Because the StyleChangeRecords must be the same for the start and end shapes, they are defined only in the StartEdges array. The EndEdges array specifies the edges for the end shape, and contains no style change records. The number of edges specified in StartEdges must equal the number of edges in EndEdges.

Note: Strictly speaking MoveTo records fall into the category of StyleChangeRecords, however they should be included in both the StartEdges and EndEdges arrays.

It is possible for an edge to change type over the course of a morph sequence. A straight edge can become a curved edge and vice versa. In this case, think of both edges as curved. A straight edge can be easily represented as a curve, by placing the off-curve (control) point at the mid-point of the straight edge, and the on-curve (anchor) point at the end of the straight edge. The calculation is as follows:


 CurveControlDelta.x = StraightDelta.x / 2;
 CurveControlDelta.y = StraightDelta.y / 2;
 CurveAnchorDelta.x  = StraightDelta.x / 2;
 CurveAnchorDelta.y  = StraightDelta.y / 2;
 

author:
   Dmitry Skavish
See Also:   Shape



Constructor Summary
public  MorphShape()
    

Method Summary
public  intaddFillStyle(MorphFillStyle fillStyle)
     Adds specified fill style to the array of shape styles.
public  intaddLineStyle(MorphLineStyle lineStyle)
    
public  voidcollectDeps(DepsCollector dc)
    
protected  FlashItemcopyInto(FlashItem item, ScriptCopier copier)
    
public  voiddrawAWTPathIteratorEnd(java.awt.geom.PathIterator pi)
    
public  voiddrawAWTPathIteratorStart(java.awt.geom.PathIterator pi)
    
public  voiddrawAWTShapeEnd(java.awt.Shape shape)
    
public  voiddrawAWTShapeEnd(java.awt.Shape shape, AffineTransform matrix)
    
public  voiddrawAWTShapeStart(java.awt.Shape shape)
    
public  voiddrawAWTShapeStart(java.awt.Shape shape, AffineTransform matrix)
    
public  voiddrawCurveEnd(int ax1, int ay1, int cx, int cy, int ax2, int ay2)
    
public  voiddrawCurveEnd(Point2D anchor1, Point2D control, Point2D anchor2)
    
public  voiddrawCurveStart(int ax1, int ay1, int cx, int cy, int ax2, int ay2)
     Draws curve record.

All coordinates are in twixels.

public  voiddrawCurveStart(Point2D anchor1, Point2D control, Point2D anchor2)
     Draws curve record.

All coordinates are in twixels.

public  voiddrawCurveToEnd(int cx, int cy, int ax, int ay)
    
public  voiddrawCurveToStart(int cx, int cy, int ax, int ay)
     Draws curve record.

All coordinates are in twixels.

public  voiddrawLineEnd(int x1, int y1, int x2, int y2)
    
public  voiddrawLineEnd(Point2D p0, Point2D p1)
    
public  voiddrawLineStart(int x1, int y1, int x2, int y2)
     Draws a straight line specified by two points.
public  voiddrawLineStart(Point2D p0, Point2D p1)
     Draws a straight line specified by two points.
public  voiddrawLineToEnd(int x, int y)
    
public  voiddrawLineToEnd(Point2D p1)
    
public  voiddrawLineToStart(int x, int y)
     Draws a straight line from current position to the specified one.

All coordinates are in twixels.

public  voiddrawLineToStart(Point2D p1)
     Draws a straight line from current position to the specified one.

All coordinates are in twixels.

public  voiddrawRectangleEnd(int x, int y, int width, int height)
    
public  voiddrawRectangleEnd(Rectangle2D r)
    
public  voiddrawRectangleStart(int x, int y, int width, int height)
     Draws a rectangle specified by its top-left corner and width and height

All coordinates are in twixels.

public  voiddrawRectangleStart(Rectangle2D r)
     Draws a rectangle specified by java.awt.geom.Rectangle2D

All coordinates are in twixels.

public  Rectangle2DgetBounds()
    
public  Rectangle2DgetBoundsEnd()
    
public  Rectangle2DgetBoundsStart()
    
public  FlashItemgetCopy(ScriptCopier copier)
    
public  MorphFillStylegetFillStyle0()
    
public  intgetFillStyle0Index()
    
public  MorphFillStylegetFillStyle1()
    
public  intgetFillStyle1Index()
    
public  MorphLineStylegetLineStyle()
    
public  intgetLineStyleIndex()
    
public  ShapeRecordsgetShapeRecordsEnd()
    
public  ShapeRecordsgetShapeRecordsStart()
    
public  MorphShapeStylesgetShapeStyles()
    
protected  StyleChangeRecordgetStyleChange()
    
public  intgetTag()
    
public  booleanisConstant()
    
public  voidmovePenToEnd(int x, int y)
    
public  voidmovePenToEnd(Point2D p)
    
public  voidmovePenToStart(int x, int y)
     Moves pen to the specified position.

All coordinates are ABSOLUTE and are in twixels.

public  voidmovePenToStart(Point2D p)
    
public static  MorphShapeparse(Parser p)
    
public  voidprintContent(PrintStream out, String indent)
    
public  voidsetBoundsEnd(Rectangle2D bounds)
     Sets bounding box for end shape.
public  voidsetBoundsEnd(int x, int y, int width, int height)
     Sets bounding box for end shape.
public  voidsetBoundsStart(Rectangle2D bounds)
     Sets bounding box for start shape.
public  voidsetBoundsStart(int x, int y, int width, int height)
     Sets bounding box for start shape.
public  intsetFillStyle0(MorphFillStyle fillStyle)
     Sets specified fillstyle as current fillstyle0.
public  voidsetFillStyle0(int fillStyle)
     Sets current fillstyle0 by its index in shapestyle array.
public  intsetFillStyle1(MorphFillStyle fillStyle)
     Sets specified fillstyle as current fillstyle1.
public  voidsetFillStyle1(int fillStyle)
     Sets current fillstyle1 by its index in shapestyle array.
public  intsetLineStyle(MorphLineStyle lineStyle)
     Sets specified linestyle as current linestyle.
public  voidsetLineStyle(int lineStyle)
     Sets current linestyle by its index in shapestyle array.
public  voidwrite(FlashOutput main)
    


Constructor Detail
MorphShape
public MorphShape()(Code)
Creates new empty morph shape




Method Detail
addFillStyle
public int addFillStyle(MorphFillStyle fillStyle)(Code)
Adds specified fill style to the array of shape styles.
Parameters:
  fillStyle - specified fill style index of added fill style in the array



addLineStyle
public int addLineStyle(MorphLineStyle lineStyle)(Code)
Adds specified line style to the array of shape styles
Parameters:
  lineStyle - specified line style index of added line style in the array



collectDeps
public void collectDeps(DepsCollector dc)(Code)



copyInto
protected FlashItem copyInto(FlashItem item, ScriptCopier copier)(Code)



drawAWTPathIteratorEnd
public void drawAWTPathIteratorEnd(java.awt.geom.PathIterator pi)(Code)



drawAWTPathIteratorStart
public void drawAWTPathIteratorStart(java.awt.geom.PathIterator pi)(Code)
Draw AWT PathIterator

All coordinates are in twixels!
Parameters:
  pi - AWT PathIterator




drawAWTShapeEnd
public void drawAWTShapeEnd(java.awt.Shape shape)(Code)



drawAWTShapeEnd
public void drawAWTShapeEnd(java.awt.Shape shape, AffineTransform matrix)(Code)



drawAWTShapeStart
public void drawAWTShapeStart(java.awt.Shape shape)(Code)
Draw AWT Shape

All shape coordinates are in twixels!
Parameters:
  shape - AWT shape




drawAWTShapeStart
public void drawAWTShapeStart(java.awt.Shape shape, AffineTransform matrix)(Code)
Draw AWT Shape

All shape coordinates are in twixels!
Parameters:
  shape - AWT shape




drawCurveEnd
public void drawCurveEnd(int ax1, int ay1, int cx, int cy, int ax2, int ay2)(Code)



drawCurveEnd
public void drawCurveEnd(Point2D anchor1, Point2D control, Point2D anchor2)(Code)



drawCurveStart
public void drawCurveStart(int ax1, int ay1, int cx, int cy, int ax2, int ay2)(Code)
Draws curve record.

All coordinates are in twixels.
Parameters:
  ax1 - X anchor point 1
Parameters:
  ay1 - Y anchor point 1
Parameters:
  cx - X control point
Parameters:
  cy - Y control point
Parameters:
  ax2 - X anchor point 2
Parameters:
  ay2 - Y anchor point 2




drawCurveStart
public void drawCurveStart(Point2D anchor1, Point2D control, Point2D anchor2)(Code)
Draws curve record.

All coordinates are in twixels.
Parameters:
  anchor0 - first anchor point
Parameters:
  control - control point
Parameters:
  anchor1 - second anchor point




drawCurveToEnd
public void drawCurveToEnd(int cx, int cy, int ax, int ay)(Code)



drawCurveToStart
public void drawCurveToStart(int cx, int cy, int ax, int ay)(Code)
Draws curve record.

All coordinates are in twixels.
Parameters:
  cx - X control point
Parameters:
  cy - Y control point
Parameters:
  ax - X anchor point
Parameters:
  ay - Y anchor point




drawLineEnd
public void drawLineEnd(int x1, int y1, int x2, int y2)(Code)



drawLineEnd
public void drawLineEnd(Point2D p0, Point2D p1)(Code)



drawLineStart
public void drawLineStart(int x1, int y1, int x2, int y2)(Code)
Draws a straight line specified by two points.

All coordinates are in twixels.
Parameters:
  x1 - X of the beginning of the line
Parameters:
  y1 - Y of the beginning of the line
Parameters:
  x2 - X of the end of the line
Parameters:
  y2 - Y of the end of the line




drawLineStart
public void drawLineStart(Point2D p0, Point2D p1)(Code)
Draws a straight line specified by two points.

All coordinates are in twixels.
Parameters:
  p0 - first point
Parameters:
  p1 - second point




drawLineToEnd
public void drawLineToEnd(int x, int y)(Code)



drawLineToEnd
public void drawLineToEnd(Point2D p1)(Code)



drawLineToStart
public void drawLineToStart(int x, int y)(Code)
Draws a straight line from current position to the specified one.

All coordinates are in twixels.
Parameters:
  x - X of end of line
Parameters:
  y - Y of end of line




drawLineToStart
public void drawLineToStart(Point2D p1)(Code)
Draws a straight line from current position to the specified one.

All coordinates are in twixels.
Parameters:
  p1 - end of line




drawRectangleEnd
public void drawRectangleEnd(int x, int y, int width, int height)(Code)



drawRectangleEnd
public void drawRectangleEnd(Rectangle2D r)(Code)



drawRectangleStart
public void drawRectangleStart(int x, int y, int width, int height)(Code)
Draws a rectangle specified by its top-left corner and width and height

All coordinates are in twixels.
Parameters:
  x - x coordinates of top-left corner of the rectangle
Parameters:
  y - y coordinates of top-left corner of the rectangle
Parameters:
  width - width of the rectangle
Parameters:
  height - height of the rectangle




drawRectangleStart
public void drawRectangleStart(Rectangle2D r)(Code)
Draws a rectangle specified by java.awt.geom.Rectangle2D

All coordinates are in twixels.
Parameters:
  r - specified rectangle




getBounds
public Rectangle2D getBounds()(Code)
Returns MorphShape bounds shape bounds



getBoundsEnd
public Rectangle2D getBoundsEnd()(Code)
Returns MorphShape end shape bounds shape bounds



getBoundsStart
public Rectangle2D getBoundsStart()(Code)
Returns MorphShape start shape bounds shape bounds



getCopy
public FlashItem getCopy(ScriptCopier copier)(Code)



getFillStyle0
public MorphFillStyle getFillStyle0()(Code)
Returns current fill style 0 currently used fill style 0



getFillStyle0Index
public int getFillStyle0Index()(Code)
Returns index of current fill style 0 index of currently used fill style 0



getFillStyle1
public MorphFillStyle getFillStyle1()(Code)
Returns current fill style 1 currently used fill style 1



getFillStyle1Index
public int getFillStyle1Index()(Code)
Returns index of current fill style 1 index of currently used fill style 1



getLineStyle
public MorphLineStyle getLineStyle()(Code)
Returns current line style currently used line style



getLineStyleIndex
public int getLineStyleIndex()(Code)
Returns index of current line style index of currently used line style



getShapeRecordsEnd
public ShapeRecords getShapeRecordsEnd()(Code)
Returns end shape records object representing array of shape records



getShapeRecordsStart
public ShapeRecords getShapeRecordsStart()(Code)
Returns start shape records object representing array of shape records



getShapeStyles
public MorphShapeStyles getShapeStyles()(Code)
Returns shape styles object representing array of shape styles



getStyleChange
protected StyleChangeRecord getStyleChange()(Code)



getTag
public int getTag()(Code)



isConstant
public boolean isConstant()(Code)



movePenToEnd
public void movePenToEnd(int x, int y)(Code)



movePenToEnd
public void movePenToEnd(Point2D p)(Code)



movePenToStart
public void movePenToStart(int x, int y)(Code)
Moves pen to the specified position.

All coordinates are ABSOLUTE and are in twixels.
Parameters:
  x - new current X
Parameters:
  y - new current Y




movePenToStart
public void movePenToStart(Point2D p)(Code)
Moves pen to the specified point.

All coordinates are ABSOLUTE and are in twixels!
Parameters:
  p - new pen position




parse
public static MorphShape parse(Parser p)(Code)
Parses Shape
Parameters:
  p - Parser parsed shape



printContent
public void printContent(PrintStream out, String indent)(Code)



setBoundsEnd
public void setBoundsEnd(Rectangle2D bounds)(Code)
Sets bounding box for end shape.
Parameters:
  bounds - new bounding box



setBoundsEnd
public void setBoundsEnd(int x, int y, int width, int height)(Code)
Sets bounding box for end shape.



setBoundsStart
public void setBoundsStart(Rectangle2D bounds)(Code)
Sets bounding box for start shape.
Parameters:
  bounds - new bounding box



setBoundsStart
public void setBoundsStart(int x, int y, int width, int height)(Code)
Sets bounding box for start shape.



setFillStyle0
public int setFillStyle0(MorphFillStyle fillStyle)(Code)
Sets specified fillstyle as current fillstyle0.

If the specified fillstyle is not in the shapestyle array then it's added, if it's already there it's reused.
Parameters:
  fillStyle - specified fillstyle index of specified fillstyle in the shapestyle array




setFillStyle0
public void setFillStyle0(int fillStyle)(Code)
Sets current fillstyle0 by its index in shapestyle array.
Parameters:
  fillStyle - index of fillstyle in shapestyle array to be set as current fillstyle0



setFillStyle1
public int setFillStyle1(MorphFillStyle fillStyle)(Code)
Sets specified fillstyle as current fillstyle1.

If the specified fillstyle is not in the shapestyle array then it's added, if it's already there it's reused.
Parameters:
  fillStyle - specified fillstyle index of specified fillstyle in the shapestyle array




setFillStyle1
public void setFillStyle1(int fillStyle)(Code)
Sets current fillstyle1 by its index in shapestyle array.
Parameters:
  fillStyle - index of fillstyle in shapestyle array to be set as current fillstyle1



setLineStyle
public int setLineStyle(MorphLineStyle lineStyle)(Code)
Sets specified linestyle as current linestyle.

If the specified linestyle is not in the shapestyle array then it's added, if it's already there it's reused.
Parameters:
  lineStyle - specified linestyle index of specified linestyle in the shapestyle array




setLineStyle
public void setLineStyle(int lineStyle)(Code)
Sets current linestyle by its index in shapestyle array.
Parameters:
  lineStyle - index of linestyle in shapestyle array to be set as current linestyle



write
public void write(FlashOutput main)(Code)



Methods inherited from org.openlaszlo.iv.flash.api.FlashDef
protected FlashItem copyInto(FlashItem item, ScriptCopier copier)(Code)(Java Doc)
public int getID()(Code)(Java Doc)
public String getName()(Code)(Java Doc)
public void setID(int id)(Code)(Java Doc)
public void setName(String name)(Code)(Java Doc)

Methods inherited from org.openlaszlo.iv.flash.api.FlashObject
protected boolean _isConstant()(Code)(Java Doc)
public void apply(Context context)(Code)(Java Doc)
public void collectDeps(DepsCollector dc)(Code)(Java Doc)
public void collectFonts(FontsCollector fc)(Code)(Java Doc)
protected FlashItem copyInto(FlashItem item, ScriptCopier copier)(Code)(Java Doc)
public void generate(FlashOutput fob, DepsCollector dc)(Code)(Java Doc)
public Rectangle2D getBounds()(Code)(Java Doc)
abstract public int getTag()(Code)(Java Doc)
public boolean isConstant()(Code)(Java Doc)
public boolean isProcessed()(Code)(Java Doc)
public void printContent(PrintStream out, String indent)(Code)(Java Doc)
public void process(FlashFile file, Context context) throws IVException(Code)(Java Doc)
protected void setConstant(boolean is_const)(Code)(Java Doc)
public void setProcessed()(Code)(Java Doc)

Methods inherited from org.openlaszlo.iv.flash.api.FlashItem
protected FlashItem copyInto(FlashItem item, ScriptCopier copier)(Code)(Java Doc)
public FlashItem getCopy(ScriptCopier copier)(Code)(Java Doc)
abstract public void printContent(PrintStream out, String indent)(Code)(Java Doc)
public String toString()(Code)(Java Doc)
abstract public void write(FlashOutput fob)(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.