abel.setBusy(true); Another more complicated example:
JXBusyLabel label = new JXBusyLabel(new Dimension(100,84)); BusyPainter painter = new BusyPainter( new Rectangle2D.Float(0, 0,13.500001f,1), new RoundRectangle2D.Float(12.5f,12.5f,59.0f,59.0f,10,10)); painter.setTrailLength(5); painter.setPoints(31); painter.setFrame(1); label.setPreferredSize(new Dimension(100,84)); label.setIcon(new EmptyIcon(100,84)); label.setBusyPainter(painter);
Another example:
JXBusyLabel label = new MyBusyLabel(new Dimension(100, 84));
where MyBusyLabel is:
public class MyBusyLabel extends JXBusyLabel { public MyBusyLabel(Dimension prefSize) { super(prefSize); } protected BusyLabel createBusyLabel(Dimension dim) { BusyPainter painter = new BusyPainter( new Rectangle2D.Float(0, 0,13.500001f,1), new RoundRectangle2D.Float(12.5f,12.5f,59.0f,59.0f,10,10)); painter.setTrailLength(5); painter.setPoints(31); painter.setFrame(1); return painter; } }
@author rbair
@author joshy
@author rah003
@author headw01