JLabel « JComboBox « Java Swing Q&A





1. Jlabel inside combobox    coderanch.com

2. clone JLabel, JComboBox objects    coderanch.com

You will not be able to clone swing components because in general, as they do not implement the Cloneable interface. Yes, you will need to create the new JLabel by the first way, and if any other properties(like alignment,color) are set to the first object, you need to manually set it in the second one too. Or alternatively you can write ...