String oldText = labelText; labelText = text; firePropertyChange(TEXT_CHANGED_PROPERTY, oldText, labelText); if (labelText != null && labelText.length() <= underlinedChar) setDisplayedMnemonicIndex(labelText.length() - 1);
String oldText = text; text = newText; firePropertyChange(TEXT_CHANGED_PROPERTY, oldText, newText);  if (text != null && text.length() <= displayedMnemonicIndex) setDisplayedMnemonicIndex(text.length() - 1);
  public void setText(String text)  {    if (text != labelText)      {	String oldText = labelText;	labelText = text;	firePropertyChange(TEXT_CHANGED_PROPERTY, oldText, labelText);	if (labelText != null && labelText.length() <= underlinedChar)	  setDisplayedMnemonicIndex(labelText.length() - 1);      }  }