Index: src/Actions/GlobalListOfActions.hpp
===================================================================
--- src/Actions/GlobalListOfActions.hpp	(revision 3ce0f13dab1ee13c2e8e829c15cf3a7273768d19)
+++ src/Actions/GlobalListOfActions.hpp	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
@@ -127,4 +127,5 @@
   (ShapeRemoveShape) \
   (ShapeRotateShape) \
+  (ShapeStretchShape) \
   (ShapeTranslateShape)
 
Index: src/Actions/Makefile.am
===================================================================
--- src/Actions/Makefile.am	(revision 3ce0f13dab1ee13c2e8e829c15cf3a7273768d19)
+++ src/Actions/Makefile.am	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
@@ -436,4 +436,5 @@
   Actions/ShapeAction/RemoveShapeAction.cpp \
   Actions/ShapeAction/RotateShapeAction.cpp \
+  Actions/ShapeAction/StretchShapeAction.cpp \
   Actions/ShapeAction/TranslateShapeAction.cpp
 SHAPEACTIONHEADER = \
@@ -442,4 +443,5 @@
   Actions/ShapeAction/RemoveShapeAction.hpp \
   Actions/ShapeAction/RotateShapeAction.hpp \
+  Actions/ShapeAction/StretchShapeAction.hpp \
   Actions/ShapeAction/TranslateShapeAction.hpp
 SHAPEACTIONDEFS = \
@@ -448,4 +450,5 @@
   Actions/ShapeAction/RemoveShapeAction.def \
   Actions/ShapeAction/RotateShapeAction.def \
+  Actions/ShapeAction/StretchShapeAction.def \
   Actions/ShapeAction/TranslateShapeAction.def
 	
Index: src/Actions/ShapeAction/StretchShapeAction.cpp
===================================================================
--- src/Actions/ShapeAction/StretchShapeAction.cpp	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
+++ src/Actions/ShapeAction/StretchShapeAction.cpp	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
@@ -0,0 +1,118 @@
+/*
+ * Project: MoleCuilder
+ * Description: creates and alters molecular systems
+ * Copyright (C)  2010-2012 University of Bonn. All rights reserved.
+ *
+ *
+ *   This file is part of MoleCuilder.
+ *
+ *    MoleCuilder is free software: you can redistribute it and/or modify
+ *    it under the terms of the GNU General Public License as published by
+ *    the Free Software Foundation, either version 2 of the License, or
+ *    (at your option) any later version.
+ *
+ *    MoleCuilder is distributed in the hope that it will be useful,
+ *    but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *    GNU General Public License for more details.
+ *
+ *    You should have received a copy of the GNU General Public License
+ *    along with MoleCuilder.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+/*
+ * StretchShapeAction.cpp
+ *
+ *  Created on: Nov 19, 2012
+ *      Author: ankele
+ */
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "CodePatterns/MemDebug.hpp"
+
+#include "Shapes/ShapeRegistry.hpp"
+#include "Shapes/ShapeOps.hpp"
+#include "CodePatterns/Log.hpp"
+#include "CodePatterns/Verbose.hpp"
+
+#include <iostream>
+#include <string>
+
+#include "StretchShapeAction.hpp"
+
+using namespace MoleCuilder;
+
+// and construct the stuff
+#include "StretchShapeAction.def"
+#include "Action_impl_pre.hpp"
+/** =========== define the function ====================== */
+Action::state_ptr ShapeStretchShapeAction::performCall() {
+  LOG(1, "Translating shapes in ShapeRegistry.");
+
+  std::vector<Shape*> selectedShapes = ShapeRegistry::getInstance().getSelectedShapes();
+
+  std::vector<Shape> old_shapes;
+
+  Vector helper = params.center.get();
+  helper.ScaleAll(params.stretch.get());
+  Vector translation = params.center.get() - helper;
+
+  for (unsigned int i=0;i<selectedShapes.size();i++){
+    old_shapes.push_back(*selectedShapes[i]);
+    Shape s = translate(stretch(*selectedShapes[i], params.stretch.get()), translation);
+    std::string name = selectedShapes[i]->getName();
+    s.setName(name);
+    ShapeRegistry::getInstance().removeShape(name);
+    ShapeRegistry::getInstance().addShape(s);
+    ShapeRegistry::getInstance().selectShape(name);
+  }
+
+  return Action::state_ptr(new ShapeStretchShapeState(old_shapes, params));
+}
+
+Action::state_ptr ShapeStretchShapeAction::performUndo(Action::state_ptr _state) {
+  ShapeStretchShapeState *state = assert_cast<ShapeStretchShapeState*>(_state.get());
+
+  for (unsigned int i=0;i<state->old_shapes.size();i++){
+    std::string name = state->old_shapes[i].getName();
+    ShapeRegistry::getInstance().removeShape(name);
+    ShapeRegistry::getInstance().addShape(state->old_shapes[i]);
+    ShapeRegistry::getInstance().selectShape(name);
+  }
+
+  return Action::state_ptr(_state);
+}
+
+Action::state_ptr ShapeStretchShapeAction::performRedo(Action::state_ptr _state){
+  ShapeStretchShapeState *state = assert_cast<ShapeStretchShapeState*>(_state.get());
+
+  std::vector<Shape*> selectedShapes = ShapeRegistry::getInstance().getSelectedShapes();
+
+  Vector helper = params.center.get();
+  helper.ScaleAll(params.stretch.get());
+  Vector translation = params.center.get() - helper;
+
+  for (unsigned int i=0;i<selectedShapes.size();i++){
+    Shape s = translate(stretch(*selectedShapes[i], params.stretch.get()), translation);
+    std::string name = selectedShapes[i]->getName();
+    s.setName(name);
+    ShapeRegistry::getInstance().removeShape(name);
+    ShapeRegistry::getInstance().addShape(s);
+    ShapeRegistry::getInstance().selectShape(name);
+  }
+
+  return Action::state_ptr(_state);
+}
+
+bool ShapeStretchShapeAction::canUndo() {
+  return true;
+}
+
+bool ShapeStretchShapeAction::shouldUndo() {
+  return true;
+}
+/** =========== end of function ====================== */
Index: src/Actions/ShapeAction/StretchShapeAction.def
===================================================================
--- src/Actions/ShapeAction/StretchShapeAction.def	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
+++ src/Actions/ShapeAction/StretchShapeAction.def	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
@@ -0,0 +1,39 @@
+/*
+ * StretchShapeAction.def
+ *
+ *  Created on: Nov 23, 2012
+ *      Author: ankele
+ */
+
+// all includes and forward declarations necessary for non-integral types below
+#include <boost/filesystem.hpp>
+
+#include "Parameters/Validators/DummyValidator.hpp"
+class Shape;
+
+// i.e. there is an integer with variable name Z that can be found in
+// ValueStorage by the token "Z" -> first column: int, Z, "Z"
+// "undefine" if no parameters are required, use (NOPARAM_DEFAULT) for each (undefined) default value
+#define paramtypes (Vector)(Vector)
+#define paramtokens ("stretch-shapes")("center")
+#define paramdescriptions ("scaling factors")("center of stretching")
+#define paramdefaults (PARAM_DEFAULT(Vector(1.,1.,1.)))(PARAM_DEFAULT(Vector(0.,0.,0.)))
+#define paramreferences (stretch)(center)
+#define paramvalids \
+(DummyValidator<Vector>()) \
+(DummyValidator<Vector>())
+
+#define statetypes (std::vector<Shape>)
+#define statereferences (old_shapes)
+
+// some defines for all the names, you may use ACTION, STATE and PARAMS
+#define CATEGORY Shape
+#define MENUNAME "shape"
+#define MENUPOSITION 6
+#define ACTIONNAME StretchShape
+#define TOKEN "stretch-shapes"
+
+
+// finally the information stored in the ActionTrait specialization
+#define DESCRIPTION "stretches selected shapes in ShapeRegistry"
+#undef SHORTFORM
Index: src/Actions/ShapeAction/StretchShapeAction.hpp
===================================================================
--- src/Actions/ShapeAction/StretchShapeAction.hpp	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
+++ src/Actions/ShapeAction/StretchShapeAction.hpp	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
@@ -0,0 +1,22 @@
+/*
+ * StretchShapeAction.hpp
+ *
+ *  Created on: Nov 23, 2012
+ *      Author: ankele
+ */
+
+#ifndef STRETCHSHAPEACTION_HPP_
+#define STRETCHSHAPEACTION_HPP_
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+
+#include "Actions/Action.hpp"
+
+#include "StretchShapeAction.def"
+#include "Action_impl_header.hpp"
+
+#endif /* STRETCHSHAPEACTION_HPP_ */
Index: src/UIElements/Views/Qt4/QtShapeController.cpp
===================================================================
--- src/UIElements/Views/Qt4/QtShapeController.cpp	(revision 3ce0f13dab1ee13c2e8e829c15cf3a7273768d19)
+++ src/UIElements/Views/Qt4/QtShapeController.cpp	(revision 29ea65c708b2778dfed09f35f53078f9ae87ceed)
@@ -94,4 +94,8 @@
   connect(action, SIGNAL(triggered()), pipe, SLOT(called()));
   editMenu->addAction(action);
+  pipe = new QtMenuPipe("stretch-shapes", action);
+  action = new QAction(QIcon::fromTheme("zoom-best-fit"), tr("stretch"), this);
+  connect(action, SIGNAL(triggered()), pipe, SLOT(called()));
+  editMenu->addAction(action);
   editButton->setMenu(editMenu);
 
