• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

can you resolve these questions?Thanks.

 
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
1. How to draw a line link from a selected item of JList to other selected item of JList in JDesktopPane?
2. is JDesktopPane able scroll? if yes , How to write code?

thanks.

----cat


---------------------------------------------------
love you.if you are g
 
cat cater
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
like PowerBuild's DataWindow
 
Ranch Hand
Posts: 410
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
For the scrolling, just add everything to a JPanel, add that to a JScrollPane, and add the scrollpane to your JDesktopPane.

Sounds to me like you're writing some kind of diagramming tool; if you, perhaps you could check out JGraph (www.jgraph.com). I hear it is supposed to be useful for creating that kind of thing.
 
cat cater
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
First,thank you Stuart Gray.
now,many JInternalFrame in JDesktopPane,and not other components.
I try to add JScrollPane to JDesktopPane, but the JInternalFrame does'n visible in JDesktopPane.
 
Stuart Gray
Ranch Hand
Posts: 410
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Try calling moveToFront() on one of the JInternalFrames. If that doesn't work, the solution might be to make another JInternalFrame for your scrolling area, and then resize that as appropriate. Not ideal, but it might be the only way.
 
cat cater
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
oh,I made a mistake . I should add JDesktopPane to JScrollPane,and resize JDesktopPane's size.

----code----
JDesktopPane.setPreferredSize(new Dimension(0,2000));
JDesktopPane.validate();
------------------------------------------------------
well,but it doesnot autoscroll. somebody tell me use "implements Scrollable".
find help.

!@_@!


-----cat
 
Stuart Gray
Ranch Hand
Posts: 410
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Really? I'm a bit surprised by that, but glad it works
 
cat cater
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
1. How to draw a line link from a selected item of JList to other selected item of JList in JDesktopPane?
 
Ranch Hand
Posts: 1535
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic