Re: JSplitPane divider component and JPopupMenu panel
- From: Daniel Pitts <googlegroupie@xxxxxxxxxxxxx>
- Date: Mon, 30 Jul 2007 16:24:23 -0700
On Jul 27, 2:15 am, Karsten Wutzke <kwut...@xxxxxx> wrote:
Hello!I count three, but thats okay...
I have two questions:
Do you mean custom JComponents in the JSplitPane? Yes that is
1. Is it possible to use the JSplitPane's divider as a divider between
components with custom behavior (or doing nothing, not movable, or at
least only into one direction)?
possible.
If you bothered to read <http://java.sun.com/j2se/1.4.2/docs/api/javax/
2. Is it possible to restrict how far to move the divider left and
right?
swing/JSplitPane.html>, you might have noticed the
setMaximumDividerLocation and setMinimumDividerLocation methods that
do exactly that.
JPopupMenus "want" to use the look and feel menu style, and I would
3. JPopupMenu's use JMenuItem subclasses to add their items, how do I
make a JPopupMenu use a GridLayout panel with JButtons instead? It
very much looks like the ICQ/MSN smiley popup...
suggest you let it. If you want to use the look and feel of your
system, you can add the following snippet to your main method:
try {
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
} catch (Exception e) {
// Look and Feel exceptions aren't fatal
}
TIA
Karsten
.
- References:
- JSplitPane divider component and JPopupMenu panel
- From: Karsten Wutzke
- JSplitPane divider component and JPopupMenu panel
- Prev by Date: Re: Swing thread problem
- Next by Date: Re: Swing thread problem
- Previous by thread: JSplitPane divider component and JPopupMenu panel
- Next by thread: Swing application getting affected by screen resolution
- Index(es):