GridBagLayout component not filling space as it should

前端 未结 1 888
长发绾君心
长发绾君心 2021-01-23 23:25

I\'m making a program that uses lots of different compenents, so I\'ve started using a GridBagLayout for it. It\'s working great, but when I run the program I get this:

1条回答
  •  挽巷
    挽巷 (楼主)
    2021-01-23 23:58

    I simply had to put weightx = 1 within my NoteBox inner class, as suggested by MadProgrammer. This fixed the issue entirely, I'm just writing this to formally mark the answer as solved.

    0 讨论(0)
提交回复
热议问题