public void postMaintenanceEventMsg(String msg) { try { doc.insertString(doc.getLength(), msg + "\n", MsgBox.getStyle("Maintenance")); } catch (BadLocationException e) { displayError(e.getMessage()); } MsgBox.setCaretPosition(doc.getLength()); }