Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.gui > #2087
| From | "Roedy Green" <roedy.green@THRWHITE.remove-dii-this> |
|---|---|
| Subject | Re: Drawing line from one |
| Message-ID | <ihpu93pu221nth45bk4fstsl85h0k3o2vr@4ax.com> (permalink) |
| Newsgroups | comp.lang.java.gui |
| References | <1184833700.027591.297070@e9g2000prf.googlegroups.com> |
| Date | 2011-04-27 15:37 +0000 |
| Organization | TDS.net |
To: comp.lang.java.gui On Thu, 19 Jul 2007 01:28:20 -0700, Chanchal <chanchal.jacob@gmail.com> wrote, quoted or indirectly quoted someone who said : >I'm developing some thing like an electronic circuit designer. I have >a number of JButtons placed programatically on a JPanel. Now I need to >draw lines between pairs of JButtons by dragging mouse from one button >to another one. Please advice on how such a thing can be implemented. >Also i should be able to delete such lines drawn. KIndly advice >Thanks in advance. See http://mindprod.com/jgloss/pane.html The trick might be to draw the lines on a different pane. You let the layout manager place the buttons, then you ask the buttons where they are with getLocation. -- Roedy Green Canadian Mind Products The Java Glossary http://mindprod.com --- * Synchronet * The Whitehouse BBS --- whitehouse.hulds.com --- check it out free usenet! --- Synchronet 3.15a-Win32 NewsLink 1.92 Time Warp of the Future BBS - telnet://time.synchro.net:24
Back to comp.lang.java.gui | Previous | Next — Previous in thread | Find similar | Unroll thread
Drawing line from one JBu "Chanchal" <chanchal@THRWHITE.remove-dii-this> - 2011-04-27 15:37 +0000 Re: Drawing line from one "Jeff Higgins" <jeff.higgins@THRWHITE.remove-dii-this> - 2011-04-27 15:37 +0000 Re: Drawing line from one "Roedy Green" <roedy.green@THRWHITE.remove-dii-this> - 2011-04-27 15:37 +0000
csiph-web