Home > Back-end >  Java drop-down menu frame to go out?
Java drop-down menu frame to go out?

Time:02-24


Custom menu as shown in figure, the frame can't go out, want to set it couldn't be the same color with the background?
The used methods:
Enclosing setUI (new MenuUI (uiBackgroung uiForeground));
Enclosing addActionListener (the listener);//estimate the response is menu plug is the internal events, no response
Enclosing setBorder (BorderFactory createLineBorder (background, 0));
//this. SetBorder (BorderFactory createBevelBorder (0));
//this. SetBorderPainted (false);
Enclosing setFocusPainted (false);

In the JMenu and JMenuItem tried?
Who is this line?
  • Related