1

I created full screen jform using netbeans in java. I need to create Full Screen width sized jtoolbar. How I do this?

this code I use for create full screen size jform / jform resize

Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
setBounds(0, 0, screenSize.width, screenSize.height);
Andrew Thompson
  • 168,117
  • 40
  • 217
  • 433

1 Answers1

-1

Use JToolBar inherithed method Component::setBounds.

Place ToolBar at TOP:

toolBar.setBounds(0, 0, screenSize.width, yourDesiredHeight);

Place ToolBar at BOTTOM:

toolBar.setBounds(0, screensize.height - yourDesiredHeight, screenSize.width, yourDesiredHeight);
Jordi Castilla
  • 26,609
  • 8
  • 70
  • 109