introduced command pattern for editor interface