public static void cutText(OutlinerCellRendererImpl textArea, JoeTree tree, OutlineLayoutManager layout) {
		Node currentNode = textArea.node;
		
		// Abort if node is not editable
		if (!currentNode.isEditable()) {
			return;
		}

		// Copy Text
		String text = textArea.getSelectedText();
		
		if (text != null) {
			java.awt.Toolkit.getDefaultToolkit().getSystemClipboard().setContents(new StringSelection(text), null);
		}

		// Delete Text
		String oldText = textArea.getText();
		int oldCaretPosition = textArea.getCaretPosition();
		int oldMarkPosition = textArea.getCaret().getMark();

		String newText = new StringBuffer().append(oldText.substring(0,textArea.getSelectionStart())).append(oldText.substring(textArea.getSelectionEnd(),oldText.length())).toString();
		int newCaretPosition = textArea.getSelectionStart();
		Undoable undoable = new UndoableEdit(currentNode, oldText, newText, oldCaretPosition, newCaretPosition, oldMarkPosition, newCaretPosition);
		undoable.setName("Cut Text");
		tree.getDocument().getUndoQueue().add(undoable);
		UndoableEdit.freezeUndoEdit(currentNode);
		
		textArea.node.setValue(newText);
		textArea.setText(newText);
		textArea.setCaretPosition(newCaretPosition);
		textArea.moveCaretPosition(newCaretPosition);

		// Record the EditingNode, Mark and CursorPosition
		tree.setEditingNode(currentNode);
		tree.setCursorMarkPosition(newCaretPosition);
		tree.setCursorPosition(newCaretPosition, false);
		tree.getDocument().setPreferredCaretPosition(newCaretPosition);

		// Do the Redraw if we have wrapped or if we are currently off screen.
		if (textArea.getPreferredSize().height != textArea.height || !currentNode.isVisible()) {
			layout.draw(currentNode, OutlineLayoutManager.TEXT);
		}
	}