if (getSelectedText() == null || (textComp.getText().equals(""))) return 0; return textComp.getSelectionEnd();
return JTextComponent.this.getSelectionEnd();
    public int getSelectionEnd()    {      if (getSelectedText() == null || (textComp.getText().equals("")))        return 0;      return textComp.getSelectionEnd();    }