Tabnine Logo
BezierFigure.changed
Code IndexAdd Tabnine to your IDE (free)

How to use
changed
method
in
org.jhotdraw.draw.BezierFigure

Best Java code snippets using org.jhotdraw.draw.BezierFigure.changed (Showing top 18 results out of 315)

origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

  @Override
  public void undo() throws CannotUndoException {
    super.undo();
    willChange();
    removeNode(index);
    changed();
  }
});
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void redo() throws CannotRedoException {
  super.redo();
  willChange();
  addNode(index, newNode);
  changed();
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void redo() throws CannotRedoException {
  super.redo();
  owner.willChange();
  owner.setNode(index, newValue);
  owner.changed();
  if (oldValue.mask != newValue.mask) {
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void undo() throws CannotUndoException {
  super.undo();
  owner.willChange();
  owner.setNode(index, oldValue);
  owner.changed();
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

  @Override
  public void undo() throws CannotUndoException {
    super.undo();
    view.removeFromSelection(f);
    f.willChange();
    f.addNode(index, removedNode);
    f.changed();
    view.addToSelection(f);
  }
});
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void redo() throws CannotRedoException {
  super.redo();
  view.removeFromSelection(f);
  f.willChange();
  f.removeNode(index);
  f.changed();
  view.addToSelection(f);
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

  @Override
  public void undo() throws CannotUndoException {
    super.undo();
    view.removeFromSelection(f);
    f.willChange();
    f.addNode(index, removedNode);
    f.changed();
    view.addToSelection(f);
  }
});
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void redo() throws CannotRedoException {
  super.redo();
  view.removeFromSelection(f);
  f.willChange();
  f.removeNode(index);
  f.changed();
  view.addToSelection(f);
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

changed();
evt.consume();
return true;
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

figure.changed();
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

f.willChange();
f.setPoint(index, controlPointIndex, new Point2D.Double(oldNode.x[controlPointIndex], oldNode.y[controlPointIndex] - 1d));
f.changed();
view.getDrawing().fireUndoableEditHappened(new BezierNodeEdit(f, index, oldNode, f.getNode(index)));
evt.consume();
f.willChange();
f.setPoint(index, controlPointIndex, new Point2D.Double(oldNode.x[controlPointIndex], oldNode.y[controlPointIndex] + 1d));
f.changed();
view.getDrawing().fireUndoableEditHappened(new BezierNodeEdit(f, index, oldNode, f.getNode(index)));
evt.consume();
f.willChange();
f.setPoint(index, controlPointIndex, new Point2D.Double(oldNode.x[controlPointIndex] - 1d, oldNode.y[controlPointIndex]));
f.changed();
view.getDrawing().fireUndoableEditHappened(new BezierNodeEdit(f, index, oldNode, f.getNode(index)));
evt.consume();
f.willChange();
f.setPoint(index, controlPointIndex, new Point2D.Double(oldNode.x[controlPointIndex] + 1d, oldNode.y[controlPointIndex]));
f.changed();
view.getDrawing().fireUndoableEditHappened(new BezierNodeEdit(f, index, oldNode, f.getNode(index)));
evt.consume();
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

f.willChange();
f.setPoint(index, new Point2D.Double(oldNode.x[0], oldNode.y[0] - 1d));
f.changed();
view.getDrawing().fireUndoableEditHappened(new BezierNodeEdit(f, index, oldNode, f.getNode(index)));
evt.consume();
f.willChange();
f.setPoint(index, new Point2D.Double(oldNode.x[0], oldNode.y[0] + 1d));
f.changed();
view.getDrawing().fireUndoableEditHappened(new BezierNodeEdit(f, index, oldNode, f.getNode(index)));
evt.consume();
f.willChange();
f.setPoint(index, new Point2D.Double(oldNode.x[0] - 1d, oldNode.y[0]));
f.changed();
view.getDrawing().fireUndoableEditHappened(new BezierNodeEdit(f, index, oldNode, f.getNode(index)));
evt.consume();
f.willChange();
f.setPoint(index, new Point2D.Double(oldNode.x[0] + 1d, oldNode.y[0]));
f.changed();
view.getDrawing().fireUndoableEditHappened(new BezierNodeEdit(f, index, oldNode, f.getNode(index)));
evt.consume();
f.willChange();
final BezierPath.Node removedNode = f.removeNode(index);
f.changed();
fireHandleRequestRemove(invalidatedArea);
fireUndoableEditHappened(new AbstractUndoableEdit() {
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

createdFigure.changed();
nodeCountBeforeDrag = createdFigure.getNodeCount();
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

  figure.setPoint(index, c2, p2);
figure.changed();
fireAreaInvalidated(figure.getNode(index));
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

f.willChange();
final BezierPath.Node removedNode = f.removeNode(index);
f.changed();
fireHandleRequestRemove(invalidatedArea);
fireUndoableEditHappened(new AbstractUndoableEdit() {
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

protected void addPointToFigure(Point2D.Double newPoint) {
  int pointCount = createdFigure.getNodeCount();
  createdFigure.willChange();
  if (pointCount < 2) {
    createdFigure.addNode(new BezierPath.Node(newPoint));
  } else {
    Point2D.Double endPoint = createdFigure.getEndPoint();
    Point2D.Double secondLastPoint = (pointCount <= 1) ? endPoint : createdFigure.getPoint(pointCount - 2, 0);
    if (newPoint.equals(endPoint)) {
      // nothing to do
    } else if (pointCount > 1 && Geom.lineContainsPoint(newPoint.x, newPoint.y, secondLastPoint.x, secondLastPoint.y, endPoint.x, endPoint.y, 0.9f / getView().getScaleFactor())) {
      createdFigure.setPoint(pointCount - 1, 0, newPoint);
    } else {
      createdFigure.addNode(new BezierPath.Node(newPoint));
    }
  }
  createdFigure.changed();
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void trackStep(Point anchor, Point lead, int modifiersEx) {
  BezierFigure figure = getOwner();
  figure.willChange();
  Point2D.Double p = view.getConstrainer().constrainPoint(view.viewToDrawing(lead));
  if (getTransformOwner().get(TRANSFORM) != null) {
    try {
      getTransformOwner().get(TRANSFORM).inverseTransform(p, p);
    } catch (NoninvertibleTransformException ex) {
      ex.printStackTrace();
    }
  }
  BezierPath.Node n = figure.getNode(index);
  //fireAreaInvalidated(n);
  n.moveTo(p);
  //fireAreaInvalidated(n);
  figure.setNode(index, n);
  figure.changed();
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

f.changed();
fireHandleRequestSecondaryHandles();
org.jhotdraw.drawBezierFigurechanged

Popular methods of BezierFigure

  • <init>
    Creates an empty BezierFigure, for example without anyBezierPath.Nodes. The BezierFigure will not dr
  • clone
  • getBezierPath
    Returns a clone of the bezier path of this figure.
  • set
  • setBezierPath
  • addFigureListener
  • addNode
    Adds a control point.
  • createHandles
  • getBounds
  • getNode
    Gets a control point.
  • getNodeCount
    Gets the node count.
  • removeNode
    Removes the Node at the specified index.
  • getNodeCount,
  • removeNode,
  • restoreAttributesTo,
  • setAttributeEnabled,
  • setAttributes,
  • chop,
  • drawCaps,
  • findSegment,
  • fireUndoableEditHappened

Popular in Java

  • Running tasks concurrently on multiple threads
  • addToBackStack (FragmentTransaction)
  • putExtra (Intent)
  • scheduleAtFixedRate (Timer)
  • Dictionary (java.util)
    Note: Do not use this class since it is obsolete. Please use the Map interface for new implementatio
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • XPath (javax.xml.xpath)
    XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
  • Project (org.apache.tools.ant)
    Central representation of an Ant project. This class defines an Ant project with all of its targets,
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Best IntelliJ plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now