如何增加JXBusyLabel的大小?

时间:2022-05-21 17:22:00

I've got the following code:

我有以下代码:

  JXBusyLabel label = new JXBusyLabel();      
  label.setBusy(true);
  label.setSize(100, 100);
  frame.add(label);

I need a circle indicator of loading, and this code is good. But I need to increase size of circle, because now it has got a very small size. But setSize method doesn't allow me to do what I want. Please, tell me, how can I do it?

我需要一个加载的圆圈指示器,这个代码很好。但我需要增加圆的大小,因为现在它的尺寸非常小。但是setSize方法不允许我做我想要的。请告诉我,我该怎么办?

1 个解决方案

#1


0  

From the swingx javadoc, you can pass a Dimension object to JXBusyLabel like this:

从swingx javadoc中,您可以将Dimension对象传递给JXBusyLabel,如下所示:

JXBusyLabel label = new JXBusyLabel(new Dimension(100,84));

JXBusyLabel label = new JXBusyLabel(new Dimension(100,84));

#1


0  

From the swingx javadoc, you can pass a Dimension object to JXBusyLabel like this:

从swingx javadoc中,您可以将Dimension对象传递给JXBusyLabel,如下所示:

JXBusyLabel label = new JXBusyLabel(new Dimension(100,84));

JXBusyLabel label = new JXBusyLabel(new Dimension(100,84));