com.sun.electric.tool.user
Class Clipboard

java.lang.Object
  extended by com.sun.electric.tool.user.Clipboard

public class Clipboard
extends java.lang.Object

Class for managing the circuitry clipboard (for copy and paste).


Method Summary
static void clear()
          Method to clear the contents of the clipboard.
static void copy()
          Method to copy the selected objects to the clipboard.
static NodeInst copyListToCell(Cell toCell, java.util.List<Geometric> geomList, java.util.List<DisplayedText> textList, java.util.List<Geometric> newGeomList, java.util.List<DisplayedText> newTextList, java.awt.geom.Point2D delta, boolean copyExports, boolean uniqueArcs, Dimension2D alignment, java.awt.geom.AffineTransform inPlace, Orientation inPlaceOrient)
          Method to copy the list of Geometrics to a new Cell.
static void copyListToClipboard(java.util.List<Geometric> geomList, java.util.List<DisplayedText> textList, Dimension2D alignment, java.awt.geom.AffineTransform inPlace, Orientation inPlaceOrient)
           
static void cut()
          Method to copy the selected objects to the clipboard and then delete them.
static void duplicate()
          Method to duplicate the selected objects.
static void editClipboard()
           
static void nodeMoved(NodeInst ni, double lastX, double lastY)
          Method to track movement of the object that was just duplicated.
static void paste()
          Method to paste the clipboard back into the current cell.
 java.lang.String toString()
          Returns a printable version of this Clipboard.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

toString

public java.lang.String toString()
Returns a printable version of this Clipboard.

Overrides:
toString in class java.lang.Object
Returns:
a printable version of this Clipboard.

editClipboard

public static void editClipboard()

copy

public static void copy()
Method to copy the selected objects to the clipboard.


cut

public static void cut()
Method to copy the selected objects to the clipboard and then delete them.


paste

public static void paste()
Method to paste the clipboard back into the current cell.


duplicate

public static void duplicate()
Method to duplicate the selected objects.


nodeMoved

public static void nodeMoved(NodeInst ni,
                             double lastX,
                             double lastY)
Method to track movement of the object that was just duplicated. By following subsequent changes to that node, future duplications know where to place their copies.

Parameters:
ni - the NodeInst that has just moved.
lastX - the previous center X of the NodeInst.
lastY - the previous center Y of the NodeInst.

clear

public static void clear()
Method to clear the contents of the clipboard.


copyListToClipboard

public static void copyListToClipboard(java.util.List<Geometric> geomList,
                                       java.util.List<DisplayedText> textList,
                                       Dimension2D alignment,
                                       java.awt.geom.AffineTransform inPlace,
                                       Orientation inPlaceOrient)

copyListToCell

public static NodeInst copyListToCell(Cell toCell,
                                      java.util.List<Geometric> geomList,
                                      java.util.List<DisplayedText> textList,
                                      java.util.List<Geometric> newGeomList,
                                      java.util.List<DisplayedText> newTextList,
                                      java.awt.geom.Point2D delta,
                                      boolean copyExports,
                                      boolean uniqueArcs,
                                      Dimension2D alignment,
                                      java.awt.geom.AffineTransform inPlace,
                                      Orientation inPlaceOrient)
Method to copy the list of Geometrics to a new Cell.

Parameters:
toCell - the destination cell of the Geometrics.
geomList - the list of Geometrics to copy.
textList - the list of text to copy.
newGeomList - the list of Geometrics that were created.
newTextList - the list of text objects that were created.
delta - an offset for all of the copied Geometrics.
copyExports - true to copy exports.
uniqueArcs - true to generate unique arc names.
alignment - the grid alignment to use (0 for none).
inPlace - the transformation to use which accounts for "down in place" editing.
inPlaceOrient - the orientation to use which accounts for "down in place" editing.
Returns:
the last NodeInst that was created.