Changed programming model to separate GUI from the actual scripting components.