Tabnine Logo
RectangleFigure.setBounds
Code IndexAdd Tabnine to your IDE (free)

How to use
setBounds
method
in
org.jhotdraw.draw.RectangleFigure

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

origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

/**
 * Moves the Figure to a new location.
 * @param tx the transformation matrix.
 */
@Override
public void transform(AffineTransform tx) {
  Point2D.Double anchor = getStartPoint();
  Point2D.Double lead = getEndPoint();
  setBounds(
      (Point2D.Double) tx.transform(anchor, anchor),
      (Point2D.Double) tx.transform(lead, lead)
      );
}

origin: stackoverflow.com

 // from your code
rectangle.setBackgroundColor(ColorConstants.green);

// new code
RectangleFigure r2 = new RectangleFigure();
r2.setBounds(new Rectangle(0,0,10,10));
r2.setBackgroundColor(ColorConstants.blue);
rectangle.add(r2);

// back to your code
lws.setContents(rectangle);
origin: stackoverflow.com

 ...

RectangleFigure rect=new RectangleFigure();
rect.setBounds(new Rectangle(10, 10, 5, 25));
rect.setBorder(new SimpleRaisedBorder());
rect.setLayoutManager(new StackLayout());

RectangleFigure rect2=new RectangleFigure();
rect2.setBounds(new Rectangle(10, 10, 5, 25));
rect2.setBorder(new SimpleRaisedBorder());
rect2.setLayoutManager(new StackLayout());

...

fp.add(content);
rect2.add(fp);
rect.add(rect2);
panel.add(rect);
origin: net.imagej/imagej-ui-swing

@Override
public void
  updateFigure(final OverlayView view, final RectangleFigure figure)
{
  super.updateFigure(view, figure);
  final RectangleOverlay overlay = downcastOverlay(view.getData());
  final double x0 = overlay.getOrigin(0);
  final double y0 = overlay.getOrigin(1);
  final double w = overlay.getExtent(0);
  final double h = overlay.getExtent(1);
  final Point2D.Double anch = new Point2D.Double(x0, y0);
  final Point2D.Double lead = new Point2D.Double(x0 + w, y0 + h);
  figure.setBounds(anch, lead);
}
origin: stackoverflow.com

Rectangle rect = new Rectangle(droppoint.x, droppoint.y, 20, 20);
Rectangle rect2 = new Rectangle(droppoint.x, droppoint.y, 100, 25);
node1.setBounds(rect);
node1.setBackgroundColor(ColorConstants.cyan);
origin: org.opentcs.thirdparty.jhotdraw/jhotdraw

ta.setBounds(new Point2D.Double(10, 10), new Point2D.Double(100, 100));
tb.setBounds(new Point2D.Double(210, 110), new Point2D.Double(300, 200));
org.jhotdraw.drawRectangleFiguresetBounds

Popular methods of RectangleFigure

  • <init>
  • getBounds
  • add
  • findConnector
  • getChildren
  • getEndPoint
  • getStartPoint
  • set
  • setAttributeEnabled
  • setBackgroundColor
  • setBorder
  • setLayoutManager
  • setBorder,
  • setLayoutManager

Popular in Java

  • Making http requests using okhttp
  • addToBackStack (FragmentTransaction)
  • notifyDataSetChanged (ArrayAdapter)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • Menu (java.awt)
  • Thread (java.lang)
    A thread is a thread of execution in a program. The Java Virtual Machine allows an application to ha
  • SocketTimeoutException (java.net)
    This exception is thrown when a timeout expired on a socket read or accept operation.
  • KeyStore (java.security)
    KeyStore is responsible for maintaining cryptographic keys and their owners. The type of the syste
  • Scanner (java.util)
    A parser that parses a text string of primitive types and strings with the help of regular expressio
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • Top 25 Plugins for Webstorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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