Scroll bar en JInternalFrame?

2019-09-24 05:21发布

问题:

I have a question.

I have a JInternalFrame, with input-texts, combo-boxes, panels, almost finalized... but, it is bigger than the JFrame...

I don't want to do all back.. So, Can I add a scroll bar without add a scroll panel? How I to do?

Sorry for my English.

回答1:

Can I add a scroll bar without add a scroll panel? How I to do?

Why not use a JScrollPane?

Simply add your main JPanel or contentPane to a JScrollPane, add it to your JInternalFrame, and you're done. This is really you're only solution, either that or re-think your GUI structure so that you display information in a more efficient manner.