Codota Logo
org.jhotdraw.draw
Code IndexAdd Codota to your IDE (free)

How to use org.jhotdraw.draw

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

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
ScheduledThreadPoolExecutor s =
  • Codota Iconnew ScheduledThreadPoolExecutor(corePoolSize)
  • Codota IconThreadFactory threadFactory;new ScheduledThreadPoolExecutor(corePoolSize, threadFactory)
  • Codota IconString str;new ScheduledThreadPoolExecutor(1, new ThreadFactoryBuilder().setNameFormat(str).build())
  • Smart code suggestions by Codota
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

/**
 * Transforms the figure.
 */
@Override
public void transform(AffineTransform tx) {
  super.transform(tx);
  for (Figure f : children) {
    f.transform(tx);
  }
  invalidate();
}
@Override
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public boolean contains(Point2D.Double p) {
  boolean contains = super.contains(p);
  if (!contains && getPresentationFigure() != null) {
    contains = getPresentationFigure().contains(p);
  }
  return contains;
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void activate(DrawingEditor editor) {
  this.editor = editor;
  editorProxy.setTarget(editor);
  isActive = true;
  // Repaint all handles
  for (DrawingView v : editor.getDrawingViews()) {
    v.repaintHandles();
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public Figure removeChild(int index) {
  willChange();
  Figure figure = basicRemoveChild(index);
  if (getDrawing() != null) {
    figure.removeNotify(getDrawing());
  }
  changed();
  return figure;
}
@Override
origin: net.imagej/imagej-ui-swing

@SuppressWarnings("rawtypes")
@Override
public void setAttributeEnabled(AttributeKey key, boolean b) {
  super.setAttributeEnabled(key, b);
  for (final BezierFigure figure : figures) {
    figure.setAttributeEnabled(key, b);
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

protected <T> void setAttributeOnChildren(AttributeKey<T> key, T newValue) {
  for (Figure child : getChildren()) {
    child.set(key, newValue);
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

/**
 * Sends a figure to the back of the composite figure.
 *
 * @param figure that is part of this composite figure
 */
public void sendToBack(Figure figure) {
  if (basicRemove(figure) != -1) {
    basicAdd(0, figure);
    fireAreaInvalidated(figure.getDrawingArea());
  }
}
origin: net.imagej/imagej-ui-swing

@Override
public void restoreAttributesTo(Object restoreData) {
  super.restoreAttributesTo(restoreData);
  for (final BezierFigure figure : figures) {
    figure.restoreAttributesTo(restoreData);
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void removeNotify(Drawing drawing) {
  super.removeNotify(drawing);
  if (getPresentationFigure() != null) {
    getPresentationFigure().removeNotify(drawing);
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

/**
 * Standard presentation method which is delegated to the encapsulated presentation figure.
 * The presentation figure is moved as well as all contained figures.
 */
@Override
public void transform(AffineTransform tx) {
  super.transform(tx);
  if (getPresentationFigure() != null) {
    getPresentationFigure().transform(tx);
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

/**
 * Return the logcal display area. This method is delegated to the encapsulated
 * presentation figure.
 */
@Override
public Rectangle2D.Double getBounds() {
  if (getPresentationFigure() == null) {
    return super.getBounds();
  }
  return getPresentationFigure().getBounds();
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void addNotify(Drawing drawing) {
  super.addNotify(drawing);
  if (getPresentationFigure() != null) {
    getPresentationFigure().addNotify(drawing);
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void addNotify(Drawing drawing) {
  super.addNotify(drawing);
  for (Figure child : getChildren()) {
    child.addNotify(drawing);
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public Figure findFigure(Point2D.Double p) {
  for (Figure f : getFiguresFrontToBack()) {
    if (f.isVisible() && f.contains(p)) {
      return f;
    }
  }
  return null;
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void willChange() {
  super.willChange();
  for (Figure child : children) {
    child.willChange();
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

public void remap(HashMap<Figure, Figure> oldToNew, boolean disconnectIfNotInMap) {
  super.remap(oldToNew, disconnectIfNotInMap);
  if (presentationFigure != null) {
    presentationFigure.remap(oldToNew, disconnectIfNotInMap);
  }
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

/**
 *  Notify all listenerList that have registered interest for
 * notification on this event type.
 */
protected void fireUndoableEditHappened(UndoableEdit edit) {
  view.getDrawing().fireUndoableEditHappened(edit);
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void read(DOMInput in) throws IOException {
  super.read(in);
  readAttributes(in);
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
protected void validate() {
  super.validate();
  layout();
}
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

@Override
public void changed() {
  for (Figure child : children) {
    child.changed();
  }
  super.changed();
}
org.jhotdraw.draw

Most used classes

  • Figure
    A figure is a graphical element of a Drawing. A figure can be only in one drawing at a time. Figure
  • AbstractAttributedFigure
    This abstract class can be extended to implement a Figurewhich has its own attribute set.
  • AttributeKeys
    Defines a put of well known Figure attributes. If you are developing an applications that uses a dif
  • BezierFigure
    A Figure which draws an opened or a closed bezier path. A bezier figure can be used to draw arbitrar
  • DefaultDrawing
    A default implementation of Drawing useful for drawings which contain only a few figures. For larger
  • DefaultDrawingView,
  • Drawing,
  • DrawingEditor,
  • DrawingView,
  • ImageFigure,
  • RectangleFigure,
  • ArrowTip,
  • FigureSelectionEvent,
  • BezierNodeHandle,
  • BezierOutlineHandle,
  • DragHandle,
  • AbstractTool,
  • BezierTool,
  • CreationTool
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now