Answer the question
In order to leave comments, you need to log in
Change edge color in JMenu?
I created a JMenuBar and JMenu in it, added all the necessary styles, but bad luck - the top and bottom gaps are white:
How to remove this?
Answer the question
In order to leave comments, you need to log in
"look and fill " is responsible for the borders
https://docs.oracle.com/javase/tutorial/uiswing/lo...
https://progi.pro/swing-lf-import-i-realizaciya-6...
Try calling this method:
/**
* Sets the current system look and feel properties
*/
public static void setSystemLookAndFeel() {
/* Get the default operation system style */
final String uiName = UIManager.getSystemLookAndFeelClassName();
/* Set this default current style for our task */
try {
UIManager.setLookAndFeel( uiName );
} catch ( Exception ex ) {
System.err.printf( "--- Can't set GUI default system style (%s):%s%n", uiName, ex.getMessage() );
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question