SHARE
TWEET

Untitled

AishaAli Nov 19th, 2019 58 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /* * Copyright (c) 1996, 1997 Erich Gamma
  2.   All Rights Reserved
  3.  */
  4.  
  5. package CH.ifa.draw.contrib;
  6.  
  7. import java.awt.*;
  8. import CH.ifa.draw.framework.*;
  9. import CH.ifa.draw.standard.*;
  10. import CH.ifa.draw.util.Geom;
  11.  
  12. import javax.swing.*;
  13. import java.awt.*;
  14. import java.awt.event.*;
  15. import CH.ifa.draw.framework.*;
  16. import CH.ifa.draw.standard.*;
  17. import CH.ifa.draw.figures.*;
  18. import CH.ifa.draw.util.*;
  19.  
  20. public class ChopPolygonConnector extends ChopBoxConnector {
  21. public void adjustOffsets(Component comp, Point offsetPoint)
  22. {
  23. }
  24. //
  25.  
  26.     private static final long serialVersionUID = -156024908227796826L;
  27.  
  28.     public ChopPolygonConnector() {
  29.     }
  30.  
  31.     public ChopPolygonConnector(Figure owner) {
  32.         super(owner);
  33.     }
  34.  
  35.     protected Point chop(Figure target, Point from) {
  36.         return ((PolygonFigure)target).chop(from);
  37.     }
  38.  
  39.  
  40.     public void adjustOffsets(Component comp, Point offsetPoint, CustomSelectionTool C_S_T) {
  41.         if (comp != null) {
  42.             Point compLocation = comp.getLocation();
  43.             offsetPoint.translate(compLocation.x, compLocation.y);
  44.             adjustOffsets(comp.getParent(), offsetPoint);
  45.         }
  46.     }
  47.  
  48. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top