Examples of intersects()


Examples of java.awt.geom.Arc2D.intersects()

   * @param harness  the test harness (<code>null</code> not permitted).
   */
  public void test(TestHarness harness)     
  {
    Arc2D arc = new Arc2D.Double();
    harness.check(!arc.intersects(0.0, 0.0, 0.0, 0.0));
    harness.check(!arc.intersects(1.0, 2.0, 3.0, 4.0));

    arc = new Arc2D.Double(-1.0, -1.0, 2.0, 2.0, 0.0, 90.0, Arc2D.PIE);
    harness.check(arc.intersects(-1.0, 0.0, 1.0, 1.0));
    harness.check(arc.intersects(-1.0, -1.0, 1.0, 1.0));
View Full Code Here

Examples of java.awt.geom.Area.intersects()

    final Area area = new Area(s);
    if (clip != null)
    {
      area.intersect(clip);
    }
    return area.intersects(rect.x, rect.y, rect.width, rect.height);
  }

  /**
   * @see Graphics2D#getDeviceConfiguration()
   */
 
View Full Code Here

Examples of java.awt.geom.Ellipse2D.intersects()

      // add an entity if this info is being collected
      EntityCollection entities = null;
      if (info != null) {
        entities = info.getOwner().getEntityCollection();
        if (entities != null && circle.intersects(dataArea)) {
          addEntity(entities, circle, dataset, series, item,
              circle.getCenterX(), circle.getCenterY());
        }
      }
View Full Code Here

Examples of java.awt.geom.GeneralPath.intersects()

    return false;
  }

  public boolean intersects(Rectangle2D rect){
    GeneralPath path = makeIntoPath();
    if(path != null) return path.intersects(rect);
    return false;
  }
 
  public boolean dropsShadow(){
    return (isClosed()
View Full Code Here

Examples of java.awt.geom.Line2D.intersects()

  implements Testlet
{
  public void test(TestHarness harness)
  {
    Line2D line1 = new Line2D.Double(0.0, 0.0, 1.0, 0.0);
    harness.check(line1.intersects(0.0, -1.0, 1.0, 1.0));
    harness.check(line1.intersects(0.0, 0.0, 1.0, 1.0));
    harness.check(!line1.intersects(0.0, 1.0, 1.0, 1.0));

    harness.check(line1.intersects(new Rectangle2D.Double(0.0, -1.0, 1.0, 1.0)));
    harness.check(line1.intersects(new Rectangle2D.Double(0.0, 0.0, 1.0, 1.0)));
View Full Code Here

Examples of java.awt.geom.Path2D.intersects()

    if(shape.getLabelsDisplayed()!=PlottingStyle.NONE)
      pa.append(pathLabels, false);

    if(LNumber.equalsDouble(rotationAngle, 0.)) {
      intersects = pa.intersects(r);
    }
    else {
      final IPoint tl   = shape.getTopLeftPoint();
      final IPoint br   = shape.getBottomRightPoint();
      final double cx   = (tl.getX()+br.getX())/2.;
View Full Code Here

Examples of java.awt.geom.Rectangle2D.intersects()

                    if (text == null || text.length() == 0)
                        text = interval.getName();
                    RoundBox box = new RoundBox(text, numberOfConflicts);
                    box.setRect(paintingRect);

                    if (paintingRect.intersects(mousePositionX, mousePositionY, 1, 1)) {
                        selectedBox = box;
                        continue;
                    }

                    box.paintComponent(g2d);
View Full Code Here

Examples of java.awt.geom.Rectangle2D.Double.intersects()

             * if the map is not visible, do not render it
             */
            // JGrassRegion fileWindow = grassMapGeoResource.getFileWindow();
            Rectangle2D.Double fileRectDouble = fileWindow.getRectangle();
            Double reprojScreenRectangle = reprojectedScreenDrawWindow.getRectangle();
            if (!reprojScreenRectangle.intersects(fileRectDouble)) {
                getContext().setStatus(ILayer.DONE);
                getContext().setStatusMessage(THE_MAP_IS_OUTSIDE_OF_THE_VISIBLE_REGION);
                System.out.println(THE_MAP_IS_OUTSIDE_OF_THE_VISIBLE_REGION);
                return;
            }
View Full Code Here

Examples of java.awt.geom.RectangularShape.intersects()

           maxX = Math.max(maxX, shape.getBounds().x + shape.getBounds().width);
           maxY = Math.max(maxY, shape.getBounds().y + shape.getBounds().height);
          
           for (RectangularShape s: componentShapes)
           {
             if ( shape.intersects(s.getBounds2D()))
               componentIntersecting = true;
           }
           componentShapes.add(shape);
         }
        
View Full Code Here

Examples of java.util.BitSet.intersects()

            }

            // Prescreening - must have IF_ACMPEQ, IF_ACMPNE,
            // or an invocation of an instance method
            BitSet bytecodeSet = classContext.getBytecodeSet(method);
            if (bytecodeSet == null || !bytecodeSet.intersects(prescreenSet)) {
                continue;
            }

            if (DEBUG) {
                System.out.println("FindRefComparison: analyzing " + SignatureConverter.convertMethodSignature(methodGen));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.