JPanel 未正确对齐
我正在尝试在一个大面板中对齐 2 个 JPanles。我无法正确对齐它们。我在此处提供了源代码的链接。如果运行源代码,您可以看到“新付款方式”单选按钮位于中心,而不是位于付款选项面板的正下方。我怎样才能到达那里。我非常抱歉无法发布屏幕截图以及很长的代码。提前致谢。
I am trying to align 2 JPanles in a big panel. I am not able to align them properly. I am giving the link to the source code here. If you run the source code, you can see that the New Payment Method Radio Button is at the centre and and not just below the payment options panel. How do i get it there. I am extremely sorry for not able to post the screenshot and also for the long code. THANKS A TON IN ADVANCE.
作为替代方案,请考虑
BoxLayout
,如下所示。As an alternative, consider
BoxLayout
, shown below.