Caffeinated
Caffeinated

Reputation: 12484

How do I Start Eclipse project with GUI windows spaced out?

I'm running a large Java Eclipse project and when it starts up, I see 3 pop-up windows tiled on top of each other, as so:

enter image description here

I need to have them start up separated positions, as I'm always testing the program and dragging the windows. Can I somehow put them all in a bigger GUI window(pane)?

Upvotes: 0

Views: 340

Answers (2)

PeakGen
PeakGen

Reputation: 23035

Use setLocation() method

windowName.setLocation(location_parameters);

passing the 'null' as an argument will make the window center.

There is another way,

setLocationRelatedTo(item_to_relate)

method. this will locate them according to the existing things like JLabels, existing windows, etc.

Upvotes: 2

Gilbert Le Blanc
Gilbert Le Blanc

Reputation: 51565

Can I somehow put them all in a bigger GUI window(pane)?

You presently have 3 JFrames, I think.

You could change this to 3 JPanels in one frame.

You would use a layout manager to arrange the 3 JPanels the way you want.

Upvotes: 1

Related Questions