private void updateStyle() {
		if (customCheckbox.isSelected()) {
			int style = Font.PLAIN;
			if (boldCheckbox.isSelected()) {
				style |= Font.BOLD;
			}
			if (italicsCheckbox.isSelected()) {
				style |= Font.ITALIC;
			}
			elements[selectedIndex].setStyle(style);
		}
		else {
			elements[selectedIndex].setStyle(-1);
		}
		setSelectedIndex(selectedIndex);
	}
updates the style of the field at the selected index.
Ghidra/Features/Base/src/main/java/ghidra/app/util/viewer/options/OptionsGui.java