- try {
- textarea.getEditorKit().write(sw, textarea.getDocument(), textarea.getSelectionStart(), textarea.getSelectionEnd()-textarea.getSelectionStart());
- } catch (Exception x){};
- StringSelection ssel=new StringSelection(sw.getBuffer().toString());
- c.setContents(ssel,ssel);
+ try
+ {
+ textarea.getEditorKit().write(sw, textarea.getDocument(),
+ textarea.getSelectionStart(),
+ textarea.getSelectionEnd() - textarea.getSelectionStart());
+ } catch (Exception x)
+ {
+ }
+ ;
+ StringSelection ssel = new StringSelection(sw.getBuffer().toString());
+ c.setContents(ssel, ssel);