textAlignCombo.setModel(new DefaultComboBoxModel(TextAlign.values()));
textAlignCombo.setSelectedItem(style.getTextAlign());
textAlignCombo.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
TextAlign selected = (TextAlign) textAlignCombo.getSelectedItem();
style.setTextAlign(selected);
fireStyleChanged();
}
});