Help : Implementing rubberbanding (moving shapes) in Applet

From: Ajay Patil (ajaypatilpune_at_hotmail.com)
Date: 12/12/03


Date: 11 Dec 2003 20:39:42 -0800

Hello,

I need the advice on how to implement rubberbanding and moving rectangles
in an applet.

I can think of two approaches.
1. Use Java 2D and handle mouse events in the panel.
2. Draw each rectangle as a AWT/Swing component and let it handle its own
   mouse events.

Can someone advice me which of the above approaches is better.

In the second approach, I was thinking that if I use a layout manager like
GridBagLayout, then I wont be able to control exact locations of the rectangles.

Your help/advice is appreciated.

Ajay



Relevant Pages

  • Need advice on implementing drag/drop rectangles in applet
    ... I need the advice on how to implement drag/drop rectangles in an applet. ... Use Java 2D and handle mouse events in the panel. ... then I wont be able to control exact locations of the rectangles. ...
    (comp.lang.java.programmer)
  • Re: finding the area of highest concentration
    ... > advice here. ... Basically I have a series of rectangles in a Cartesian ... > calculating the centre point of each rectangle in the plane and then ... Thsnks a lot, Joe ...
    (sci.math)
  • finding the area of highest concentration
    ... advice here. ... Basically I have a series of rectangles in a Cartesian ... plane and I would like to find the area of highest density (also a ... calculating the centre point of each rectangle in the plane and then ...
    (sci.math)
  • finding the area of highest concentration
    ... advice here. ... Basically I have a series of rectangles in a Cartesian ... plane and I would like to find the area of highest density (also a ... calculating the centre point of each rectangle in the plane and then ...
    (sci.math)
  • Re: need suggestions for technologies to use for a web application
    ... Users can drag drawing shapes (rectangles, circles, images, text ... made up primarily of java programmers, so I would be partial to using ... I've written some applet code and can't recommend it. ...
    (comp.lang.misc)

Loading