I am trying to cast combo box to string but I have problems with it. I get NullPointerException?
fontStyle = (String)combo.getSelectedItem();
size = (String)comboSize.getSelectedItem();
if (fontStyle.equals("Regular") && size.equals("10"))
{
Font font = new Font(Font.SANS_SERIF, Font.PLAIN, 10);
text.setFont(font);
}