Added CurveEngine.run_command and reorganized CommandStack._execute