Stable version -- with undo and redo not implement totally