Index: branches/std/src/lib/Makefile.am
===================================================================
--- branches/std/src/lib/Makefile.am	(revision 7202)
+++ branches/std/src/lib/Makefile.am	(revision 7203)
@@ -55,4 +55,5 @@
 
 SUBDIRS = \
+	. \
 	math \
 	graphics \
@@ -65,4 +66,3 @@
 	parser \
 	shell \
-	gui \
-	.
+	gui
Index: branches/std/src/lib/event/key_mapper.cc
===================================================================
--- branches/std/src/lib/event/key_mapper.cc	(revision 7202)
+++ branches/std/src/lib/event/key_mapper.cc	(revision 7203)
@@ -129,5 +129,5 @@
  * @param filename: The path and name of the file to load the bindings from
 */
-void KeyMapper::loadKeyBindings (const char* fileName)
+void KeyMapper::loadKeyBindings (const std::string& fileName)
 {
   IniParser parser(fileName);
@@ -145,5 +145,5 @@
 
   iniParser->firstVar();
-  while(iniParser->getCurrentName())
+  while(iniParser->getCurrentName() != "")
   {
     PRINTF(3)("Keys: Parsing %s, %s now.\n", iniParser->getCurrentName(), iniParser->getCurrentValue());
@@ -164,5 +164,5 @@
 
   iniParser->firstVar();
-  while(iniParser->getCurrentName())
+  while(iniParser->getCurrentName() != "")
   {
     PRINTF(3)("MISC: Parsing %s, %s now.\n", iniParser->getCurrentName(), iniParser->getCurrentValue());
@@ -177,5 +177,5 @@
  * @param the name of the button
 */
-int* KeyMapper::nameToIndex (const char* name)
+int* KeyMapper::nameToIndex (const std::string& name)
 {
   coord[0] = -1;
@@ -199,9 +199,9 @@
  * @param id of the key
 */
-void KeyMapper::mapKeys(const char* name, int* index)
+void KeyMapper::mapKeys(const std::string& name, int* index)
 {
   for( int i = 0; map[i].pValue != NULL; ++i )
     {
-      if( !strcmp (name, map[i].pName))
+      if( name == map[i].pName)
       {
         if( index[0] == 0)
Index: branches/std/src/lib/event/key_mapper.h
===================================================================
--- branches/std/src/lib/event/key_mapper.h	(revision 7202)
+++ branches/std/src/lib/event/key_mapper.h	(revision 7203)
@@ -29,5 +29,5 @@
   virtual ~KeyMapper();
 
-  void loadKeyBindings(const char* fileName = NULL);
+  void loadKeyBindings(const std::string& fileName = NULL);
   void loadKeyBindings(IniParser* iniParser);
 
@@ -35,6 +35,6 @@
 
  private:
-  int* nameToIndex (const char* name);
-  void mapKeys(const char* name, int* index);
+  int* nameToIndex (const std::string& name);
+  void mapKeys(const std::string& name, int* index);
 
  public:
Index: branches/std/src/lib/event/key_names.cc
===================================================================
--- branches/std/src/lib/event/key_names.cc	(revision 7202)
+++ branches/std/src/lib/event/key_names.cc	(revision 7203)
@@ -23,11 +23,11 @@
 using namespace std;
 
-int buttonnameToSDLB(const char* name)
+int buttonnameToSDLB(const std::string& name)
 {
-        if( !strcmp (name, "BUTTON_LEFT")) return EV_MOUSE_BUTTON_LEFT;
-        if( !strcmp (name, "BUTTON_MIDDLE")) return EV_MOUSE_BUTTON_MIDDLE;
-        if( !strcmp (name, "BUTTON_RIGHT")) return EV_MOUSE_BUTTON_RIGHT;
-        if( !strcmp (name, "BUTTON_WHEELUP")) return EV_MOUSE_BUTTON_WHEELUP;
-        if( !strcmp (name, "BUTTON_WHEELDOWN")) return EV_MOUSE_BUTTON_WHEELDOWN;
+        if((name == "BUTTON_LEFT")) return EV_MOUSE_BUTTON_LEFT;
+        if((name == "BUTTON_MIDDLE")) return EV_MOUSE_BUTTON_MIDDLE;
+        if((name == "BUTTON_RIGHT")) return EV_MOUSE_BUTTON_RIGHT;
+        if((name == "BUTTON_WHEELUP")) return EV_MOUSE_BUTTON_WHEELUP;
+        if((name == "BUTTON_WHEELDOWN")) return EV_MOUSE_BUTTON_WHEELDOWN;
         return -1;
 }
@@ -43,143 +43,143 @@
 }
 
-int keynameToSDLK(const char* name)
+int keynameToSDLK(const std::string& name)
 {
-        if( !strcmp (name, "BACKSPACE")) return SDLK_BACKSPACE;
-        if( !strcmp (name, "TAB")) return SDLK_TAB;
-        if( !strcmp (name, "CLEAR")) return SDLK_CLEAR;
-        if( !strcmp (name, "RETURN")) return SDLK_RETURN;
-        if( !strcmp (name, "ESCAPE")) return SDLK_ESCAPE;
-        if( !strcmp (name, "SPACE")) return SDLK_SPACE;
-        if( !strcmp (name, "EXCLAIM")) return SDLK_EXCLAIM;
-        if( !strcmp (name, "QUOTEDBL")) return SDLK_QUOTEDBL;
-        if( !strcmp (name, "HASH")) return SDLK_HASH;
-        if( !strcmp (name, "PAUSE")) return SDLK_PAUSE;
-        if( !strcmp (name, "DOLLAR")) return SDLK_DOLLAR;
-        if( !strcmp (name, "AMPERSAND")) return SDLK_AMPERSAND;
-        if( !strcmp (name, "QUOTE")) return SDLK_QUOTE;
-        if( !strcmp (name, "LEFTPAREN")) return SDLK_LEFTPAREN;
-        if( !strcmp (name, "RIGHTPAREN")) return SDLK_RIGHTPAREN;
-        if( !strcmp (name, "ASTERISK")) return SDLK_ASTERISK;
-        if( !strcmp (name, "PLUS")) return SDLK_PLUS;
-        if( !strcmp (name, "COMMA")) return SDLK_COMMA;
-        if( !strcmp (name, "MINUS")) return SDLK_MINUS;
-        if( !strcmp (name, "PERIOD")) return SDLK_PERIOD;
-        if( !strcmp (name, "SLASH")) return SDLK_SLASH;
-        if( !strcmp (name, "0")) return SDLK_0;
-        if( !strcmp (name, "1")) return SDLK_1;
-        if( !strcmp (name, "2")) return SDLK_2;
-        if( !strcmp (name, "3")) return SDLK_3;
-        if( !strcmp (name, "4")) return SDLK_4;
-        if( !strcmp (name, "5")) return SDLK_5;
-        if( !strcmp (name, "6")) return SDLK_6;
-        if( !strcmp (name, "7")) return SDLK_7;
-        if( !strcmp (name, "8")) return SDLK_8;
-        if( !strcmp (name, "9")) return SDLK_9;
-        if( !strcmp (name, "COLON")) return SDLK_COLON;
-        if( !strcmp (name, "SEMICOLON")) return SDLK_SEMICOLON;
-        if( !strcmp (name, "LESS")) return SDLK_LESS;
-        if( !strcmp (name, "EQUALS")) return SDLK_EQUALS;
-        if( !strcmp (name, "GREATER")) return SDLK_GREATER;
-        if( !strcmp (name, "QUESTION")) return SDLK_QUESTION;
-        if( !strcmp (name, "AT")) return SDLK_AT;
-        if( !strcmp (name, "LEFTBRACKET")) return SDLK_LEFTBRACKET;
-        if( !strcmp (name, "BACKSLASH")) return SDLK_BACKSLASH;
-        if( !strcmp (name, "RIGHTBRACKET")) return SDLK_RIGHTBRACKET;
-        if( !strcmp (name, "CARET")) return SDLK_CARET;
-        if( !strcmp (name, "UNDERSCORE")) return SDLK_UNDERSCORE;
-        if( !strcmp (name, "BACKQUOTE")) return SDLK_BACKQUOTE;
-        if( !strcmp (name, "a")) return SDLK_a;
-        if( !strcmp (name, "b")) return SDLK_b;
-        if( !strcmp (name, "c")) return SDLK_c;
-        if( !strcmp (name, "d")) return SDLK_d;
-        if( !strcmp (name, "e")) return SDLK_e;
-        if( !strcmp (name, "f")) return SDLK_f;
-        if( !strcmp (name, "g")) return SDLK_g;
-        if( !strcmp (name, "h")) return SDLK_h;
-        if( !strcmp (name, "i")) return SDLK_i;
-        if( !strcmp (name, "j")) return SDLK_j;
-        if( !strcmp (name, "k")) return SDLK_k;
-        if( !strcmp (name, "l")) return SDLK_l;
-        if( !strcmp (name, "m")) return SDLK_m;
-        if( !strcmp (name, "n")) return SDLK_n;
-        if( !strcmp (name, "o")) return SDLK_o;
-        if( !strcmp (name, "p")) return SDLK_p;
-        if( !strcmp (name, "q")) return SDLK_q;
-        if( !strcmp (name, "r")) return SDLK_r;
-        if( !strcmp (name, "s")) return SDLK_s;
-        if( !strcmp (name, "t")) return SDLK_t;
-        if( !strcmp (name, "u")) return SDLK_u;
-        if( !strcmp (name, "v")) return SDLK_v;
-        if( !strcmp (name, "w")) return SDLK_w;
-        if( !strcmp (name, "x")) return SDLK_x;
-        if( !strcmp (name, "y")) return SDLK_y;
-        if( !strcmp (name, "z")) return SDLK_z;
-        if( !strcmp (name, "DELETE")) return SDLK_DELETE;
-        if( !strcmp (name, "KP0")) return SDLK_KP0;
-        if( !strcmp (name, "KP1")) return SDLK_KP1;
-        if( !strcmp (name, "KP2")) return SDLK_KP2;
-        if( !strcmp (name, "KP3")) return SDLK_KP3;
-        if( !strcmp (name, "KP4")) return SDLK_KP4;
-        if( !strcmp (name, "KP5")) return SDLK_KP5;
-        if( !strcmp (name, "KP6")) return SDLK_KP6;
-        if( !strcmp (name, "KP7")) return SDLK_KP7;
-        if( !strcmp (name, "KP8")) return SDLK_KP8;
-        if( !strcmp (name, "KP9")) return SDLK_KP9;
-        if( !strcmp (name, "KP_PERIOD")) return SDLK_KP_PERIOD;
-        if( !strcmp (name, "KP_DIVIDE")) return SDLK_KP_DIVIDE;
-        if( !strcmp (name, "KP_MULTIPLY")) return SDLK_KP_MULTIPLY;
-        if( !strcmp (name, "KP_MINUS")) return SDLK_KP_MINUS;
-        if( !strcmp (name, "KP_PLUS")) return SDLK_KP_PLUS;
-        if( !strcmp (name, "KP_ENTER")) return SDLK_KP_ENTER;
-        if( !strcmp (name, "KP_EQUALS")) return SDLK_KP_EQUALS;
-        if( !strcmp (name, "UP")) return SDLK_UP;
-        if( !strcmp (name, "DOWN")) return SDLK_DOWN;
-        if( !strcmp (name, "RIGHT")) return SDLK_RIGHT;
-        if( !strcmp (name, "LEFT")) return SDLK_LEFT;
-        if( !strcmp (name, "INSERT")) return SDLK_INSERT;
-        if( !strcmp (name, "HOME")) return SDLK_HOME;
-        if( !strcmp (name, "END")) return SDLK_END;
-        if( !strcmp (name, "PAGEUP")) return SDLK_PAGEUP;
-        if( !strcmp (name, "PAGEDOWN")) return SDLK_PAGEDOWN;
-        if( !strcmp (name, "F1")) return SDLK_F1;
-        if( !strcmp (name, "F2")) return SDLK_F2;
-        if( !strcmp (name, "F3")) return SDLK_F3;
-        if( !strcmp (name, "F4")) return SDLK_F4;
-        if( !strcmp (name, "F5")) return SDLK_F5;
-        if( !strcmp (name, "F6")) return SDLK_F6;
-        if( !strcmp (name, "F7")) return SDLK_F7;
-        if( !strcmp (name, "F8")) return SDLK_F8;
-        if( !strcmp (name, "F9")) return SDLK_F9;
-        if( !strcmp (name, "F10")) return SDLK_F10;
-        if( !strcmp (name, "F11")) return SDLK_F11;
-        if( !strcmp (name, "F12")) return SDLK_F12;
-        if( !strcmp (name, "F13")) return SDLK_F13;
-        if( !strcmp (name, "F14")) return SDLK_F14;
-        if( !strcmp (name, "F15")) return SDLK_F15;
-        if( !strcmp (name, "NUMLOCK")) return SDLK_NUMLOCK;
-        if( !strcmp (name, "CAPSLOCK")) return SDLK_CAPSLOCK;
-        if( !strcmp (name, "SCROLLOCK")) return SDLK_SCROLLOCK;
-        if( !strcmp (name, "RSHIFT")) return SDLK_RSHIFT;
-        if( !strcmp (name, "LSHIFT")) return SDLK_LSHIFT;
-        if( !strcmp (name, "RCTRL")) return SDLK_RCTRL;
-        if( !strcmp (name, "LCTRL")) return SDLK_LCTRL;
-        if( !strcmp (name, "RALT")) return SDLK_RALT;
-        if( !strcmp (name, "LALT")) return SDLK_LALT;
-        if( !strcmp (name, "RMETA")) return SDLK_RMETA;
-        if( !strcmp (name, "LMETA")) return SDLK_LMETA;
-        if( !strcmp (name, "LSUPER")) return SDLK_LSUPER;
-        if( !strcmp (name, "RSUPER")) return SDLK_RSUPER;
-        if( !strcmp (name, "MODE")) return SDLK_MODE;
-        if( !strcmp (name, "HELP")) return SDLK_HELP;
-        if( !strcmp (name, "PRINT")) return SDLK_PRINT;
-        if( !strcmp (name, "SYSREQ")) return SDLK_SYSREQ;
-        if( !strcmp (name, "BREAK")) return SDLK_BREAK;
-        if( !strcmp (name, "MENU")) return SDLK_MENU;
-        if( !strcmp (name, "POWER")) return SDLK_POWER;
-        if( !strcmp (name, "EURO")) return SDLK_EURO;
+        if((name == "BACKSPACE")) return SDLK_BACKSPACE;
+        if((name == "TAB")) return SDLK_TAB;
+        if((name == "CLEAR")) return SDLK_CLEAR;
+        if((name == "RETURN")) return SDLK_RETURN;
+        if((name == "ESCAPE")) return SDLK_ESCAPE;
+        if((name == "SPACE")) return SDLK_SPACE;
+        if((name == "EXCLAIM")) return SDLK_EXCLAIM;
+        if((name == "QUOTEDBL")) return SDLK_QUOTEDBL;
+        if((name == "HASH")) return SDLK_HASH;
+        if((name == "PAUSE")) return SDLK_PAUSE;
+        if((name == "DOLLAR")) return SDLK_DOLLAR;
+        if((name == "AMPERSAND")) return SDLK_AMPERSAND;
+        if((name == "QUOTE")) return SDLK_QUOTE;
+        if((name == "LEFTPAREN")) return SDLK_LEFTPAREN;
+        if((name == "RIGHTPAREN")) return SDLK_RIGHTPAREN;
+        if((name == "ASTERISK")) return SDLK_ASTERISK;
+        if((name == "PLUS")) return SDLK_PLUS;
+        if((name == "COMMA")) return SDLK_COMMA;
+        if((name == "MINUS")) return SDLK_MINUS;
+        if((name == "PERIOD")) return SDLK_PERIOD;
+        if((name == "SLASH")) return SDLK_SLASH;
+        if((name == "0")) return SDLK_0;
+        if((name == "1")) return SDLK_1;
+        if((name == "2")) return SDLK_2;
+        if((name == "3")) return SDLK_3;
+        if((name == "4")) return SDLK_4;
+        if((name == "5")) return SDLK_5;
+        if((name == "6")) return SDLK_6;
+        if((name == "7")) return SDLK_7;
+        if((name == "8")) return SDLK_8;
+        if((name == "9")) return SDLK_9;
+        if((name == "COLON")) return SDLK_COLON;
+        if((name == "SEMICOLON")) return SDLK_SEMICOLON;
+        if((name == "LESS")) return SDLK_LESS;
+        if((name == "EQUALS")) return SDLK_EQUALS;
+        if((name == "GREATER")) return SDLK_GREATER;
+        if((name == "QUESTION")) return SDLK_QUESTION;
+        if((name == "AT")) return SDLK_AT;
+        if((name == "LEFTBRACKET")) return SDLK_LEFTBRACKET;
+        if((name == "BACKSLASH")) return SDLK_BACKSLASH;
+        if((name == "RIGHTBRACKET")) return SDLK_RIGHTBRACKET;
+        if((name == "CARET")) return SDLK_CARET;
+        if((name == "UNDERSCORE")) return SDLK_UNDERSCORE;
+        if((name == "BACKQUOTE")) return SDLK_BACKQUOTE;
+        if((name == "a")) return SDLK_a;
+        if((name == "b")) return SDLK_b;
+        if((name == "c")) return SDLK_c;
+        if((name == "d")) return SDLK_d;
+        if((name == "e")) return SDLK_e;
+        if((name == "f")) return SDLK_f;
+        if((name == "g")) return SDLK_g;
+        if((name == "h")) return SDLK_h;
+        if((name == "i")) return SDLK_i;
+        if((name == "j")) return SDLK_j;
+        if((name == "k")) return SDLK_k;
+        if((name == "l")) return SDLK_l;
+        if((name == "m")) return SDLK_m;
+        if((name == "n")) return SDLK_n;
+        if((name == "o")) return SDLK_o;
+        if((name == "p")) return SDLK_p;
+        if((name == "q")) return SDLK_q;
+        if((name == "r")) return SDLK_r;
+        if((name == "s")) return SDLK_s;
+        if((name == "t")) return SDLK_t;
+        if((name == "u")) return SDLK_u;
+        if((name == "v")) return SDLK_v;
+        if((name == "w")) return SDLK_w;
+        if((name == "x")) return SDLK_x;
+        if((name == "y")) return SDLK_y;
+        if((name == "z")) return SDLK_z;
+        if((name == "DELETE")) return SDLK_DELETE;
+        if((name == "KP0")) return SDLK_KP0;
+        if((name == "KP1")) return SDLK_KP1;
+        if((name == "KP2")) return SDLK_KP2;
+        if((name == "KP3")) return SDLK_KP3;
+        if((name == "KP4")) return SDLK_KP4;
+        if((name == "KP5")) return SDLK_KP5;
+        if((name == "KP6")) return SDLK_KP6;
+        if((name == "KP7")) return SDLK_KP7;
+        if((name == "KP8")) return SDLK_KP8;
+        if((name == "KP9")) return SDLK_KP9;
+        if((name == "KP_PERIOD")) return SDLK_KP_PERIOD;
+        if((name == "KP_DIVIDE")) return SDLK_KP_DIVIDE;
+        if((name == "KP_MULTIPLY")) return SDLK_KP_MULTIPLY;
+        if((name == "KP_MINUS")) return SDLK_KP_MINUS;
+        if((name == "KP_PLUS")) return SDLK_KP_PLUS;
+        if((name == "KP_ENTER")) return SDLK_KP_ENTER;
+        if((name == "KP_EQUALS")) return SDLK_KP_EQUALS;
+        if((name == "UP")) return SDLK_UP;
+        if((name == "DOWN")) return SDLK_DOWN;
+        if((name == "RIGHT")) return SDLK_RIGHT;
+        if((name == "LEFT")) return SDLK_LEFT;
+        if((name == "INSERT")) return SDLK_INSERT;
+        if((name == "HOME")) return SDLK_HOME;
+        if((name == "END")) return SDLK_END;
+        if((name == "PAGEUP")) return SDLK_PAGEUP;
+        if((name == "PAGEDOWN")) return SDLK_PAGEDOWN;
+        if((name == "F1")) return SDLK_F1;
+        if((name == "F2")) return SDLK_F2;
+        if((name == "F3")) return SDLK_F3;
+        if((name == "F4")) return SDLK_F4;
+        if((name == "F5")) return SDLK_F5;
+        if((name == "F6")) return SDLK_F6;
+        if((name == "F7")) return SDLK_F7;
+        if((name == "F8")) return SDLK_F8;
+        if((name == "F9")) return SDLK_F9;
+        if((name == "F10")) return SDLK_F10;
+        if((name == "F11")) return SDLK_F11;
+        if((name == "F12")) return SDLK_F12;
+        if((name == "F13")) return SDLK_F13;
+        if((name == "F14")) return SDLK_F14;
+        if((name == "F15")) return SDLK_F15;
+        if((name == "NUMLOCK")) return SDLK_NUMLOCK;
+        if((name == "CAPSLOCK")) return SDLK_CAPSLOCK;
+        if((name == "SCROLLOCK")) return SDLK_SCROLLOCK;
+        if((name == "RSHIFT")) return SDLK_RSHIFT;
+        if((name == "LSHIFT")) return SDLK_LSHIFT;
+        if((name == "RCTRL")) return SDLK_RCTRL;
+        if((name == "LCTRL")) return SDLK_LCTRL;
+        if((name == "RALT")) return SDLK_RALT;
+        if((name == "LALT")) return SDLK_LALT;
+        if((name == "RMETA")) return SDLK_RMETA;
+        if((name == "LMETA")) return SDLK_LMETA;
+        if((name == "LSUPER")) return SDLK_LSUPER;
+        if((name == "RSUPER")) return SDLK_RSUPER;
+        if((name == "MODE")) return SDLK_MODE;
+        if((name == "HELP")) return SDLK_HELP;
+        if((name == "PRINT")) return SDLK_PRINT;
+        if((name == "SYSREQ")) return SDLK_SYSREQ;
+        if((name == "BREAK")) return SDLK_BREAK;
+        if((name == "MENU")) return SDLK_MENU;
+        if((name == "POWER")) return SDLK_POWER;
+        if((name == "EURO")) return SDLK_EURO;
         return -1;
 }
 
-const char* SDLKToKeyname( int key)
+const char* SDLKToKeyname(int key)
 {
         if( key == SDLK_BACKSPACE) return "BACKSPACE";
Index: branches/std/src/lib/event/key_names.h
===================================================================
--- branches/std/src/lib/event/key_names.h	(revision 7202)
+++ branches/std/src/lib/event/key_names.h	(revision 7203)
@@ -1,37 +1,39 @@
 /*!
  * @file keynames.h
-  *  Key/button naming functions
-
-                Converts strings to SDLK/SDL_BUTTON values and vice versa
-*/
+ *  Key/button naming functions
+ *
+ * Converts strings to SDLK/SDL_BUTTON values and vice versa
+ */
 #ifndef _KEY_NAMES_H
 #define _KEY_NAMES_H
 
-/**
-      *  converts a button name string to a integer representing the corresponding SDL mouse button identifier
-      * @param name: the name of the mouse button
-      * @return an int containing the SDL identifier of the mouse button or -1 if the button name is not valid
-*/
-int buttonnameToSDLB(const char* name);
+#include <string>
 
 /**
-      *  converst a SDL mouse button identifier to a name string
-      * @param button: an SDL mouse button identifier
-      * @return a pointer to a string containing the name of the mouse button
-*/
+ *  converts a button name string to a integer representing the corresponding SDL mouse button identifier
+ * @param name: the name of the mouse button
+ * @return an int containing the SDL identifier of the mouse button or -1 if the button name is not valid
+ */
+int buttonnameToSDLB(const std::string& name);
+
+/**
+ *  converst a SDL mouse button identifier to a name string
+ * @param button: an SDL mouse button identifier
+ * @return a pointer to a string containing the name of the mouse button
+ */
 const char* SDLBToButtonname( int button);
 
 /**
-      *  converts a key name string to a integer representing the corresponding SDLK sym
-      * @param name: the name of the key
-      * @return the SDLK sym of the named key or -1 if the key name is not valid
-*/
-int keynameToSDLK(const char* name);
+ *  converts a key name string to a integer representing the corresponding SDLK sym
+ * @param name: the name of the key
+ * @return the SDLK sym of the named key or -1 if the key name is not valid
+ */
+int keynameToSDLK(const std::string& name);
 
 /**
-      *  converts an SDLK sym to a name string
-      * @param key: the SDLK sym
-      * @return a pointer to a string containig the name of the key
-*/
+ *  converts an SDLK sym to a name string
+ * @param key: the SDLK sym
+ * @return a pointer to a string containig the name of the key
+ */
 const char* SDLKToKeyname( int key);
 
Index: branches/std/src/lib/graphics/graphics_engine.cc
===================================================================
--- branches/std/src/lib/graphics/graphics_engine.cc	(revision 7202)
+++ branches/std/src/lib/graphics/graphics_engine.cc	(revision 7203)
@@ -169,11 +169,11 @@
 {
   // looking if we are in fullscreen-mode
-  const char* fullscreen = iniParser->getVar(CONFIG_NAME_FULLSCREEN, CONFIG_SECTION_VIDEO, "0");
-  if (strchr(fullscreen, '1') || !strcasecmp(fullscreen, "true"))
+  const std::string fullscreen = iniParser->getVar(CONFIG_NAME_FULLSCREEN, CONFIG_SECTION_VIDEO, "0");
+  if (fullscreen[0] == '1' || fullscreen == "true")
     this->fullscreenFlag = SDL_FULLSCREEN;
 
   // looking if we are in fullscreen-mode
-  const char* textures = iniParser->getVar(CONFIG_NAME_TEXTURES, CONFIG_SECTION_VIDEO_ADVANCED, "0");
-  if (strchr(textures, '1') || !strcasecmp(textures, "true"))
+  const std::string textures = iniParser->getVar(CONFIG_NAME_TEXTURES, CONFIG_SECTION_VIDEO_ADVANCED, "0");
+  if (textures[0] == '1' || textures == "true")
     Texture::setTextureEnableState( true);
   else
@@ -181,5 +181,5 @@
 
   // searching for a usefull resolution
-  SubString resolution(iniParser->getVar(CONFIG_NAME_RESOLUTION, CONFIG_SECTION_VIDEO, "640x480"), 'x');
+  SubString resolution(iniParser->getVar(CONFIG_NAME_RESOLUTION, CONFIG_SECTION_VIDEO, "640x480").c_str(), 'x'); ///FIXME
   //resolution.debug();
 
@@ -262,16 +262,16 @@
  * @param icon The name of the Icon on the Disc
  */
-void GraphicsEngine::setWindowName(const char* windowName, const char* icon)
-{
-  SDL_Surface* iconSurf = SDL_LoadBMP(icon);
+void GraphicsEngine::setWindowName(const std::string& windowName, const std::string& icon)
+{
+  SDL_Surface* iconSurf = SDL_LoadBMP(icon.c_str());
   if (iconSurf != NULL)
   {
     Uint32 colorkey = SDL_MapRGB(iconSurf->format, 0, 0, 0);
     SDL_SetColorKey(iconSurf, SDL_SRCCOLORKEY, colorkey);
-    SDL_WM_SetIcon(iconSurf,NULL);
+    SDL_WM_SetIcon(iconSurf, NULL);
     SDL_FreeSurface(iconSurf);
   }
 
-  SDL_WM_SetCaption (windowName, icon);
+  SDL_WM_SetCaption (windowName.c_str(), icon.c_str());
 }
 
Index: branches/std/src/lib/graphics/graphics_engine.h
===================================================================
--- branches/std/src/lib/graphics/graphics_engine.h	(revision 7202)
+++ branches/std/src/lib/graphics/graphics_engine.h	(revision 7203)
@@ -41,5 +41,5 @@
     int initFromIniFile(IniParser* iniParser);
 
-    void setWindowName(const char* windowName, const char* icon);
+    void setWindowName(const std::string& windowName, const std::string& icon);
 
     int setResolution(int width, int height, int bpp);
Index: branches/std/src/lib/graphics/importer/height_map.cc
===================================================================
--- branches/std/src/lib/graphics/importer/height_map.cc	(revision 7202)
+++ branches/std/src/lib/graphics/importer/height_map.cc	(revision 7203)
@@ -333,11 +333,12 @@
 }
 
-HeightMap::HeightMap(const char* height_map_name = NULL) : VertexArrayModel()
+HeightMap::HeightMap(const std::string& height_map_name = "")
+  : VertexArrayModel()
 {
    this->setClassID(CL_HEIGHT_MAP, "HeightMap");
-   heightMap =  IMG_Load(height_map_name);
+   heightMap =  IMG_Load(height_map_name.c_str());
    if(heightMap!=NULL) {
 
-                 PRINTF(0)("loading Image %s\n", height_map_name);
+     PRINTF(0)("loading Image %s\n", height_map_name.c_str());
                  PRINTF(0)("width : %i\n", heightMap->w);
                  PRINTF(0)("height : %i\n", heightMap->h);
@@ -350,5 +351,5 @@
                 }
 
-     else       PRINTF(4)("oops! couldn't load %s for some reason.\n", height_map_name);
+                else       PRINTF(4)("oops! couldn't load %s for some reason.\n", height_map_name.c_str());
 
 
@@ -361,12 +362,13 @@
 }
 
-HeightMap::HeightMap(const char* height_map_name = NULL, const char* colour_map_name = NULL) : VertexArrayModel()
+HeightMap::HeightMap(const std::string& height_map_name = NULL, const std::string& colour_map_name = NULL)
+  : VertexArrayModel()
 {
 this->setClassID(CL_HEIGHT_MAP, "HeightMap");
 
-   heightMap =  IMG_Load(height_map_name);
+   heightMap =  IMG_Load(height_map_name.c_str());
    if(heightMap!=NULL) {
 
-                 PRINTF(0)("loading Image %s\n", height_map_name);
+     PRINTF(0)("loading Image %s\n", height_map_name.c_str());
                  PRINTF(0)("width : %i\n", heightMap->w);
                  PRINTF(0)("height : %i\n", heightMap->h);
@@ -379,5 +381,5 @@
                 }
 
-     else       PRINTF(4)("oops! couldn't load %s for some reason.\n", height_map_name);
+                else       PRINTF(4)("oops! couldn't load %s for some reason.\n", height_map_name.c_str());
 
 
@@ -385,12 +387,12 @@
 
   colourMap=NULL;
-  if(colour_map_name != NULL)
+  if(colour_map_name != "")
   {
-  colourMap = IMG_Load(colour_map_name);
+    colourMap = IMG_Load(colour_map_name.c_str());
   }
 
   if(colourMap != NULL)
                 {
-                 PRINTF(0)("loading Image %s\n", colour_map_name);
+                  PRINTF(0)("loading Image %s\n", colour_map_name.c_str());
                  PRINTF(0)("width : %i\n", colourMap->w);
                  PRINTF(0)("height : %i\n", colourMap->h);
Index: branches/std/src/lib/graphics/importer/height_map.h
===================================================================
--- branches/std/src/lib/graphics/importer/height_map.h	(revision 7202)
+++ branches/std/src/lib/graphics/importer/height_map.h	(revision 7203)
@@ -59,5 +59,5 @@
 void load();
 void load(int Mode);
-void load(const char*, int Mode);
+void load(const std::string&, int Mode);
 void scale( Vector V);
 void setAbsCoor(Vector V);
@@ -65,6 +65,6 @@
 float getNormal(float x, float y);
 HeightMap();
-HeightMap(const char*);
-HeightMap(const char*, const char*);
+HeightMap(const std::string&);
+HeightMap(const std::string&, const std::string&);
 virtual ~HeightMap();
 
Index: branches/std/src/lib/graphics/importer/material.cc
===================================================================
--- branches/std/src/lib/graphics/importer/material.cc	(revision 7202)
+++ branches/std/src/lib/graphics/importer/material.cc	(revision 7203)
@@ -34,5 +34,5 @@
  * @param mtlName Name of the Material to be added to the Material List
  */
-Material::Material (const char* mtlName)
+Material::Material (const std::string& mtlName)
 {
   this->setClassID(CL_MATERIAL, "Material");
@@ -278,5 +278,5 @@
  * @param pathName The Path to add.
 */
-void Material::addTexturePath(const char* pathName)
+void Material::addTexturePath(const std::string& pathName)
 {
   ResourceManager::getInstance()->addImageDir(pathName);
@@ -289,5 +289,5 @@
  * @param dMap the Name of the Image to Use
 */
-void Material::setDiffuseMap(const char* dMap, GLenum target)
+void Material::setDiffuseMap(const std::string& dMap, GLenum target)
 {
   PRINTF(5)("setting Diffuse Map %s\n", dMap);
@@ -297,5 +297,5 @@
   //! @todo check if RESOURCE MANAGER is availiable
   //! @todo Textures from .mtl-file need special care.
-  if (dMap != NULL)
+  if (!dMap.empty())
     this->diffuseTexture = (Texture*)ResourceManager::getInstance()->load(dMap, IMAGE, RP_GAME, (int)target);
   else
@@ -308,5 +308,5 @@
    @todo implement this
 */
-void Material::setAmbientMap(const char* aMap, GLenum target)
+void Material::setAmbientMap(const std::string& aMap, GLenum target)
 {
   SDL_Surface* ambientMap;
@@ -319,5 +319,5 @@
    @todo implement this
 */
-void Material::setSpecularMap(const char* sMap, GLenum target)
+void Material::setSpecularMap(const std::string& sMap, GLenum target)
 {
   SDL_Surface* specularMap;
@@ -330,6 +330,6 @@
    @todo implemet this
 */
-void Material::setBump(const char* bump)
-{
-
-}
+void Material::setBump(const std::string& bump)
+{
+
+}
Index: branches/std/src/lib/graphics/importer/material.h
===================================================================
--- branches/std/src/lib/graphics/importer/material.h	(revision 7202)
+++ branches/std/src/lib/graphics/importer/material.h	(revision 7203)
@@ -26,5 +26,5 @@
 {
  public:
-  Material (const char* mtlName = NULL);
+  Material (const std::string& mtlName = "");
   virtual ~Material ();
 
@@ -49,11 +49,11 @@
 
  // MAPPING //
-  void setDiffuseMap(const char* dMap, GLenum target = GL_TEXTURE_2D);
-  void setAmbientMap(const char* aMap, GLenum target = GL_TEXTURE_2D);
-  void setSpecularMap(const char* sMap, GLenum target = GL_TEXTURE_2D);
-  void setBump(const char* bump);
+  void setDiffuseMap(const std::string& dMap, GLenum target = GL_TEXTURE_2D);
+  void setAmbientMap(const std::string& aMap, GLenum target = GL_TEXTURE_2D);
+  void setSpecularMap(const std::string& sMap, GLenum target = GL_TEXTURE_2D);
+  void setBump(const std::string& bump);
   GLuint getDiffuseTexture() const { return (this->diffuseTexture)? this->diffuseTexture->getTexture() : 0; };
 
-  static void addTexturePath(const char* pathName);
+  static void addTexturePath(const std::string& pathName);
 
   private:
Index: branches/std/src/lib/graphics/importer/md2Model.cc
===================================================================
--- branches/std/src/lib/graphics/importer/md2Model.cc	(revision 7202)
+++ branches/std/src/lib/graphics/importer/md2Model.cc	(revision 7203)
@@ -75,5 +75,5 @@
   \brief simple constructor initializing all variables
 */
-MD2Model::MD2Model(const char* modelFileName, const char* skinFileName, float scale)
+MD2Model::MD2Model(const std::string& modelFileName, const std::string& skinFileName, float scale)
 {
   this->setClassID(CL_MD2_MODEL, "MD2Model");
@@ -352,6 +352,6 @@
 {
   PRINT(0)("\n==========================| MD2Model::debug() |===\n");
-  PRINT(0)("=  Model FileName:\t%s\n", this->data->fileName);
-  PRINT(0)("=  Skin FileName:\t%s\n", this->data->skinFileName);
+  PRINT(0)("=  Model FileName:\t%s\n", this->data->fileName.c_str());
+  PRINT(0)("=  Skin FileName:\t%s\n", this->data->skinFileName.c_str());
   PRINT(0)("=  Size in Memory:\t%i Bytes\n", this->data->header->frameSize * this->data->header->numFrames + 64); // 64bytes is the header size
   PRINT(0)("=  Number of Vertices:\t%i\n", this->data->header->numVertices);
@@ -370,5 +370,5 @@
   \brief simple constructor
 */
-MD2Data::MD2Data(const char* modelFileName, const char* skinFileName, float scale)
+MD2Data::MD2Data(const std::string& modelFileName, const std::string& skinFileName, float scale)
 {
   scale *= 0.1f;
@@ -387,6 +387,6 @@
   this->scaleFactor = scale;
 
-  this->fileName = NULL;
-  this->skinFileName = NULL;
+  this->fileName = "";
+  this->skinFileName = "";
   this->loadModel(modelFileName);
   this->loadSkin(skinFileName);
@@ -401,6 +401,4 @@
 MD2Data::~MD2Data()
 {
-  delete [] this->fileName;
-  delete [] this->skinFileName;
   delete this->header;
 
@@ -419,5 +417,5 @@
   \return true if success
 */
-bool MD2Data::loadModel(const char* fileName)
+bool MD2Data::loadModel(const std::string& fileName)
 {
   FILE *pFile;                            //file stream
@@ -428,8 +426,8 @@
 
   //! @todo this chek should include deleting a loaded model (eventually)
-  if (fileName == NULL)
+  if (fileName.empty())
     return false;
 
-  pFile = fopen(fileName, "rb");
+  pFile = fopen(fileName.c_str(), "rb");
   if( unlikely(!pFile))
     {
@@ -442,10 +440,9 @@
   if( unlikely(this->header->version != MD2_VERSION) && unlikely(this->header->ident != MD2_IDENT))
     {
-      PRINTF(1)("Couldn't load file %s: invalid file format: stop loading\n", fileName);
+      PRINTF(1)("Couldn't load file %s: invalid file format: stop loading\n", fileName.c_str());
       return false;
     }
 
-  this->fileName = new char[strlen(fileName)+1];
-  strcpy(this->fileName, fileName);
+  this->fileName =fileName;
   /* got the data: map it to locals */
   this->numFrames = this->header->numFrames;
@@ -507,14 +504,13 @@
   \return true if success
 */
-bool MD2Data::loadSkin(const char* fileName)
-{
-  if( fileName == NULL)
-    {
-      this->skinFileName = NULL;
+bool MD2Data::loadSkin(const std::string& fileName)
+{
+  if( fileName.empty())
+    {
+      this->skinFileName = "";
       return false;
     }
 
-  this->skinFileName = new char[strlen(fileName)+1];
-  strcpy(this->skinFileName, fileName);
+  this->skinFileName =fileName;
 
   this->material.setName("md2ModelMaterial");
Index: branches/std/src/lib/graphics/importer/md2Model.h
===================================================================
--- branches/std/src/lib/graphics/importer/md2Model.h	(revision 7202)
+++ branches/std/src/lib/graphics/importer/md2Model.h	(revision 7203)
@@ -189,10 +189,10 @@
 {
  public:
-   MD2Data(const char* modelFileName, const char* skinFileName, float scale = 1.0f);
+   MD2Data(const std::string& modelFileName, const std::string& skinFileName, float scale = 1.0f);
   virtual ~MD2Data();
 
  private:
-  bool loadModel(const char* fileName);
-  bool loadSkin(const char* fileName = NULL);
+   bool loadModel(const std::string& fileName);
+   bool loadSkin(const std::string& fileName = NULL);
 
  public:
@@ -202,6 +202,6 @@
   int                numTexCoor;            //!< number of texture coordinates
   int                numGLCommands;         //!< number of gl commands in the glList (tells how to draw)
-  char*              fileName;              //!< file name of the model File
-  char*              skinFileName;          //!< file name of the skin file
+  std::string        fileName;              //!< file name of the model File
+  std::string        skinFileName;          //!< file name of the skin file
   MD2Header*         header;                //!< the header file
 
@@ -223,5 +223,5 @@
 
 public:
-  MD2Model(const char* modelFileName, const char* skinFileName = NULL, float scale = 1.0f);
+  MD2Model(const std::string& modelFileName, const std::string& skinFileName = NULL, float scale = 1.0f);
   virtual ~MD2Model();
 
Index: branches/std/src/lib/graphics/importer/media_container.cc
===================================================================
--- branches/std/src/lib/graphics/importer/media_container.cc	(revision 7202)
+++ branches/std/src/lib/graphics/importer/media_container.cc	(revision 7203)
@@ -101,7 +101,7 @@
 
   // Open video file
-  if (av_open_input_file(&format_context, ResourceManager::getFullName(filename), NULL, 0, NULL) !=0 )
-  {
-    PRINTF(1)("Could not open %s\n", ResourceManager::getFullName(filename));
+  if (av_open_input_file(&format_context, ResourceManager::getFullName(filename).c_str(), NULL, 0, NULL) !=0 )
+  {
+    PRINTF(1)("Could not open %s\n", ResourceManager::getFullName(filename).c_str());
     return false;
   }
@@ -110,5 +110,5 @@
   if (av_find_stream_info(format_context) < 0)
   {
-    PRINTF(1)("Could not find stream information in %s\n", ResourceManager::getFullName(filename));
+    PRINTF(1)("Could not find stream information in %s\n", ResourceManager::getFullName(filename).c_str());
     return false;
   }
@@ -116,8 +116,8 @@
   // Find the first video stream and take it
   video_stream = av_find_default_stream_index(format_context);
-  
+
   if(video_stream == -1)
   {
-    PRINTF(1)("Could not find a video stream in %s\n", ResourceManager::getFullName(filename));
+    PRINTF(1)("Could not find a video stream in %s\n", ResourceManager::getFullName(filename).c_str());
     return false;
   }
@@ -202,5 +202,5 @@
       // Free the packet that was allocated by av_read_frame
       av_free_packet(&packet);
-      
+
       // Did we get a video frame?
       if(frame_finished)
@@ -216,5 +216,5 @@
           memcpy(&data[i*codec_context->width*3],
                  ((AVPicture*)RGB_frame)->data[0]+i *
-                 ((AVPicture*)RGB_frame)->linesize[0], 
+                 ((AVPicture*)RGB_frame)->linesize[0],
                   codec_context->width*sizeof(uint8_t)*3);
 
@@ -258,4 +258,4 @@
   }
   else
-    return NULL;
-}
+    return 0;
+}
Index: branches/std/src/lib/graphics/importer/movie_player.cc
===================================================================
--- branches/std/src/lib/graphics/importer/movie_player.cc	(revision 7202)
+++ branches/std/src/lib/graphics/importer/movie_player.cc	(revision 7203)
@@ -31,5 +31,5 @@
 
 
-MoviePlayer::MoviePlayer(const char* filename)
+MoviePlayer::MoviePlayer(const std::string& filename)
 {
   // set the class id for the base object
@@ -83,14 +83,14 @@
 
 
-bool MoviePlayer::loadMovie(const char* filename)
+bool MoviePlayer::loadMovie(const std::string& filename)
 {
   this->unloadMedia();
 
-  if(filename == NULL)
+  if(filename.empty())
     return false;
   // check whether file exists
   if(!ResourceManager::isInDataDir(filename))
   {
-    PRINTF(1)("Could not find %s\n", filename);
+    PRINTF(1)("Could not find %s\n", filename.c_str());
     return false;
   }
@@ -100,7 +100,7 @@
 
   // Open video file
-  if (av_open_input_file(&format_context, ResourceManager::getFullName(filename), NULL, 0, NULL) !=0 )
-  {
-    PRINTF(1)("Could not open %s\n", ResourceManager::getFullName(filename));
+  if (av_open_input_file(&format_context, ResourceManager::getFullName(filename).c_str(), NULL, 0, NULL) !=0 )
+  {
+    PRINTF(1)("Could not open %s\n", ResourceManager::getFullName(filename).c_str());
     return false;
   }
@@ -109,5 +109,5 @@
   if (av_find_stream_info(format_context) < 0)
   {
-    PRINTF(1)("Could not find stream information in %s\n", ResourceManager::getFullName(filename));
+    PRINTF(1)("Could not find stream information in %s\n", ResourceManager::getFullName(filename).c_str());
     return false;
   }
@@ -118,5 +118,5 @@
   if(video_stream == -1)
   {
-    PRINTF(1)("Could not find a video stream in %s\n", ResourceManager::getFullName(filename));
+    PRINTF(1)("Could not find a video stream in %s\n", ResourceManager::getFullName(filename).c_str());
     return false;
   }
Index: branches/std/src/lib/graphics/importer/movie_player.h
===================================================================
--- branches/std/src/lib/graphics/importer/movie_player.h	(revision 7202)
+++ branches/std/src/lib/graphics/importer/movie_player.h	(revision 7203)
@@ -58,8 +58,8 @@
 public:
 
-  MoviePlayer(const char* filename = NULL);
+  MoviePlayer(const std::string& filename = NULL);
   virtual ~MoviePlayer();
 
-  bool loadMovie(const char* filename);
+  bool loadMovie(const std::string& filename);
 
   void start(float start_time);
Index: branches/std/src/lib/graphics/importer/objModel.cc
===================================================================
--- branches/std/src/lib/graphics/importer/objModel.cc	(revision 7202)
+++ branches/std/src/lib/graphics/importer/objModel.cc	(revision 7203)
@@ -32,5 +32,6 @@
  * @param scaling The factor that the model will be scaled with.
 */
-OBJModel::OBJModel(const char* fileName, float scaling) : StaticModel(fileName)
+OBJModel::OBJModel(const std::string& fileName, float scaling)
+  : StaticModel(fileName)
 {
   this->setClassID(CL_OBJ_MODEL, "OBJModel");
@@ -51,9 +52,5 @@
 */
 OBJModel::~OBJModel()
-{
-  PRINTF(4)("Deleting the obj-names\n");
-  if (this->objPath)
-    delete []this->objPath;
-}
+{ }
 
 /**
@@ -63,6 +60,7 @@
    Splits the FileName from the DirectoryName
 */
-bool OBJModel::importFile (const char* fileName)
-{
+bool OBJModel::importFile (const std::string& fileNameInput)
+{
+  const char* fileName = fileNameInput.c_str();
   PRINTF(4)("preparing to read in file: %s\n", fileName);
   // splitting the
@@ -74,6 +72,6 @@
     {
       int len = split - fileName+1;
-      this->objPath = new char[len +2];
-      strncpy(this->objPath, fileName, len);
+      this->objPath =  fileName;
+      this->objPath.erase(len, this->objPath.size());
       this->objPath[len] = '\0';
       PRINTF(4)("Resolved file %s to Path %s.\n", fileName, this->objPath);
@@ -91,10 +89,10 @@
    This function does read the file, parses it for the occurence of things like vertices, faces and so on, and executes the specific tasks
 */
-bool OBJModel::readFromObjFile(const char* fileName)
+bool OBJModel::readFromObjFile(const std::string& fileName)
 {
   FILE* stream;
-  if( (stream = fopen (fileName, "r")) == NULL)
-    {
-      PRINTF(2)("Object File Could not be Opened %s\n", fileName);
+  if( (stream = fopen (fileName.c_str(), "r")) == NULL)
+    {
+      PRINTF(2)("Object File Could not be Opened %s\n", fileName.c_str());
       return false;
     }
@@ -162,14 +160,12 @@
  * that a material does not have to be able to read itself in from a File.
  */
-bool OBJModel::readMtlLib (const char* mtlFile)
-{
-  char* fileName = new char [strlen(this->objPath) + strlen(mtlFile)+1];
-  sprintf(fileName, "%s%s", this->objPath, mtlFile);
+bool OBJModel::readMtlLib (const std::string& mtlFile)
+{
+  std::string fileName = this->objPath + mtlFile;
 
   FILE* stream;
-  if( (stream = fopen (fileName, "r")) == NULL)
-    {
-      PRINTF(2)("MaterialLibrary could not be opened %s\n", fileName);
-      delete[] fileName;
+  if( (stream = fopen (fileName.c_str(), "r")) == NULL)
+    {
+      PRINTF(2)("MaterialLibrary could not be opened %s\n", fileName.c_str());
       return false;
     }
@@ -258,5 +254,4 @@
     }
   fclose(stream);
-  delete []fileName;
   return true;
 }
Index: branches/std/src/lib/graphics/importer/objModel.h
===================================================================
--- branches/std/src/lib/graphics/importer/objModel.h	(revision 7202)
+++ branches/std/src/lib/graphics/importer/objModel.h	(revision 7203)
@@ -13,15 +13,15 @@
 {
  public:
-  OBJModel(const char* fileName, float scaling = 1.0);
+   OBJModel(const std::string& fileName, float scaling = 1.0);
   virtual ~OBJModel();
 
  private:
   ///// readin /////
-  bool importFile (const char* fileName);
-  bool readFromObjFile (const char* fileName);
-  bool readMtlLib (const char* matFile);
+   bool importFile (const std::string& fileName);
+   bool readFromObjFile (const std::string& fileName);
+   bool readMtlLib (const std::string& matFile);
 
  private:
-  char*       objPath;     //!< The Path where the obj and mtl-file are located.
+   std::string       objPath;     //!< The Path where the obj and mtl-file are located.
 };
 
Index: branches/std/src/lib/graphics/importer/static_model.cc
===================================================================
--- branches/std/src/lib/graphics/importer/static_model.cc	(revision 7202)
+++ branches/std/src/lib/graphics/importer/static_model.cc	(revision 7203)
@@ -23,6 +23,4 @@
 #include <stdarg.h>
 
-#include "vector.h"
-
 using namespace std;
 
@@ -86,5 +84,5 @@
 {
   PRINTF(4)("Adding new Group\n");
-  this->name = NULL;
+  this->name = "";
   this->faceMode = -1;
   this->faceCount = 0;
@@ -109,7 +107,4 @@
   if (this->listNumber != 0)
     glDeleteLists(this->listNumber, 1);
-
-  if (this->name != NULL)
-    delete[] this->name;
 
   if (this->next !=NULL)
@@ -142,5 +137,5 @@
  * assigns it a Name and a Type
  */
-StaticModel::StaticModel(const char* modelName)
+StaticModel::StaticModel(const std::string& modelName)
 {
   this->setClassID(CL_STATIC_MODEL, "StaticModel");
@@ -276,15 +271,13 @@
  * It does this by just calling the List that must have been created earlier.
  */
-void StaticModel::draw (char* groupName) const
-{
-  if (groupName == NULL)
-     return;
+void StaticModel::draw (const std::string& groupName) const
+{
   PRINTF(4)("drawing the requested 3D-Models if found.\n");
   ModelGroup* tmpGroup = this->firstGroup;
   while (tmpGroup != NULL)
     {
-      if (tmpGroup->name != NULL && !strcmp(tmpGroup->name, groupName))
+      if (tmpGroup->name == groupName)
         {
-          PRINTF(4)("Drawing model %s\n", tmpGroup->name);
+          PRINTF(4)("Drawing model %s\n", tmpGroup->name.c_str());
           glCallList (tmpGroup->listNumber);
           return;
@@ -292,5 +285,5 @@
       tmpGroup = tmpGroup->next;
     }
-  PRINTF(2)("Model Named %s in %s not Found.\n", groupName, this->getName());
+    PRINTF(2)("Model Named %s in %s not Found.\n", groupName.c_str(), this->getName());
   return;
 }
@@ -341,5 +334,5 @@
  * @returns the added material
  */
-Material* StaticModel::addMaterial(const char* materialName)
+Material* StaticModel::addMaterial(const std::string& materialName)
 {
   ModelMaterial* modMat = new ModelMaterial;
@@ -357,9 +350,9 @@
  * @returns the Material if found, NULL otherwise
  */
-Material* StaticModel::findMaterialByName(const char* materialName)
+Material* StaticModel::findMaterialByName(const std::string& materialName)
 {
   list<ModelMaterial*>::iterator modMat;
   for  (modMat = this->materialList.begin(); modMat != this->materialList.end(); modMat++)
-    if (!strcmp((*modMat)->material->getName(), materialName))
+    if (materialName == (*modMat)->material->getName())
       return (*modMat)->material;
   return NULL;
@@ -373,5 +366,5 @@
  * With it you should be able to create Models with more than one SubModel inside
  */
-bool StaticModel::addGroup(const char* groupString)
+bool StaticModel::addGroup(const std::string& groupString)
 {
   PRINTF(5)("Read Group: %s.\n", groupString);
@@ -382,8 +375,7 @@
     }
   // setting the group name if not default.
-  if (strcmp(groupString, "default"))
-    {
-      this->currentGroup->name = new char [strlen(groupString)+1];
-      strcpy(this->currentGroup->name, groupString);
+  if (groupString == "default")
+    {
+      this->currentGroup->name = groupString;
     }
   ++this->groupCount;
@@ -396,10 +388,10 @@
  *  If a vertex line is found this function will inject it into the vertex-Array
  */
-bool StaticModel::addVertex (const char* vertexString)
+bool StaticModel::addVertex (const std::string& vertexString)
 {
   float subbuffer1;
   float subbuffer2;
   float subbuffer3;
-  sscanf (vertexString, "%f %f %f", &subbuffer1, &subbuffer2, &subbuffer3);
+  sscanf (vertexString.c_str(), "%f %f %f", &subbuffer1, &subbuffer2, &subbuffer3);
   this->vertices.push_back(subbuffer1*scaleFactor);
   this->vertices.push_back(subbuffer2*scaleFactor);
@@ -431,10 +423,10 @@
  * If a vertexNormal line is found this function will inject it into the vertexNormal-Array
  */
-bool StaticModel::addVertexNormal (const char* normalString)
+bool StaticModel::addVertexNormal (const std::string& normalString)
 {
   float subbuffer1;
   float subbuffer2;
   float subbuffer3;
-  sscanf (normalString, "%f %f %f", &subbuffer1, &subbuffer2, &subbuffer3);
+  sscanf (normalString.c_str(), "%f %f %f", &subbuffer1, &subbuffer2, &subbuffer3);
   this->normals.push_back(subbuffer1);
   this->normals.push_back(subbuffer2);
@@ -471,9 +463,9 @@
  * !! WARNING THIS IS DIFFERNT FROM addVervexTexture(float, float); because it changes the second entry to 1-v !!
  */
-bool StaticModel::addVertexTexture (const char* vTextureString)
+bool StaticModel::addVertexTexture (const std::string& vTextureString)
 {
   float subbuffer1;
   float subbuffer2;
-  sscanf (vTextureString, "%f %f", &subbuffer1, &subbuffer2);
+  sscanf (vTextureString.c_str(), "%f %f", &subbuffer1, &subbuffer2);
   this->vTexture.push_back(subbuffer1);
   this->vTexture.push_back(1 - subbuffer2);
@@ -508,6 +500,7 @@
  * in this, that the first Vertex/Normal/Texcoord is 1 instead of 0
  */
-bool StaticModel::addFace (const char* faceString)
-{
+bool StaticModel::addFace (const std::string& faceStringInput)
+{
+  const char* faceString = faceStringInput.c_str();
   if (this->currentGroup->faceCount >0)
     this->currentGroup->currentFace = this->currentGroup->currentFace->next = new ModelFace;
@@ -596,5 +589,5 @@
  * @param matString the Material that will be set.
 */
-bool StaticModel::setMaterial(const char* matString)
+bool StaticModel::setMaterial(const std::string& matString)
 {
   if (this->currentGroup->faceCount > 0)
Index: branches/std/src/lib/graphics/importer/static_model.h
===================================================================
--- branches/std/src/lib/graphics/importer/static_model.h	(revision 7202)
+++ branches/std/src/lib/graphics/importer/static_model.h	(revision 7203)
@@ -13,7 +13,4 @@
 #include <vector>
 #include <list>
-
-// FORWARD DECLARATION //
-template<class T> class tArray;
 
 // definition of different modes for setting up Faces
@@ -70,5 +67,5 @@
   void cleanup();
 
-  char*        name;           //!< the Name of the Group. this is an identifier, that can be accessed via the draw (char* name) function.
+  std::string  name;           //!< the Name of the Group. this is an identifier, that can be accessed via the draw (std::string name) function.
   GLubyte*     indices;        //!< The indices of the Groups. Needed for vertex-arrays
   GLuint       listNumber;     //!< The number of the GL-List this Group gets.
@@ -98,31 +95,31 @@
 {
  public:
-  StaticModel(const char* modelName = NULL);
+  StaticModel(const std::string& modelName = NULL);
   virtual ~StaticModel();
 
   virtual void draw() const;
   void draw(int groupNumber) const;
-  void draw(char* groupName) const;
+  void draw(const std::string& groupName) const;
 
   void rebuild();
 
   Material* addMaterial(Material* material);
-  Material* addMaterial(const char* materialName);
+  Material* addMaterial(const std::string& materialName);
 
-  bool addGroup(const char* groupString);
+  bool addGroup(const std::string& groupString);
 
-  bool addVertex(const char* vertexString);
+  bool addVertex(const std::string& vertexString);
   bool addVertex(float x, float y, float z);
 
-  bool addFace(const char* faceString);
+  bool addFace(const std::string& faceString);
   bool addFace(int faceElemCount, VERTEX_FORMAT type, ...);
 
-  bool addVertexNormal(const char* normalString);
+  bool addVertexNormal(const std::string& normalString);
   bool addVertexNormal(float x, float y, float z);
 
-  bool addVertexTexture(const char* vTextureString);
+  bool addVertexTexture(const std::string& vTextureString);
   bool addVertexTexture(float u, float v);
 
-  bool setMaterial(const char* mtlString);
+  bool setMaterial(const std::string& mtlString);
   bool setMaterial(Material* mtl);
 
@@ -133,5 +130,5 @@
   void cubeModel();
 
-  Material* findMaterialByName(const char* materialName);
+  Material* findMaterialByName(const std::string& materialName);
 
  protected:
Index: branches/std/src/lib/graphics/importer/texture.cc
===================================================================
--- branches/std/src/lib/graphics/importer/texture.cc	(revision 7202)
+++ branches/std/src/lib/graphics/importer/texture.cc	(revision 7203)
@@ -32,5 +32,5 @@
  *  Constructor for a Texture
 */
-Texture::Texture(const char* imageName, GLenum target)
+Texture::Texture(const std::string& imageName, GLenum target)
 {
   this->setClassID(CL_TEXTURE, "Texture");
@@ -41,5 +41,5 @@
   this->priority = 0.5;
 
-  if (imageName != NULL)
+  if (!imageName.empty())
   {
     this->setName(imageName);
@@ -67,5 +67,5 @@
  * @param imageName The image to load
 */
-bool Texture::loadImage(const char* imageName, GLenum target)
+bool Texture::loadImage(const std::string& imageName, GLenum target)
 {
   if (Texture::texturesEnabled)
@@ -81,5 +81,5 @@
       this->texture = 0;
     }
-    if (imageName != NULL)
+    if (!imageName.empty())
     {
       SDL_Surface* tmpSurf;
@@ -87,5 +87,5 @@
         glDeleteTextures(1, &this->texture);
       // load the new Image to memory
-      tmpSurf = IMG_Load(imageName);
+      tmpSurf = IMG_Load(imageName.c_str());
       if(tmpSurf != NULL)
       {
Index: branches/std/src/lib/graphics/importer/texture.h
===================================================================
--- branches/std/src/lib/graphics/importer/texture.h	(revision 7202)
+++ branches/std/src/lib/graphics/importer/texture.h	(revision 7203)
@@ -18,9 +18,9 @@
   {
     public:
-      Texture(const char* imageName = NULL, GLenum target = GL_TEXTURE_2D);
+      Texture(const std::string& imageName = NULL, GLenum target = GL_TEXTURE_2D);
   //  Texture(TEXTURE_TYPE type, int resolution);
       virtual ~Texture();
 
-      bool loadImage(const char* imageName, GLenum target = GL_TEXTURE_2D);
+      bool loadImage(const std::string& imageName, GLenum target = GL_TEXTURE_2D);
       virtual bool rebuild();
 
Index: branches/std/src/lib/graphics/shader.cc
===================================================================
--- branches/std/src/lib/graphics/shader.cc	(revision 7202)
+++ branches/std/src/lib/graphics/shader.cc	(revision 7203)
@@ -36,10 +36,10 @@
  * standard constructor
 */
-Shader::Shader (const char* vertexShaderFile, const char* fragmentShaderFile)
+Shader::Shader (const std::string& vertexShaderFile, const std::string& fragmentShaderFile)
 {
    this->setClassID(CL_SHADER, "Shader");
 
-   this->fragmentShaderFile = NULL;
-   this->vertexShaderFile = NULL;
+   this->fragmentShaderFile = "";
+   this->vertexShaderFile = "";
    this->shaderProgram = 0;
    this->vertexShader = 0;
@@ -52,7 +52,7 @@
        this->shaderProgram = glCreateProgramObjectARB();
 
-       if (vertexShaderFile != NULL)
+       if (!vertexShaderFile.empty())
          this->loadShaderProgramm(SHADER_VERTEX, vertexShaderFile);
-       if (fragmentShaderFile != NULL)
+       if (!fragmentShaderFile.empty())
          this->loadShaderProgramm(SHADER_FRAGMENT, fragmentShaderFile);
        glLinkProgramARB(this->shaderProgram);
@@ -103,5 +103,5 @@
 }
 
-Shader* Shader::getShader(const char* vertexShaderFile, const char* fragmentShaderFile)
+Shader* Shader::getShader(const std::string& vertexShaderFile, const std::string& fragmentShaderFile)
 {
   return (Shader*)ResourceManager::getInstance()->load(vertexShaderFile, SHADER,  RP_LEVEL, fragmentShaderFile);
@@ -116,5 +116,5 @@
 
 
-bool Shader::loadShaderProgramm(SHADER_TYPE type, const char* fileName)
+bool Shader::loadShaderProgramm(SHADER_TYPE type, const std::string& fileName)
 {
   GLhandleARB shader = 0;
@@ -129,6 +129,5 @@
   if (type == SHADER_VERTEX && GLEW_ARB_vertex_shader)
   {
-    this->vertexShaderFile = new char[strlen(fileName)+1];
-    strcpy(this->vertexShaderFile, fileName);
+    this->vertexShaderFile = fileName;
 
     shader = this->vertexShader = glCreateShaderObjectARB(GL_VERTEX_SHADER_ARB);
@@ -137,6 +136,5 @@
   if (type == SHADER_FRAGMENT && GLEW_ARB_fragment_shader)
   {
-    this->fragmentShaderFile = new char[strlen(fileName)+1];
-    strcpy(this->fragmentShaderFile, fileName);
+    this->fragmentShaderFile = fileName;
 
     shader = this->fragmentShader = glCreateShaderObjectARB(GL_FRAGMENT_SHADER_ARB);
@@ -146,5 +144,6 @@
   {
     GLint status = 0;
-    glShaderSourceARB(shader, program->size(), (const char**)&(*program)[0], NULL);
+    /// FIXME do it back
+    //    glShaderSourceARB(shader, program->size(), (const std::string&)&(*program)[0], NULL);
     glCompileShaderARB(shader);
     // checking on error.
@@ -160,5 +159,5 @@
 }
 
-char* Shader::fileRead(const char* fileName)
+char* Shader::fileRead(const std::string& fileName)
 {
   FILE* fileHandle;
@@ -167,8 +166,8 @@
   int count = 0;
 
-  if (fileName == NULL)
+  if (fileName.empty())
     return NULL;
 
-  fileHandle = fopen(fileName, "rt");
+  fileHandle = fopen(fileName.c_str(), "rt");
 
   if (fileHandle == NULL)
@@ -187,11 +186,11 @@
 
 
-std::vector<char*>* Shader::fileReadArray(const char* fileName)
+std::vector<char*>* Shader::fileReadArray(const std::string& fileName)
 {
   FILE*    stream;           //< The stream we use to read the file.
 
-  if( (stream = fopen (fileName, "rt")) == NULL)
-  {
-    PRINTF(1)("Shader could not open %s\n", fileName);
+  if( (stream = fopen (fileName.c_str(), "rt")) == NULL)
+  {
+    PRINTF(1)("Shader could not open %s\n", fileName.c_str());
     return NULL;
   }
@@ -234,6 +233,5 @@
   if (type == SHADER_VERTEX && this->vertexShader != 0)
   {
-    delete[] this->vertexShaderFile;
-    this->vertexShaderFile = NULL;
+    this->vertexShaderFile = "";
     glDetachObjectARB(this->shaderProgram, this->vertexShader);
     glDeleteObjectARB(this->vertexShader);
@@ -245,6 +243,5 @@
   else if (type == SHADER_FRAGMENT && this->fragmentShader != 0)
   {
-    delete[] this->fragmentShaderFile;
-    this->fragmentShaderFile = NULL;
+    this->fragmentShaderFile = "";
     glDetachObjectARB(this->shaderProgram, this->fragmentShader);
     glDeleteObjectARB(this->fragmentShader);
Index: branches/std/src/lib/graphics/shader.h
===================================================================
--- branches/std/src/lib/graphics/shader.h	(revision 7202)
+++ branches/std/src/lib/graphics/shader.h	(revision 7203)
@@ -27,16 +27,16 @@
 
   public:
-  Shader(const char* vertexShaderFile = NULL, const char* fragmentShaderFile = NULL);
+  Shader(const std::string& vertexShaderFile = NULL, const std::string& fragmentShaderFile = NULL);
   virtual ~Shader();
-  static Shader* getShader(const char* vertexShaderFile, const char* fragmentShaderFile);
+  static Shader* getShader(const std::string& vertexShaderFile, const std::string& fragmentShaderFile);
   static bool unload(Shader* shader);
 
-  bool loadShaderProgramm(SHADER_TYPE type, const char* fileName);
+  bool loadShaderProgramm(SHADER_TYPE type, const std::string& fileName);
   void activateShader();
   static void deactivateShader();
   void deleteProgram(SHADER_TYPE type);
 
-  char* fileRead(const char* fileName);
-  std::vector<char*>* fileReadArray(const char* fileName);
+  char* fileRead(const std::string& fileName);
+  std::vector<char*>* fileReadArray(const std::string& fileName);
 
   static bool checkShaderAbility();
@@ -54,6 +54,6 @@
 
  private:
-   char*                  fragmentShaderFile;
-   char*                  vertexShaderFile;
+   std::string            fragmentShaderFile;
+   std::string            vertexShaderFile;
    GLhandleARB            shaderProgram;
    GLhandleARB            vertexShader;
Index: branches/std/src/lib/graphics/text_engine/font.cc
===================================================================
--- branches/std/src/lib/graphics/text_engine/font.cc	(revision 7202)
+++ branches/std/src/lib/graphics/text_engine/font.cc	(revision 7203)
@@ -37,5 +37,5 @@
  * @param fontSize the Size of the Font in Pixels
  */
-Font::Font(const char* fontFile, unsigned int renderSize)
+Font::Font(const std::string& fontFile, unsigned int renderSize)
 {
   this->init();
@@ -44,5 +44,5 @@
   this->setStyle("c");
 
-  if (fontFile != NULL)
+  if (!fontFile.empty())
     this->loadFontFromTTF(fontFile);
 }
@@ -52,5 +52,5 @@
  * @param imageFile the ImageFile to load the Font From.
  */
-Font::Font(const char* imageFile)
+Font::Font(const std::string& imageFile)
 {
   this->init();
@@ -58,6 +58,6 @@
   //  this->setSize(fontSize);
   SDL_Surface* image = NULL;
-  if (imageFile != NULL)
-    image = IMG_Load(imageFile);
+  if (!imageFile.empty())
+    image = IMG_Load(imageFile.c_str());
   else
     return;
@@ -68,5 +68,5 @@
   }
   else
-    PRINTF(1)("loading from surface %s failed: %s\n", imageFile, IMG_GetError());
+    PRINTF(1)("loading from surface %s failed: %s\n", imageFile.c_str(), IMG_GetError());
 }
 
@@ -114,7 +114,7 @@
 
   //! @todo check if we really do not need to delete the fastTextureID here.
-//   if (this->fastTextureID != 0)
-//     if(glIsTexture(this->fastTextureID))
-//       glDeleteTextures(1, &this->fastTextureID);
+  //   if (this->fastTextureID != 0)
+  //     if(glIsTexture(this->fastTextureID))
+  //       glDeleteTextures(1, &this->fastTextureID);
 
   // erease this font out of the memory.
@@ -140,5 +140,5 @@
  * @returns true if loaded, false if something went wrong, or if a font was loaded before.
  */
-bool Font::loadFontFromTTF(const char* fontFile)
+bool Font::loadFontFromTTF(const std::string& fontFile)
 {
   // checking for existent Font.
@@ -222,20 +222,21 @@
  *   i: italic, b: bold, u, underline
  */
-void Font::setStyle(const char* renderStyle)
+void Font::setStyle(const std::string& renderStyle)
 {
   this->renderStyle = TTF_STYLE_NORMAL;
 
-  for (int i = 0; i < strlen(renderStyle); i++)
-    if (strncmp(renderStyle+i, "b", 1) == 0)
+  for (int i = 0; i < renderStyle.size(); i++)
+  {
+    if (renderStyle[i] == 'b')
       this->renderStyle |= TTF_STYLE_BOLD;
-  else if (strncmp(renderStyle+i, "i", 1) == 0)
-    this->renderStyle |= TTF_STYLE_ITALIC;
-  else if (strncmp(renderStyle+i, "u", 1) == 0)
-    this->renderStyle |= TTF_STYLE_UNDERLINE;
-
+    else if (renderStyle[i] == 'i')
+      this->renderStyle |= TTF_STYLE_ITALIC;
+    else if (renderStyle[i] == 'u')
+      this->renderStyle |= TTF_STYLE_UNDERLINE;
+  }
   if (likely(this->fontTTF != NULL))
     TTF_SetFontStyle(this->fontTTF, this->renderStyle);
-//  else
-//    PRINTF(2)("Font was not initialized, please do so before setting the Font-Style.\n");
+  //  else
+  //    PRINTF(2)("Font was not initialized, please do so before setting the Font-Style.\n");
 }
 
@@ -247,5 +248,5 @@
  * @param fileName the File to write the image into.
  */
-void Font::createAsciiImage(const char* fileName, unsigned int size) const
+void Font::createAsciiImage(const std::string& fileName, unsigned int size) const
 {
   if (this->fontTTF == NULL)
@@ -258,16 +259,16 @@
   SDL_Rect tmpRect; // this represents a Rectangle for blitting.
   SDL_Surface* tmpSurf =  SDL_CreateRGBSurface(SDL_SWSURFACE,
-                                               height*size, height*size,
-                                               32,
+                          height*size, height*size,
+                          32,
 #if SDL_BYTEORDER == SDL_LIL_ENDIAN /* OpenGL RGBA masks */
-                                               0x000000FF,
-                                               0x0000FF00,
-                                               0x00FF0000,
-                                               0xFF000000
+                          0x000000FF,
+                          0x0000FF00,
+                          0x00FF0000,
+                          0xFF000000
 #else
-                                               0xFF000000,
-                                               0x00FF0000,
-                                               0x0000FF00,
-                                               0x000000FF
+                          0xFF000000,
+                          0x00FF0000,
+                          0x0000FF00,
+                          0x000000FF
 #endif
                                               );
@@ -299,5 +300,5 @@
     }
   }
-  SDL_SaveBMP(tmpSurf, fileName);
+  SDL_SaveBMP(tmpSurf, fileName.c_str());
   SDL_FreeSurface(tmpSurf);
 }
@@ -409,5 +410,5 @@
 
   this->initGlyphs(32, numberOfGlyphs);
-//  this->glyphArray[32]->width = .5f; //!< @todo find out the real size of a Space
+  //  this->glyphArray[32]->width = .5f; //!< @todo find out the real size of a Space
 
   int rectSize = this->findOptimalFastTextureSize();
@@ -418,16 +419,16 @@
   SDL_Rect tmpRect; // this represents a Rectangle for blitting.
   SDL_Surface* tmpSurf =  SDL_CreateRGBSurface(SDL_SWSURFACE,
-                                               rectSize, rectSize,
-                                               32,
+                          rectSize, rectSize,
+                          32,
 #if SDL_BYTEORDER == SDL_LIL_ENDIAN /* OpenGL RGBA masks */
-                                               0x000000FF,
-                                               0x0000FF00,
-                                               0x00FF0000,
-                                               0xFF000000
+                          0x000000FF,
+                          0x0000FF00,
+                          0x00FF0000,
+                          0xFF000000
 #else
-                                               0xFF000000,
-                                               0x00FF0000,
-                                               0x0000FF00,
-                                               0x000000FF
+                          0xFF000000,
+                          0x00FF0000,
+                          0x0000FF00,
+                          0x000000FF
 #endif
                                               );
@@ -457,5 +458,5 @@
         break;
       }
-          // reading in the new Glyph
+      // reading in the new Glyph
       if (likely(this->fontTTF != NULL))
       {
@@ -521,5 +522,5 @@
   for (int i = from; i <= lastGlyph; i++)
   {
-      // setting up all the Glyphs we like.
+    // setting up all the Glyphs we like.
     glyphArray[i] = getGlyphMetrics(i);
   }
@@ -555,5 +556,5 @@
       if((tmpGlyph = this->glyphArray[i]) != NULL)
       {
-              // getting the height of the highest Glyph in the Line.
+        // getting the height of the highest Glyph in the Line.
         if (tmpGlyph->height*this->renderSize > maxLineHeight)
           maxLineHeight = (int)(tmpGlyph->height*this->renderSize);
@@ -563,5 +564,5 @@
           x = 0;
           y = y + maxLineHeight;
-                  //maxLineHeight = 0;
+          //maxLineHeight = 0;
         }
         if (y + maxLineHeight + 1 > size)
@@ -592,5 +593,6 @@
   if(style==TTF_STYLE_NORMAL)
     PRINTF(0)(" normal");
-  else {
+  else
+  {
     if(style&TTF_STYLE_BOLD)
       PRINTF(0)(" bold");
Index: branches/std/src/lib/graphics/text_engine/font.h
===================================================================
--- branches/std/src/lib/graphics/text_engine/font.h	(revision 7202)
+++ branches/std/src/lib/graphics/text_engine/font.h	(revision 7203)
@@ -55,7 +55,7 @@
 {
   public:
-    Font(const char* fontFile,
+    Font(const std::string& fontFile,
          unsigned int renderSize);
-    Font(const char* imageFile);
+    Font(const std::string& imageFile);
     Font(char** xpmArray);
     virtual ~Font();
@@ -64,8 +64,8 @@
 
   //  font
-    bool loadFontFromTTF(const char* fontFile);
+    bool loadFontFromTTF(const std::string& fontFile);
     bool loadFontFromSDL_Surface(SDL_Surface* surface);
 
-    void setStyle(const char* renderStyle);
+    void setStyle(const std::string& renderStyle);
 
     /** @returns a Pointer to the Array of Glyphs */
@@ -78,5 +78,5 @@
     inline static Font* getDefaultFont() { if (Font::defaultFont == NULL) initDefaultFont(); return Font::defaultFont; };
 
-    void createAsciiImage(const char* fileName, unsigned int size) const;
+    void createAsciiImage(const std::string& fileName, unsigned int size) const;
     static void initDefaultFont();
     static void removeDefaultFont();
Index: branches/std/src/lib/gui/gtk_gui/gui_exec.cc
===================================================================
--- branches/std/src/lib/gui/gtk_gui/gui_exec.cc	(revision 7202)
+++ branches/std/src/lib/gui/gtk_gui/gui_exec.cc	(revision 7203)
@@ -47,6 +47,6 @@
   Frame* execFrame;            //!< The Frame that holds the ExecutionOptions.
 
-  this->confFile = NULL;
-  this->confDir = NULL;
+  this->confFile = "";
+  this->confDir = "";
 
   execFrame = new Frame("Execute-Tags:");
@@ -137,8 +137,4 @@
 GuiExec::~GuiExec()
 {
-  if(this->confFile)
-    delete []this->confFile;
-  if(this->confDir)
-    delete []this->confDir;
 }
 
@@ -156,7 +152,7 @@
   //! @todo F** Windows-support
 #ifndef __WIN32__
-  mkdir(this->confDir, 0755);
+  mkdir(this->confDir.c_str(), 0755);
 #else /* __WiN32__ */
-  mkdir(this->confDir);
+  mkdir(this->confDir.c_str());
 #endif /* __WIN32__ */
 }
@@ -170,8 +166,7 @@
 void GuiExec::setConfFile(const char* fileName)
 {
-  if (!this->confDir)
+  if (!this->confDir.empty())
     this->setConfDir("~/");
-  this->confFile = new char[strlen(this->confDir)+strlen(fileName)+2];
-  sprintf(this->confFile, "%s/%s", this->confDir, fileName);
+  this->confFile = this->confDir + "/" + fileName;
   PRINTF(5)("ConfigurationFile is %s.\n", this->confFile);
 }
@@ -182,5 +177,5 @@
 const char* GuiExec::getConfigFile() const
 {
-  return this->confFile;
+  return this->confFile.c_str();
 }
 
@@ -204,7 +199,6 @@
   IniParser iniParser;
   this->writeFileText(widget, &iniParser, 0);
-  char* fileName = ResourceManager::homeDirCheck(confFile);
+  std::string fileName = ResourceManager::homeDirCheck(confFile);
   iniParser.writeFile(fileName);
-  delete[] fileName;
 }
 
@@ -259,7 +253,6 @@
 void GuiExec::readFromFile(Widget* widget)
 {
-  char* fileName = ResourceManager::homeDirCheck(confFile);
+  std::string fileName = ResourceManager::homeDirCheck(confFile);
   IniParser iniParser(fileName);
-  delete[] fileName;
   if (!iniParser.isOpen())
     return;
@@ -267,13 +260,13 @@
   iniParser.firstSection();
   Widget* groupWidget = widget;
-  const char* groupName;
-  const char* widgetName;
+  std::string groupName;
+  std::string widgetName;
   VarInfo varInfo;
-  while (groupName = iniParser.getCurrentSection())
+  while ((groupName = iniParser.getCurrentSection()) != "")
   {
-    printf("GROUP:::%s\n", groupName);
-    if((groupWidget = locateGroup(widget, groupName, 1))==NULL)
+    PRINTF(4)("GROUP:::%s\n", groupName.c_str());
+    if((groupWidget = locateGroup(widget, groupName.c_str(), 1))==NULL)
       {
-	PRINTF(2)("!!There is no group called %s in this GUI.\n First best Widget will get the Infos assigned.\n Config-File will be updated in next Save\n", groupName);
+        PRINTF(2)("!!There is no group called %s in this GUI.\n First best Widget will get the Infos assigned.\n Config-File will be updated in next Save\n", groupName.c_str());
 	groupWidget = widget;
 	continue;
@@ -282,11 +275,11 @@
       PRINT(4)("Group %s located.\n", static_cast<Packer*>(groupWidget)->groupName);
 
-    const char* entryName;
+    std::string entryName;
     iniParser.firstVar();
-    while(entryName = iniParser.getCurrentName())
-    {
-      PRINTF(4)("ENTRY:::%s = %s\n", entryName, iniParser.getCurrentValue());
-      varInfo.variableName = entryName;
-      varInfo.variableValue = iniParser.getCurrentValue();
+    while((entryName = iniParser.getCurrentName()) != "")
+    {
+      PRINTF(4)("ENTRY:::%s = %s\n", entryName.c_str(), iniParser.getCurrentValue().c_str());
+      varInfo.variableName = entryName.c_str();
+      varInfo.variableValue = iniParser.getCurrentValue().c_str();
       groupWidget->walkThrough(this->readFileText, &varInfo, 0);
       iniParser.nextVar();
Index: branches/std/src/lib/gui/gtk_gui/gui_exec.h
===================================================================
--- branches/std/src/lib/gui/gtk_gui/gui_exec.h	(revision 7202)
+++ branches/std/src/lib/gui/gtk_gui/gui_exec.h	(revision 7203)
@@ -11,4 +11,6 @@
 #include "gui_gtk.h"
 
+#include <string>
+
 class Widget;
 class CheckButton;
@@ -22,6 +24,6 @@
   CheckButton* saveSettings;   //!< A CheckBox for if the Options should be saved.
 
-  char* confDir;               //!< The directory of the orxonox-configuration-files.
-  char* confFile;              //!< The name of the .orxonox.conf(ig)-file.
+  std::string confDir;         //!< The directory of the orxonox-configuration-files.
+  std::string confFile;        //!< The name of the .orxonox.conf(ig)-file.
 
   //! A struct that holds informations about variables.
@@ -58,6 +60,6 @@
 struct HashTable
 {
-  char* name;           //!< name of the entry
-  char* value;          //!< value of the entry
+  std::string name;           //!< name of the entry
+  std::string value;          //!< value of the entry
   HashTable* next;      //!< pointer to the next entry
 };
Index: branches/std/src/lib/lang/base_object.cc
===================================================================
--- branches/std/src/lib/lang/base_object.cc	(revision 7202)
+++ branches/std/src/lib/lang/base_object.cc	(revision 7203)
@@ -95,12 +95,12 @@
  * @brief set the name of the Object
  */
-void BaseObject::setName (const char* objectName)
+void BaseObject::setName (const std::string& objectName)
 {
   if (this->objectName)
     delete[] this->objectName;
-  if (objectName != NULL)
-  {
-    this->objectName = new char[strlen(objectName)+1];
-    strcpy(this->objectName, objectName);
+  if (!objectName.empty())
+  {
+    this->objectName = new char[objectName.size()+1];
+    strcpy(this->objectName, objectName.c_str());
   }
   else
Index: branches/std/src/lib/lang/base_object.h
===================================================================
--- branches/std/src/lib/lang/base_object.h	(revision 7202)
+++ branches/std/src/lib/lang/base_object.h	(revision 7203)
@@ -16,4 +16,5 @@
 #endif
 
+#include <string>
 #include "stdincl.h"
 
@@ -30,5 +31,5 @@
 
   virtual void loadParams(const TiXmlElement* root);
-  void setName (const char* newName);
+  void setName (const std::string& newName);
   /** returns the Name of this Object */
   inline const char* getName ()const { return this->objectName; };
Index: branches/std/src/lib/parser/ini_parser/ini_parser.cc
===================================================================
--- branches/std/src/lib/parser/ini_parser/ini_parser.cc	(revision 7202)
+++ branches/std/src/lib/parser/ini_parser/ini_parser.cc	(revision 7203)
@@ -40,10 +40,10 @@
  * @param fileName: the path and name of the file to parse
  */
-IniParser::IniParser (const char* fileName)
-{
-  this->fileName = NULL;
-  this->comment = NULL;
-
-  if (fileName != NULL)
+IniParser::IniParser (const std::string& fileName)
+{
+  this->fileName = "";
+  this->comment = "";
+
+  if (!fileName.empty())
     this->readFile(fileName);
 }
@@ -59,4 +59,6 @@
 }
 
+const std::string IniParser::emptyString = "";
+
 
 /**
@@ -68,5 +70,5 @@
   while(!this->sections.empty())
   {
-     IniSection section = this->sections.front();
+    IniSection section = this->sections.front();
 
     // in all entries of the sections
@@ -75,12 +77,7 @@
       // delete all strings of entries.
       IniEntry entry = section.entries.front();
-      delete[] entry.name;
-      delete[] entry.value;
-      delete[] entry.comment;
       section.entries.pop_front();
     }
     // delete all Sections
-    delete[] section.name;
-    delete[] section.comment;
     this->sections.pop_front();
   }
@@ -95,19 +92,12 @@
  * If fileName is NULL the new Name will be set to NULL too.
  */
-void IniParser::setFileName(const char* fileName)
-{
-  if (this->fileName != NULL)
-    delete[] this->fileName;
-  if  (this->comment != NULL)
-    delete[] this->comment;
-  this->comment = NULL;
-
-  if (fileName != NULL)
-  {
-    this->fileName = new char[strlen(fileName)+1];
-    strcpy(this->fileName, fileName);
-  }
-  else
-    this->fileName = NULL;
+void IniParser::setFileName(const std::string& fileName)
+{
+  this->comment = "";
+
+  if (!fileName.empty())
+    this->fileName = fileName;
+  else
+    this->fileName = "";
 }
 
@@ -121,17 +111,17 @@
  * and the new one will be opened.
  */
-bool IniParser::readFile(const char* fileName)
+bool IniParser::readFile(const std::string& fileName)
 {
   FILE*    stream;           //< The stream we use to read the file.
   int      lineCount = 0;    //< The Count of lines.
 
-  if (this->fileName != NULL)
+  if (!this->fileName.empty())
     this->deleteSections();
-  if( fileName == NULL)
-    return false;
-
-  if( (stream = fopen (fileName, "r")) == NULL)
-  {
-    PRINTF(1)("IniParser could not open %s\n", fileName);
+  if( fileName.empty())
+    return false;
+
+  if( (stream = fopen (fileName.c_str(), "r")) == NULL)
+  {
+    PRINTF(1)("IniParser could not open %s\n", fileName.c_str());
     return false;
   }
@@ -191,5 +181,6 @@
           continue;
         }
-        if( ptr == lineBegin) {
+        if( ptr == lineBegin)
+        {
           lineCount++;
           continue;
@@ -228,53 +219,43 @@
  * @return true on success false otherwise
  */
-bool IniParser::writeFile(const char* fileName) const
+bool IniParser::writeFile(const std::string& fileName) const
 {
   FILE*    stream;           //!< The stream we use to read the file.
-  if( fileName == NULL && (fileName = this->fileName) == NULL )
-    return false;
-
-  if( (stream = fopen (fileName, "w")) == NULL)
-  {
-    PRINTF(1)("IniParser could not open %s\n", fileName);
-    return false;
-  }
-  else
-  {
-    if (this->comment != NULL)
-      fprintf(stream, "%s\n\n", this->comment);
+  if( fileName.empty())
+    return false;
+
+  if( (stream = fopen (fileName.c_str(), "w")) == NULL)
+  {
+    PRINTF(1)("IniParser could not open %s\n", fileName.c_str());
+    return false;
+  }
+  else
+  {
+    if (!this->comment.empty())
+      fprintf(stream, "%s\n\n", this->comment.c_str());
 
     std::list<IniSection>::const_iterator section;
     for (section = this->sections.begin(); section != this->sections.end(); section++)
+    {
+      if (!(*section).comment.empty())
+        fprintf(stream, "%s", (*section).comment.c_str());
+      fprintf(stream, "\n [%s]\n", (*section).name.c_str());
+
+      std::list<IniEntry>::const_iterator entry;
+      for (entry = (*section).entries.begin(); entry != (*section).entries.end(); entry++)
       {
-        if ((*section).comment != NULL)
-          fprintf(stream, "%s", (*section).comment);
-        fprintf(stream, "\n [%s]\n", (*section).name);
-
-        std::list<IniEntry>::const_iterator entry;
-        for (entry = (*section).entries.begin(); entry != (*section).entries.end(); entry++)
-        {
-          if ((*entry).comment != NULL)
-            fprintf(stream, "%s", (*entry).comment);
-          fprintf(stream, "   %s = %s\n", (*entry).name, (*entry).value);
-         }
+        if (!(*entry).comment.empty())
+          fprintf(stream, "%s", (*entry).comment.c_str());
+        fprintf(stream, "   %s = %s\n", (*entry).name.c_str(), (*entry).value.c_str());
       }
+    }
   }
   fclose(stream);
 }
 
-void IniParser::setFileComment(const char* fileComment)
-{
-  if (this->comment != NULL)
-    delete this->comment;
-
-  if (fileComment != NULL)
-  {
-    this->comment = new char[strlen(fileComment)+1];
-    strcpy(this->comment, fileComment);
-  }
-  else
-    this->comment = NULL;
-}
-
+void IniParser::setFileComment(const std::string& fileComment)
+{
+  this->comment = fileComment;
+}
 
 /**
@@ -284,16 +265,15 @@
  * @return true on success... there is only success or segfault :)
  */
-bool IniParser::addSection(const char* sectionName)
-{
-  if (sectionName == NULL)
+bool IniParser::addSection(const std::string& sectionName)
+{
+  if (sectionName.empty())
     return false;
   this->sections.push_back(IniSection());
-  this->sections.back().comment = NULL;
-  this->sections.back().name = new char[strlen(sectionName)+1];
-  strcpy(this->sections.back().name, sectionName);
+  this->sections.back().comment = "";
+  this->sections.back().name = sectionName;
 
   this->currentSection = --this->sections.end();
   if (!this->sections.empty())
-      this->currentEntry = (*this->currentSection).entries.begin();
+    this->currentEntry = (*this->currentSection).entries.begin();
   PRINTF(5)("Added Section %s\n", sectionName);
   return true;
@@ -306,5 +286,5 @@
  * @return true on success or false if the section could not be found
  */
-bool IniParser::getSection(const char* sectionName)
+bool IniParser::getSection(const std::string& sectionName)
 {
   this->currentSection = this->getSectionIT(sectionName);
@@ -321,5 +301,5 @@
  *
  */
-void IniParser::setSectionComment(const char* comment, const char* sectionName)
+void IniParser::setSectionComment(const std::string& comment, const std::string& sectionName)
 {
   std::list<IniSection>::iterator section = this->getSectionIT(sectionName);
@@ -327,13 +307,5 @@
     return;
 
-  if ((*section).comment != NULL)
-    delete[] (*section).comment;
-  if (comment != NULL)
-  {
-    (*section).comment = new char[strlen (comment)+1];
-    strcpy((*section).comment, comment);
-  }
-  else
-    (*section).comment = NULL;
+  (*section).comment = comment;
 }
 
@@ -342,5 +314,5 @@
  * @returns the Comment, or NULL on error.
  */
-const char* IniParser::getSectionComment(const char* sectionName) const
+const std::string& IniParser::getSectionComment(const std::string& sectionName) const
 {
   std::list<IniSection>::const_iterator section = this->getSectionIT(sectionName);
@@ -348,5 +320,5 @@
     return (*section).comment;
   else
-    return NULL;
+    return IniParser::emptyString;
 }
 
@@ -367,18 +339,18 @@
  * @returns the name of the section if found, NULL otherwise
  */
-const char* IniParser::nextSection()
+const std::string& IniParser::nextSection()
 {
   if (this->currentSection == this->sections.end())
-    return NULL;
+    return IniParser::emptyString;
 
   this->currentSection++;
 
   if (this->currentSection != this->sections.end())
-    {
-      this->currentEntry = (*this->currentSection).entries.begin();
-      return this->currentSection->name;
-    }
-  else
-    return NULL;
+  {
+    this->currentEntry = (*this->currentSection).entries.begin();
+    return this->currentSection->name;
+  }
+  else
+    return IniParser::emptyString;
 }
 
@@ -393,12 +365,12 @@
  * @return true if everything is ok false on error
  */
-bool IniParser::addVar(const char* entryName, const char* value, const char* sectionName)
+bool IniParser::addVar(const std::string& entryName, const std::string& value, const std::string& sectionName)
 {
   std::list<IniSection>::iterator section;
 
-  if (sectionName != NULL)
+  if (!sectionName.empty())
   {
     for (section = this->sections.begin(); section != this->sections.end(); section++)
-      if (!strcmp((*section).name, sectionName))
+      if ((*section).name == sectionName)
         break;
   }
@@ -411,5 +383,5 @@
   if (section == this->sections.end())
   {
-    PRINTF(2)("section '%s' not found for value '%s'\n", sectionName, entryName);
+    PRINTF(2)("section '%s' not found for value '%s'\n", sectionName.c_str(), entryName.c_str());
     return false;
   }
@@ -417,13 +389,11 @@
   {
     (*section).entries.push_back(IniEntry());
-    (*section).entries.back().comment = NULL;
-    (*section).entries.back().name = new char[strlen(entryName)+1];
-    strcpy((*section).entries.back().name, entryName);
-    (*section).entries.back().value = new char[strlen(value)+1];
-    strcpy((*section).entries.back().value, value);
+    (*section).entries.back().comment = "";
+    (*section).entries.back().name = entryName;
+    (*section).entries.back().value = value;
     PRINTF(5)("Added Entry %s with Value '%s' to Section %s\n",
-              (*section).entries.back().name,
-              (*section).entries.back().value,
-              (*section).name);
+              (*section).entries.back().name.c_str(),
+              (*section).entries.back().value.c_str(),
+              (*section).name.c_str());
     this->currentEntry = --(*section).entries.end();
     return true;
@@ -442,12 +412,12 @@
  * lead to unwanted behaviour.
 */
-const char* IniParser::getVar(const char* entryName, const char* sectionName, const char* defaultValue) const
-{
-  if (this->fileName != NULL)
+const std::string& IniParser::getVar(const std::string& entryName, const std::string& sectionName, const std::string& defaultValue) const
+{
+  if (!this->fileName.empty())
   {
     std::list<IniEntry>::const_iterator entry = this->getEntryIT(entryName, sectionName);
-    if (entry != NULL &&  !strcmp((*entry).name, entryName))
+    if (entry != NULL &&  (*entry).name == entryName)
       return (*entry).value;
-    PRINTF(2)("Entry '%s' in section '%s' not found.\n", entryName, sectionName);
+    PRINTF(2)("Entry '%s' in section '%s' not found.\n", entryName.c_str(), sectionName.c_str());
 
   }
@@ -456,5 +426,4 @@
 
   return defaultValue;
-
 }
 
@@ -465,19 +434,8 @@
  * @param sectionName the Name of the Section
  */
-void IniParser::setEntryComment(const char* comment, const char* entryName, const char* sectionName)
+void IniParser::setEntryComment(const std::string& comment, const std::string& entryName, const std::string& sectionName)
 {
   std::list<IniEntry>::iterator entry = this->getEntryIT(entryName, sectionName);
-
-  if ((*entry).comment != NULL)
-    delete[] (*entry).comment;
-  if (comment != NULL)
-  {
-    (*entry).comment = new char[strlen (comment)+1];
-    strcpy((*entry).comment, comment);
-  }
-  else
-    (*entry).comment = NULL;
-
-
+  (*entry).comment = comment;
 }
 
@@ -487,5 +445,5 @@
  * @returns the queried Comment.
  */
-const char* IniParser::getEntryComment(const char* entryName, const char* sectionName) const
+const std::string& IniParser::getEntryComment(const std::string& entryName, const std::string& sectionName) const
 {
   std::list<IniEntry>::const_iterator entry = this->getEntryIT(entryName, sectionName);
@@ -501,5 +459,5 @@
 {
   if (!this->sections.empty() &&
-       this->currentSection != this->sections.end())
+      this->currentSection != this->sections.end())
     this->currentEntry = (*this->currentSection).entries.begin();
 }
@@ -530,5 +488,5 @@
  * @returns the name of the Current selected Section
  */
-const char* IniParser::getCurrentSection() const
+const std::string& IniParser::getCurrentSection() const
 {
   if (!this->sections.empty() &&
@@ -536,6 +494,6 @@
     return this->currentSection->name;
   else
-    return NULL;
- }
+    return IniParser::emptyString ;
+}
 
 
@@ -543,12 +501,12 @@
  * @returns the current entries Name, or NULL if we havn't selected a Entry
  */
-const char* IniParser::getCurrentName() const
-{
- if (!this->sections.empty() &&
-     this->currentSection != this->sections.end() &&
-     this->currentEntry != (*this->currentSection).entries.end())
-   return (*this->currentEntry).name;
- else
-   return NULL;
+const std::string& IniParser::getCurrentName() const
+{
+  if (!this->sections.empty() &&
+      this->currentSection != this->sections.end() &&
+      this->currentEntry != (*this->currentSection).entries.end())
+    return (*this->currentEntry).name;
+  else
+    return emptyString;
 }
 
@@ -556,5 +514,5 @@
  * @returns the current entries Value, or NULL if we havn't selected a Entry
  */
-const char* IniParser::getCurrentValue() const
+const std::string& IniParser::getCurrentValue() const
 {
   if (!this->sections.empty() &&
@@ -563,5 +521,5 @@
     return (*this->currentEntry).value;
   else
-    return NULL;
+    return IniParser::emptyString;
 }
 
@@ -571,12 +529,12 @@
  * @param sectionName the Name of the Section to get the Iterator from
  */
-std::list<IniParser::IniSection>::const_iterator IniParser::getSectionIT(const char* sectionName) const
+std::list<IniParser::IniSection>::const_iterator IniParser::getSectionIT(const std::string& sectionName) const
 {
   std::list<IniSection>::const_iterator section = this->currentSection;
-  if (sectionName == NULL)
+  if (sectionName.empty())
     return this->currentSection;
   else
     for (section = this->sections.begin(); section != this->sections.end(); section++)
-      if (!strcmp((*section).name, sectionName))
+      if ((*section).name == sectionName)
         break;
   return section;
@@ -588,12 +546,12 @@
  * @param sectionName the Name of the Section to get the Iterator from
  */
-std::list<IniParser::IniSection>::iterator IniParser::getSectionIT(const char* sectionName)
+std::list<IniParser::IniSection>::iterator IniParser::getSectionIT(const std::string& sectionName)
 {
   std::list<IniSection>::iterator section = this->currentSection;
-  if (sectionName == NULL)
+  if (sectionName.empty())
     return this->currentSection;
   else
     for (section = this->sections.begin(); section != this->sections.end(); section++)
-      if (!strcmp((*section).name, sectionName))
+      if ((*section).name == sectionName)
         break;
   return section;
@@ -606,7 +564,7 @@
  * @param sectionName the Name of the Section to get the Iterator from
  */
-std::list<IniParser::IniEntry>::const_iterator IniParser::getEntryIT(const char* entryName, const char* sectionName) const
-{
-  if (entryName == NULL)
+std::list<IniParser::IniEntry>::const_iterator IniParser::getEntryIT(const std::string& entryName, const std::string& sectionName) const
+{
+  if (entryName.empty())
     return this->currentEntry;
   std::list<IniSection>::const_iterator section = this->getSectionIT(sectionName);
@@ -615,5 +573,5 @@
   if (section != this->sections.end())
     for (entry = (*section).entries.begin(); entry != (*section).entries.end(); entry++)
-      if (!strcmp((*entry).name, entryName))
+      if ((*entry).name == entryName)
         break;
   if (entry == (*section).entries.end())
@@ -629,7 +587,7 @@
  * @param sectionName the Name of the Section to get the Iterator from
  */
-std::list<IniParser::IniEntry>::iterator IniParser::getEntryIT(const char* entryName, const char* sectionName)
-{
-  if (entryName == NULL)
+std::list<IniParser::IniEntry>::iterator IniParser::getEntryIT(const std::string& entryName, const std::string& sectionName)
+{
+  if (entryName.empty())
     return this->currentEntry;
   std::list<IniSection>::iterator section = this->getSectionIT(sectionName);
@@ -638,5 +596,5 @@
   if (section != this->sections.end())
     for (entry = (*section).entries.begin(); entry != (*section).entries.end(); entry++)
-      if (!strcmp((*entry).name, entryName))
+      if ((*entry).name == entryName)
         break;
   if (entry == (*section).entries.end())
@@ -652,25 +610,17 @@
 void IniParser::setFileComment()
 {
-  if (this->comment != NULL)
-    delete[] this->comment;
-
-  if (this->commentList.empty()) {
-    this->comment = NULL;
+  if (this->commentList.empty())
+  {
+    this->comment = "";
     return;
   }
 
-  unsigned int stringLength = 1;
   std::list<char*>::iterator comment;
-  for (comment = this->commentList.begin(); comment != this->commentList.end(); comment++)
-    stringLength += strlen((*comment)) +1;
-
-  this->comment = new char[stringLength];
-  this->comment[0] = '\0';
+
   while (!this->commentList.empty())
   {
-    if (*this->comment != '\0')
-      strcat(this->comment, "\n");
-    strcat(this->comment, this->commentList.front());
-    delete[] this->commentList.front();
+    if (this->comment[0] != '\0')
+      this->comment += "\n";
+    this->comment += this->commentList.front();
     this->commentList.pop_front();
   }
@@ -682,25 +632,14 @@
 void IniParser::setSectionComment()
 {
-  if ((*this->currentSection).comment != NULL)
-    delete[] (*this->currentSection).comment;
-
-  if (this->commentList.empty()) {
-    (*this->currentSection).comment = NULL;
+  (*this->currentSection).comment = "";
+
+  if (this->commentList.empty())
     return;
-  }
-
-  unsigned int stringLength = 1;
-  std::list<char*>::iterator comment;
-  for (comment = this->commentList.begin(); comment != this->commentList.end(); comment++)
-    stringLength += strlen((*comment)) +1;
-
-  (*this->currentSection).comment = new char[stringLength];
-  (*this->currentSection).comment[0] = '\0';
+
   while (!this->commentList.empty())
   {
-    if (*(*this->currentSection).comment != '\0')
-      strcat((*this->currentSection).comment, "\n");
-    strcat((*this->currentSection).comment, this->commentList.front());
-    delete[] this->commentList.front();
+    if ((*this->currentSection).comment[0] != '\0')
+      (*this->currentSection).comment += "\n";
+    (*this->currentSection).comment += this->commentList.front();
     this->commentList.pop_front();
   }
@@ -712,28 +651,15 @@
 void IniParser::setEntryComment()
 {
-  if ((*this->currentEntry).comment != NULL)
-    delete[] (*this->currentEntry).comment;
-
-  if (this->commentList.empty()) {
-    (*this->currentEntry).comment = NULL;
+  (*this->currentEntry).comment = "";
+  if (this->commentList.empty())
     return;
-  }
-
-  unsigned int stringLength = 1;
-  std::list<char*>::iterator comment;
-  for (comment = this->commentList.begin(); comment != this->commentList.end(); comment++)
-    stringLength += strlen((*comment)) +1;
-
-  (*this->currentEntry).comment = new char[stringLength];
-  (*this->currentEntry).comment[0] = '\0';
+
   while (!this->commentList.empty())
   {
-    if (*(*this->currentEntry).comment != '\0')
-      strcat((*this->currentEntry).comment, "\n");
-    strcat((*this->currentEntry).comment, this->commentList.front());
-    delete[] this->commentList.front();
+    if ((*this->currentEntry).comment[0] != '\0')
+      (*this->currentEntry).comment += "\n";
+    (*this->currentEntry).comment += this->commentList.front();
     this->commentList.pop_front();
   }
-
 }
 
@@ -744,23 +670,23 @@
 void IniParser::debug() const
 {
-  PRINTF(0)("Iniparser %s - debug\n", this->fileName);
-  if (this->comment != NULL)
-    PRINTF(0)("FileComment:\n %s\n\n", this->comment);
-
-  if (this->fileName != NULL)
+  PRINTF(0)("Iniparser %s - debug\n", this->fileName.c_str());
+  if (!this->comment.empty())
+    PRINTF(0)("FileComment:\n %s\n\n", this->comment.c_str());
+
+  if (!this->fileName.empty())
   {
     std::list<IniSection>::const_iterator section;
     for (section = this->sections.begin(); section != this->sections.end(); section++)
     {
-      if ((*section).comment != NULL)
-        PRINTF(0)(" %s\n", (*section).comment);
-      PRINTF(0)(" [%s]\n", (*section).name);
+      if (!(*section).comment.empty())
+        PRINTF(0)(" %s\n", (*section).comment.c_str());
+      PRINTF(0)(" [%s]\n", (*section).name.c_str());
 
       std::list<IniEntry>::const_iterator entry;
       for (entry = (*section).entries.begin(); entry != (*section).entries.end(); entry++)
       {
-        if ((*entry).comment != NULL)
-          PRINTF(0)(" %s\n", (*entry).comment);
-        PRINTF(0)("   '%s' -> '%s'\n", (*entry).name, (*entry).value);
+        if (!(*entry).comment.empty())
+          PRINTF(0)(" %s\n", (*entry).comment.c_str());
+        PRINTF(0)("   '%s' -> '%s'\n", (*entry).name.c_str(), (*entry).value.c_str());
       }
     }
Index: branches/std/src/lib/parser/ini_parser/ini_parser.h
===================================================================
--- branches/std/src/lib/parser/ini_parser/ini_parser.h	(revision 7202)
+++ branches/std/src/lib/parser/ini_parser/ini_parser.h	(revision 7203)
@@ -15,4 +15,5 @@
 
 #include <list>
+#include <string>
 
 //! ini-file parser
@@ -27,7 +28,7 @@
     struct IniEntry
     {
-      char*               comment;  //!< A Comment that is appendet to the Top of this Entry.
-      char*               name;     //!< name of a given Entry
-      char*               value;    //!< value of a given Entry
+      std::string         comment;  //!< A Comment that is appendet to the Top of this Entry.
+      std::string         name;     //!< name of a given Entry
+      std::string         value;    //!< value of a given Entry
     };
 
@@ -35,6 +36,6 @@
     struct IniSection
     {
-      char*               comment;  //!< A Comment that is appendet to the Top of this Section.
-      char*               name;     //!< name of a given section
+      std::string         comment;  //!< A Comment that is appendet to the Top of this Section.
+      std::string         name;     //!< name of a given section
       std::list<IniEntry> entries;  //!< a list of entries for this section
     };
@@ -42,32 +43,32 @@
 
   public:
-    IniParser (const char* filename = NULL);
+    IniParser (const std::string& filename = "");
     virtual ~IniParser ();
 
     /** @returns true if the file is opened, false otherwise*/
-    bool isOpen() const { return (this->fileName != NULL)? true : false; };
+    bool isOpen() const { return (!this->fileName.empty())? true : false; };
     /** @returns the fileName we have opened. */
-    const char* getFileName() const { return this->fileName; };
+    const std::string& getFileName() const { return this->fileName; };
 
-    bool readFile(const char* fileName);
-    bool writeFile(const char* fileName) const;
+    bool readFile(const std::string& fileName);
+    bool writeFile(const std::string& fileName) const;
 
-    void setFileComment(const char* fileComment);
-    const char* getFileComment() const { return this->comment; };
+    void setFileComment(const std::string& fileComment);
+    const std::string& getFileComment() const { return this->comment; };
 
-    bool addSection(const char* sectionName);
-    bool getSection(const char* sectionName);
-    void setSectionComment(const char* comment, const char* sectionName);
-    const char* getSectionComment(const char* sectionNane) const;
+    bool addSection(const std::string& sectionName);
+    bool getSection(const std::string& sectionName);
+    void setSectionComment(const std::string& comment, const std::string& sectionName);
+    const std::string& getSectionComment(const std::string& sectionNane) const;
 
     // iterate through sections with these Functions
     void firstSection();
-    const char* nextSection();
+    const std::string& nextSection();
 
 
-    bool addVar(const char* entryName, const char* value, const char* sectionName = NULL);
-    const char* getVar(const char* entryName, const char* sectionName, const char* defaultValue = "") const;
-    void setEntryComment(const char* comment, const char* entryName, const char* sectionName);
-    const char* getEntryComment(const char* entryName, const char* sectionName) const;
+    bool addVar(const std::string& entryName, const std::string& value, const std::string& sectionName = NULL);
+    const std::string& getVar(const std::string& entryName, const std::string& sectionName, const std::string& defaultValue = "") const;
+    void setEntryComment(const std::string& comment, const std::string& entryName, const std::string& sectionName);
+    const std::string& getEntryComment(const std::string& entryName, const std::string& sectionName) const;
 
     // iterate Through Variables with these Functions.
@@ -77,7 +78,7 @@
 
     // retrieving functions when iterating.
-    const char* getCurrentSection() const;
-    const char* getCurrentName() const;
-    const char* getCurrentValue() const;
+    const std::string& getCurrentSection() const;
+    const std::string& getCurrentName() const;
+    const std::string& getCurrentValue() const;
 
 
@@ -88,5 +89,5 @@
   private:
     void deleteSections();
-    void setFileName(const char* fileName);
+    void setFileName(const std::string& fileName);
 
     void setFileComment();
@@ -94,18 +95,21 @@
     void setEntryComment();
 
-    std::list<IniSection>::const_iterator getSectionIT(const char* sectionName) const;
-    std::list<IniSection>::iterator getSectionIT(const char* sectionName);
+    std::list<IniSection>::const_iterator getSectionIT(const std::string& sectionName) const;
+    std::list<IniSection>::iterator getSectionIT(const std::string& sectionName);
 
-    std::list<IniEntry>::const_iterator getEntryIT(const char* entryName, const char* sectionName = NULL) const;
-    std::list<IniEntry>::iterator getEntryIT(const char* entryName, const char* sectionName = NULL);
+    std::list<IniEntry>::const_iterator getEntryIT(const std::string& entryName, const std::string& sectionName = NULL) const;
+    std::list<IniEntry>::iterator getEntryIT(const std::string& entryName, const std::string& sectionName = NULL);
 
   private:
-    char*                            fileName;        //!< The name of the File that was parsed.
-    char*                            comment;         //!< A Comment for the header of this File.
+    std::string                      fileName;        //!< The name of the File that was parsed.
+    std::string                      comment;         //!< A Comment for the header of this File.
     std::list<IniSection>            sections;        //!< a list of all stored Sections of the Parser
     std::list<IniSection>::iterator  currentSection;  //!< the current selected Section
     std::list<IniEntry>::iterator    currentEntry;    //!< the current selected entry (in currentSection)
 
-    std::list<char*>                 commentList;     //!< A list of Comments. (this is for temporary saving of Comments, that are inserted in front of Sections/Entries.)
+    std::list<std::string>           commentList;     //!< A list of Comments. (this is for temporary saving of Comments, that are inserted in front of Sections/Entries.)
+
+
+    static const std::string         emptyString;
 };
 
Index: branches/std/src/lib/parser/tinyxml/tinyxml.h
===================================================================
--- branches/std/src/lib/parser/tinyxml/tinyxml.h	(revision 7202)
+++ branches/std/src/lib/parser/tinyxml/tinyxml.h	(revision 7203)
@@ -26,4 +26,6 @@
 #ifndef TINYXML_INCLUDED
 #define TINYXML_INCLUDED
+
+#define TIXML_USE_STL
 
 #ifdef _MSC_VER
@@ -81,5 +83,5 @@
 		#define TIXML_SNSCANF  snscanf
 	#endif
-#endif	
+#endif
 
 class TiXmlDocument;
@@ -96,5 +98,5 @@
 const int TIXML_PATCH_VERSION = 2;
 
-/*	Internal structure for tracking location of items 
+/*	Internal structure for tracking location of items
 	in the XML file.
 */
@@ -110,6 +112,6 @@
 
 // Only used by Attribute::Query functions
-enum 
-{ 
+enum
+{
 	TIXML_SUCCESS,
 	TIXML_NO_ATTRIBUTE,
@@ -162,5 +164,5 @@
 	/**	All TinyXml classes can print themselves to a filestream.
 		This is a formatted print, and will insert tabs and newlines.
-		
+
 		(For an unformatted stream, use the << operator.)
 	*/
@@ -206,6 +208,6 @@
 	static const int utf8ByteTable[256];
 
-	virtual const char* Parse(	const char* p, 
-								TiXmlParsingData* data, 
+	virtual const char* Parse(	const char* p,
+								TiXmlParsingData* data,
 								TiXmlEncoding encoding /*= TIXML_ENCODING_UNKNOWN */ ) = 0;
 
@@ -245,7 +247,7 @@
 
 	static const char*	SkipWhiteSpace( const char*, TiXmlEncoding encoding );
-	inline static bool	IsWhiteSpace( char c )		
-	{ 
-		return ( isspace( (unsigned char) c ) || c == '\n' || c == '\r' ); 
+	inline static bool	IsWhiteSpace( char c )
+	{
+		return ( isspace( (unsigned char) c ) || c == '\n' || c == '\r' );
 	}
 
@@ -334,5 +336,5 @@
     /// Field containing a generic user pointer
 	void*			userData;
-	
+
 	// None of these methods are reliable for any language except English.
 	// Good for approximation, not great for accuracy.
@@ -386,5 +388,5 @@
 
 public:
-	#ifdef TIXML_USE_STL	
+	#ifdef TIXML_USE_STL
 
 	    /** An input stream operator, for every class. Tolerant of newlines and
@@ -400,5 +402,5 @@
 		    a node to a stream is very well defined. You'll get a nice stream
 		    of output, without any extra whitespace or newlines.
-		    
+
 		    But reading is not as well defined. (As it always is.) If you create
 		    a TiXmlElement (for example) and read that from an input stream,
@@ -408,5 +410,5 @@
 		    A TiXmlDocument will read nodes until it reads a root element, and
 			all the children of that root element.
-	    */	
+	    */
 	    friend std::ostream& operator<< (std::ostream& out, const TiXmlNode& base);
 
@@ -470,9 +472,9 @@
     #ifdef TIXML_USE_STL
 	/// STL std::string form.
-	void SetValue( const std::string& _value )    
-	{	  
+	void SetValue( const std::string& _value )
+	{
 		StringToBuffer buf( _value );
-		SetValue( buf.buffer ? buf.buffer : "" );    	
-	}	
+		SetValue( buf.buffer ? buf.buffer : "" );
+	}
 	#endif
 
@@ -492,5 +494,5 @@
 	TiXmlNode* LastChild()	{ return lastChild; }
 	const TiXmlNode* LastChild( const char * value ) const;			/// The last child of this node matching 'value'. Will be null if there are no children.
-	TiXmlNode* LastChild( const char * value );	
+	TiXmlNode* LastChild( const char * value );
 
     #ifdef TIXML_USE_STL
@@ -649,5 +651,5 @@
 
 	/** Create an exact duplicate of this node and return it. The memory must be deleted
-		by the caller. 
+		by the caller.
 	*/
 	virtual TiXmlNode* Clone() const = 0;
@@ -731,5 +733,5 @@
 	/** QueryIntValue examines the value string. It is an alternative to the
 		IntValue() method with richer error checking.
-		If the value is an integer, it is stored in 'value' and 
+		If the value is an integer, it is stored in 'value' and
 		the call returns TIXML_SUCCESS. If it is not
 		an integer, it returns TIXML_WRONG_TYPE.
@@ -750,14 +752,14 @@
     #ifdef TIXML_USE_STL
 	/// STL std::string form.
-	void SetName( const std::string& _name )	
-	{	
+	void SetName( const std::string& _name )
+	{
 		StringToBuffer buf( _name );
-		SetName ( buf.buffer ? buf.buffer : "error" );	
-	}
-	/// STL std::string form.	
-	void SetValue( const std::string& _value )	
-	{	
+		SetName ( buf.buffer ? buf.buffer : "error" );
+	}
+	/// STL std::string form.
+	void SetValue( const std::string& _value )
+	{
 		StringToBuffer buf( _value );
-		SetValue( buf.buffer ? buf.buffer : "error" );	
+		SetValue( buf.buffer ? buf.buffer : "error" );
 	}
 	#endif
@@ -801,5 +803,5 @@
 /*	A class used to manage a group of attributes.
 	It is only used internally, both by the ELEMENT and the DECLARATION.
-	
+
 	The set can be changed transparent to the Element and Declaration
 	classes that use it, but NOT transparent to the Attribute
@@ -882,9 +884,9 @@
 	/** QueryIntAttribute examines the attribute - it is an alternative to the
 		Attribute() method with richer error checking.
-		If the attribute is an integer, it is stored in 'value' and 
+		If the attribute is an integer, it is stored in 'value' and
 		the call returns TIXML_SUCCESS. If it is not
 		an integer, it returns TIXML_WRONG_TYPE. If the attribute
 		does not exist, then TIXML_NO_ATTRIBUTE is returned.
-	*/	
+	*/
 	int QueryIntAttribute( const char* name, int* _value ) const;
 	/// QueryDoubleAttribute examines the attribute - see QueryIntAttribute().
@@ -913,18 +915,18 @@
 
 	/// STL std::string form.
-	void SetAttribute( const std::string& name, const std::string& _value )	
-	{	
+	void SetAttribute( const std::string& name, const std::string& _value )
+	{
 		StringToBuffer n( name );
 		StringToBuffer v( _value );
 		if ( n.buffer && v.buffer )
-			SetAttribute (n.buffer, v.buffer );	
-	}	
+			SetAttribute (n.buffer, v.buffer );
+	}
 	///< STL std::string form.
-	void SetAttribute( const std::string& name, int _value )	
-	{	
+	void SetAttribute( const std::string& name, int _value )
+	{
 		StringToBuffer n( name );
 		if ( n.buffer )
-			SetAttribute (n.buffer, _value);	
-	}	
+			SetAttribute (n.buffer, _value);
+	}
 	#endif
 
@@ -954,5 +956,5 @@
 		and concise, GetText() is limited compared to getting the TiXmlText child
 		and accessing it directly.
-	
+
 		If the first child of 'this' is a TiXmlText, the GetText()
 		returns the character string of the Text node, else null is returned.
@@ -964,10 +966,10 @@
 		@endverbatim
 
-		'str' will be a pointer to "This is text". 
-		
+		'str' will be a pointer to "This is text".
+
 		Note that this function can be misleading. If the element foo was created from
 		this XML:
 		@verbatim
-		<foo><b>This is text</b></foo> 
+		<foo><b>This is text</b></foo>
 		@endverbatim
 
@@ -975,10 +977,10 @@
 		another element. From this XML:
 		@verbatim
-		<foo>This is <b>text</b></foo> 
+		<foo>This is <b>text</b></foo>
 		@endverbatim
 		GetText() will return "This is ".
 
-		WARNING: GetText() accesses a child node - don't become confused with the 
-				 similarly named TiXmlHandle::Text() and TiXmlNode::ToText() which are 
+		WARNING: GetText() accesses a child node - don't become confused with the
+				 similarly named TiXmlHandle::Text() and TiXmlNode::ToText() which are
 				 safe type casts on the referenced node.
 	*/
@@ -1054,7 +1056,7 @@
 
 
-/** XML text. A text node can have 2 ways to output the next. "normal" output 
+/** XML text. A text node can have 2 ways to output the next. "normal" output
 	and CDATA. It will default to the mode it was parsed from the XML file and
-	you generally want to leave it alone, but you can change the output mode with 
+	you generally want to leave it alone, but you can change the output mode with
 	SetCDATA() and query it with CDATA().
 */
@@ -1063,5 +1065,5 @@
 	friend class TiXmlElement;
 public:
-	/** Constructor for text element. By default, it is treated as 
+	/** Constructor for text element. By default, it is treated as
 		normal, encoded text. If you want it be output as a CDATA text
 		element, set the parameter _cdata to 'true'
@@ -1279,5 +1281,5 @@
 		- The ErrorDesc() method will return the name of the error. (very useful)
 		- The ErrorRow() and ErrorCol() will return the location of the error (if known)
-	*/	
+	*/
 	bool Error() const						{ return error; }
 
@@ -1290,5 +1292,5 @@
 	int ErrorId()	const				{ return errorId; }
 
-	/** Returns the location (if known) of the error. The first column is column 1, 
+	/** Returns the location (if known) of the error. The first column is column 1,
 		and the first row is row 1. A value of 0 means the row and column wasn't applicable
 		(memory errors, for example, have no row/column) or the parser lost the error. (An
@@ -1303,5 +1305,5 @@
 		to report the correct values for row and column. It does not change the output
 		or input in any way.
-		
+
 		By calling this method, with a tab size
 		greater than 0, the row and column of each node and attribute is stored
@@ -1331,9 +1333,9 @@
 		state is automatically cleared if you Parse a new XML block.
 	*/
-	void ClearError()						{	error = false; 
-												errorId = 0; 
-												errorDesc = ""; 
-												errorLocation.row = errorLocation.col = 0; 
-												//errorLocation.last = 0; 
+	void ClearError()						{	error = false;
+												errorId = 0;
+												errorDesc = "";
+												errorLocation.row = errorLocation.col = 0;
+												//errorLocation.last = 0;
 											}
 
@@ -1381,5 +1383,5 @@
 	@endverbatim
 
-	Assuming you want the value of "attributeB" in the 2nd "Child" element, it's very 
+	Assuming you want the value of "attributeB" in the 2nd "Child" element, it's very
 	easy to write a *lot* of code that looks like:
 
@@ -1401,5 +1403,5 @@
 
 	And that doesn't even cover "else" cases. TiXmlHandle addresses the verbosity
-	of such code. A TiXmlHandle checks for null	pointers so it is perfectly safe 
+	of such code. A TiXmlHandle checks for null	pointers so it is perfectly safe
 	and correct to use:
 
@@ -1422,5 +1424,5 @@
 
 	@verbatim
-	int i=0; 
+	int i=0;
 	while ( true )
 	{
@@ -1433,6 +1435,6 @@
 	@endverbatim
 
-	It seems reasonable, but it is in fact two embedded while loops. The Child method is 
-	a linear walk to find the element, so this code would iterate much more than it needs 
+	It seems reasonable, but it is in fact two embedded while loops. The Child method is
+	a linear walk to find the element, so this code would iterate much more than it needs
 	to. Instead, prefer:
 
@@ -1464,18 +1466,18 @@
 	TiXmlHandle FirstChildElement( const char * value ) const;
 
-	/** Return a handle to the "index" child with the given name. 
+	/** Return a handle to the "index" child with the given name.
 		The first child is 0, the second 1, etc.
 	*/
 	TiXmlHandle Child( const char* value, int index ) const;
-	/** Return a handle to the "index" child. 
+	/** Return a handle to the "index" child.
 		The first child is 0, the second 1, etc.
 	*/
 	TiXmlHandle Child( int index ) const;
-	/** Return a handle to the "index" child element with the given name. 
+	/** Return a handle to the "index" child element with the given name.
 		The first child element is 0, the second 1, etc. Note that only TiXmlElements
 		are indexed: other types are not counted.
 	*/
 	TiXmlHandle ChildElement( const char* value, int index ) const;
-	/** Return a handle to the "index" child element. 
+	/** Return a handle to the "index" child element.
 		The first child element is 0, the second 1, etc. Note that only TiXmlElements
 		are indexed: other types are not counted.
@@ -1492,5 +1494,5 @@
 
 	/// Return the handle as a TiXmlNode. This may return null.
-	TiXmlNode* Node() const			{ return node; } 
+	TiXmlNode* Node() const			{ return node; }
 	/// Return the handle as a TiXmlElement. This may return null.
 	TiXmlElement* Element() const	{ return ( ( node && node->ToElement() ) ? node->ToElement() : 0 ); }
Index: branches/std/src/lib/particles/spark_particles.cc
===================================================================
--- branches/std/src/lib/particles/spark_particles.cc	(revision 7202)
+++ branches/std/src/lib/particles/spark_particles.cc	(revision 7203)
@@ -68,6 +68,4 @@
 {
   this->setClassID(CL_SPARK_PARTICLES, "SparkParticles");
-
-  this->material = NULL;
 }
 
Index: branches/std/src/lib/sound/ogg_player.cc
===================================================================
--- branches/std/src/lib/sound/ogg_player.cc	(revision 7202)
+++ branches/std/src/lib/sound/ogg_player.cc	(revision 7203)
@@ -31,5 +31,5 @@
  * @param fileName the file to load
  */
-OggPlayer::OggPlayer(const char* fileName)
+OggPlayer::OggPlayer(const std::string& fileName)
 {
   this->setClassID(CL_SOUND_OGG_PLAYER, "OggPlayer");
@@ -40,5 +40,5 @@
   this->buffers[1] = 0;
 
-  if (fileName != NULL)
+  if (!fileName.empty())
   {
     if (this->open(fileName))
@@ -56,5 +56,5 @@
  * @param fileName the file to open
  */
-bool OggPlayer::open(const char* fileName)
+bool OggPlayer::open(const std::string& fileName)
 {
   if (this->buffers[0] == 0)
@@ -72,5 +72,5 @@
   int result;
 
-  if(!(oggFile = fopen(fileName, "rb")))
+  if(!(oggFile = fopen(fileName.c_str(), "rb")))
   {
     PRINTF(2)("Could not open Ogg file.");
Index: branches/std/src/lib/sound/ogg_player.h
===================================================================
--- branches/std/src/lib/sound/ogg_player.h	(revision 7202)
+++ branches/std/src/lib/sound/ogg_player.h	(revision 7203)
@@ -27,8 +27,8 @@
 {
 public:
-  OggPlayer(const char* fileName = NULL);
+  OggPlayer(const std::string& fileName = NULL);
   virtual ~OggPlayer();
 
-  bool open(const char* fileName);
+  bool open(const std::string& fileName);
   void release();
   void debug();
Index: branches/std/src/lib/sound/sound_buffer.cc
===================================================================
--- branches/std/src/lib/sound/sound_buffer.cc	(revision 7202)
+++ branches/std/src/lib/sound/sound_buffer.cc	(revision 7203)
@@ -32,5 +32,5 @@
  * @param fileName The name of the File
  */
-SoundBuffer::SoundBuffer(const char* fileName)
+SoundBuffer::SoundBuffer(const std::string& fileName)
 {
   this->setClassID(CL_SOUND_BUFFER, "SoundBuffer");
@@ -54,5 +54,5 @@
  * @returns true on success.
  */
-bool SoundBuffer::loadWAV(const char* fileName)
+bool SoundBuffer::loadWAV(const std::string& fileName)
 {
   SDL_AudioSpec wavSpec;
@@ -61,7 +61,7 @@
 
   /* Load the WAV */
-  if( SDL_LoadWAV(fileName, &wavSpec, &wavBuffer, &wavLength) == NULL)
+  if( SDL_LoadWAV(fileName.c_str(), &wavSpec, &wavBuffer, &wavLength) == NULL)
   {
-    PRINTF(2)("Could not open %s: %s\n", fileName, SDL_GetError());
+    PRINTF(2)("Could not open %s: %s\n", fileName.c_str(), SDL_GetError());
     return false;
   }
Index: branches/std/src/lib/sound/sound_buffer.h
===================================================================
--- branches/std/src/lib/sound/sound_buffer.h	(revision 7202)
+++ branches/std/src/lib/sound/sound_buffer.h	(revision 7203)
@@ -17,8 +17,8 @@
 {
   public:
-    SoundBuffer(const char* fileName);
+    SoundBuffer(const std::string& fileName);
     virtual ~SoundBuffer();
 
-    bool loadWAV(const char* fileName);
+    bool loadWAV(const std::string& fileName);
 
     /** @returns the ID of the buffer used in this SoundBuffer */
Index: branches/std/src/lib/sound/sound_engine.cc
===================================================================
--- branches/std/src/lib/sound/sound_engine.cc	(revision 7202)
+++ branches/std/src/lib/sound/sound_engine.cc	(revision 7203)
@@ -99,12 +99,12 @@
 void SoundEngine::loadSettings(IniParser* iniParser)
 {
-  const char* channels = iniParser->getVar(CONFIG_NAME_AUDIO_CHANNELS, CONFIG_SECTION_AUDIO, "32");
-  this->maxSourceCount = atoi(channels);
-
-  const char* effectsVolume = iniParser->getVar(CONFIG_NAME_EFFECTS_VOLUME, CONFIG_SECTION_AUDIO, "80");
-  this->effectsVolume = atof(effectsVolume)/100.0;
-
-  const char* musicVolume = iniParser->getVar(CONFIG_NAME_MUSIC_VOLUME, CONFIG_SECTION_AUDIO, "75");
-  this->musicVolume = atof(musicVolume)/100.0;
+  MultiType channels = iniParser->getVar(CONFIG_NAME_AUDIO_CHANNELS, CONFIG_SECTION_AUDIO, "32");
+  this->maxSourceCount = channels.getInt();
+
+  MultiType effectsVolume = iniParser->getVar(CONFIG_NAME_EFFECTS_VOLUME, CONFIG_SECTION_AUDIO, "80");
+  this->effectsVolume = effectsVolume.getFloat()/100.0;
+
+  MultiType musicVolume = iniParser->getVar(CONFIG_NAME_MUSIC_VOLUME, CONFIG_SECTION_AUDIO, "75");
+  this->musicVolume = musicVolume.getFloat()/100.0;
 }
 
Index: branches/std/src/lib/util/executor/executor.cc
===================================================================
--- branches/std/src/lib/util/executor/executor.cc	(revision 7202)
+++ branches/std/src/lib/util/executor/executor.cc	(revision 7203)
@@ -105,16 +105,9 @@
   value[4] = &value4;
 
-  printf("%s ::: paramCount: %d\n", this->getName(), this->paramCount);
   for (unsigned int i = 0; i < this->paramCount; i++)
   {
     if (*value[i] != MT_NULL)
     {
-      printf("1:::: %d : %s \n",i, MultiType::MultiTypeToString(this->defaultValue[i].getType()));
-
-      this->defaultValue[i].debug();
-      //this->defaultValue[i].setValueOf(*value[i]);
-      //printf("2::::%s\n", MultiType::MultiTypeToString(this->defaultValue[i].getType()));
-      //this->defaultValue[i].debug();
-    //this->defaultValue[i].setValueOf(*value[i]);
+      this->defaultValue[i].setValueOf(*value[i]);
     }
   }
Index: branches/std/src/lib/util/executor/executor.h
===================================================================
--- branches/std/src/lib/util/executor/executor.h	(revision 7202)
+++ branches/std/src/lib/util/executor/executor.h	(revision 7203)
@@ -87,4 +87,6 @@
 #define   l_FLOAT_DEFGRAB(i)        this->defaultValue[i].getFloat()
 //! where to chek for default STRING values
+#define   l_STRING_DEFGRAB(i)       this->defaultValue[i].getString()
+//! where to chek for default CSTRING values
 #define   l_CSTRING_DEFGRAB(i)      this->defaultValue[i].getCString()
 
@@ -268,6 +270,6 @@
     virtual void execute (BaseObject* object, const void* parameters = NULL)
     {
-      SubString sub((const char*) parameters, " \n\t,", '\\');
-      printf("%s :: %s\n", this->getName(), (const char*) parameters);
+      SubString sub(((const std::string*) parameters)->c_str(), " \n\t,", '\\');
+      printf("%s :: %s\n", this->getName(), ((const std::string*) parameters)->c_str());
 //! FUNCTOR_LIST is the List of Executive Functions
 #define FUNCTOR_LIST(x) ExecutorExecute ## x
Index: branches/std/src/lib/util/executor/functor_list.h
===================================================================
--- branches/std/src/lib/util/executor/functor_list.h	(revision 7202)
+++ branches/std/src/lib/util/executor/functor_list.h	(revision 7203)
@@ -75,6 +75,6 @@
 
 #define l_CSTRING_TYPE     const char*          //!< The type of a STRING
-#define l_CSTRING_FUNC     isString             //!< The function to parse a STRING
-#define l_CSTRING_NAME     "string"             //!< The name of a STRING
+#define l_CSTRING_FUNC     isCString            //!< The function to parse a STRING
+#define l_CSTRING_NAME     "cstring"            //!< The name of a STRING
 #define l_CSTRING_PARAM    MT_STRING            //!< the type of the parameter STRING
 #define l_CSTRING_DEFAULT  ""                   //!< a default Value for an STRING
@@ -98,12 +98,22 @@
 
   FUNCTOR_LIST(0)();
+  //! makes functions with one cstring
+  FUNCTOR_LIST(1)(l_CSTRING);
+  //! makes functions with two cstrings
+  FUNCTOR_LIST(2)(l_CSTRING, l_CSTRING);
+  //! makes functions with three cstrings
+  FUNCTOR_LIST(3)(l_CSTRING, l_CSTRING, l_CSTRING);
+  //! makes functions with four cstrings
+  FUNCTOR_LIST(4)(l_CSTRING, l_CSTRING, l_CSTRING, l_CSTRING);
+
   //! makes functions with one string
-  FUNCTOR_LIST(1)(l_CSTRING);
+  FUNCTOR_LIST(1)(l_STRING);
   //! makes functions with two strings
-  FUNCTOR_LIST(2)(l_CSTRING, l_CSTRING);
+  FUNCTOR_LIST(2)(l_STRING, l_STRING);
   //! makes functions with three strings
-  FUNCTOR_LIST(3)(l_CSTRING, l_CSTRING, l_CSTRING);
+  FUNCTOR_LIST(3)(l_STRING, l_STRING, l_STRING);
   //! makes functions with four strings
-  FUNCTOR_LIST(4)(l_CSTRING, l_CSTRING, l_CSTRING, l_CSTRING);
+  FUNCTOR_LIST(4)(l_STRING, l_STRING, l_STRING, l_STRING);
+
 
   //! makes functions with one bool
Index: branches/std/src/lib/util/helper_functions.cc
===================================================================
--- branches/std/src/lib/util/helper_functions.cc	(revision 7202)
+++ branches/std/src/lib/util/helper_functions.cc	(revision 7203)
@@ -22,5 +22,5 @@
 
 /**
- * checks if the input was a bool
+ * @brief checks if the input was a bool
  * @param BOOL a String that holds a bool: must be one of those: 1,0,true,false(case-insensitive)
  * @param defaultValue a default value that is set, if BOOL is corrupt
@@ -42,5 +42,5 @@
 
 /**
- * checks if the input was a int
+ * @brief checks if the input was a int
  * @param INT a String that holds an int.
  * @param defaultValue a default value that is set, if INT is corrupt
@@ -63,5 +63,5 @@
 
 /**
- * checks if the input was a float
+ * @brief checks if the input was a float
  * @param FLOAT a String that holds an float.
  * @param defaultValue a default value that is set, if FLOAT is corrupt
@@ -83,10 +83,10 @@
 
 /**
- * checks if the input was a string
+ * @brief checks if the input was a string
  * @param STING a String(char-array) that holds an string.
  * @param defaultValue a default value that is set, if STRING is corrupt
  * @return returns the contained string (char-array), if STRING was correct otherwise defaultValue
  */
-const char* isString(const char* STRING, const char* defaultValue)
+const char* isCString(const char* STRING, const char* defaultValue)
 {
   if (STRING != NULL && strlen(STRING) > 0)
@@ -95,2 +95,45 @@
     return defaultValue;
 }
+
+/**
+ * @brief checks if the input was a string
+ * @param STING a String(char-array) that holds an string.
+ * @param defaultValue a default value that is set, if STRING is corrupt
+ * @return returns the contained string (char-array), if STRING was correct otherwise defaultValue
+ */
+std::string isString(const char* STRING, const std::string& defaultValue)
+{
+  if (STRING != NULL && strlen(STRING) > 0)
+    return STRING;
+  else
+    return defaultValue;
+}
+
+
+/**
+ * @brief compares two strings without ignoring the case
+ * @param s1 first string
+ * @param s2 second string
+ */
+int nocase_cmp(const std::string& s1, const std::string& s2)
+{
+  std::string::const_iterator it1=s1.begin();
+  std::string::const_iterator it2=s2.begin();
+
+  //stop when either string's end has been reached
+  while ( (it1!=s1.end()) && (it2!=s2.end()) )
+  {
+    if(::toupper(*it1) != ::toupper(*it2)) //letters differ?
+     // return -1 to indicate smaller than, 1 otherwise
+      return (::toupper(*it1)  < ::toupper(*it2)) ? -1 : 1;
+    //proceed to the next character in each string
+    ++it1;
+    ++it2;
+  }
+  size_t size1=s1.size(), size2=s2.size();// cache lengths
+   //return -1,0 or 1 according to strings' lengths
+  if (size1==size2)
+    return 0;
+  return (size1<size2) ? -1 : 1;
+}
+
Index: branches/std/src/lib/util/helper_functions.h
===================================================================
--- branches/std/src/lib/util/helper_functions.h	(revision 7202)
+++ branches/std/src/lib/util/helper_functions.h	(revision 7203)
@@ -6,4 +6,6 @@
 #ifndef _HELPER_FUNCTIONS_H
 #define _HELPER_FUNCTIONS_H
+
+#include <string>
 
 // FORWARD DECLARATION
@@ -15,5 +17,10 @@
 int           isInt(const char* INT, int defaultValue);
 float         isFloat(const char* FLOAT, float defaultValue);
-const char*   isString(const char* STRING, const char* defaultValue);
+const char*   isCString(const char* STRING, const char* defaultValue);
+std::string   isString(const char* STRING, const std::string& defaultValue);
+
+
+int           nocase_cmp(const std::string& s1, const std::string& s2);
+
 
 #endif /* _HELPER_FUNCTIONS_H */
Index: branches/std/src/lib/util/loading/game_loader.cc
===================================================================
--- branches/std/src/lib/util/loading/game_loader.cc	(revision 7202)
+++ branches/std/src/lib/util/loading/game_loader.cc	(revision 7203)
@@ -86,12 +86,11 @@
  * this will interprete the map/campaign files and recursivly load a tree of worlds/campaigns
  */
-ErrorMessage GameLoader::loadCampaign(const char* fileName)
+ErrorMessage GameLoader::loadCampaign(const std::string& fileName)
 {
   ErrorMessage errorCode;
-  char* campaignName = ResourceManager::getFullName(fileName);
-  if (campaignName)
+  std::string campaignName = ResourceManager::getFullName(fileName);
+  if (!campaignName.empty())
     {
       this->currentCampaign = this->fileToCampaign(campaignName);
-      delete[] campaignName;
     }
 }
@@ -105,12 +104,11 @@
  * this will interprete the map/campaign files and recursivly load a tree of worlds/campaigns
  */
-ErrorMessage GameLoader::loadNetworkCampaign(const char* fileName)
+ErrorMessage GameLoader::loadNetworkCampaign(const std::string& fileName)
 {
   ErrorMessage errorCode;
-  char* campaignName = ResourceManager::getFullName(fileName);
-  if (campaignName)
+  std::string campaignName = ResourceManager::getFullName(fileName);
+  if (!campaignName.empty())
   {
     this->currentCampaign = this->fileToCampaign(campaignName);
-    delete[] campaignName;
   }
 }
@@ -220,5 +218,5 @@
  * this will interprete the map/campaign files and recursivly load a tree of worlds/campaigns
  */
-Campaign* GameLoader::fileToCampaign(const char* fileName)
+Campaign* GameLoader::fileToCampaign(const std::string& fileName)
 {
   /* do not entirely load the campaign. just the current world
@@ -227,5 +225,5 @@
   */
 
-  if( fileName == NULL)
+  if( fileName.empty())
     {
       PRINTF(2)("No filename specified for loading");
@@ -233,16 +231,15 @@
     }
 
-  TiXmlDocument* XMLDoc = new TiXmlDocument( fileName);
+  TiXmlDocument XMLDoc(fileName);
   // load the campaign document
-  if( !XMLDoc->LoadFile())
+  if( !XMLDoc.LoadFile(fileName))
     {
       // report an error
-      PRINTF(1)("Could not load XML File %s: %s @ %d:%d\n", fileName, XMLDoc->ErrorDesc(), XMLDoc->ErrorRow(), XMLDoc->ErrorCol());
-      delete XMLDoc;
+      PRINTF(1)("Could not load XML File %s: %s @ %d:%d\n", fileName.c_str(), XMLDoc.ErrorDesc(), XMLDoc.ErrorRow(), XMLDoc.ErrorCol());
       return NULL;
     }
 
   // check basic validity
-  TiXmlElement* root = XMLDoc->RootElement();
+  TiXmlElement* root = XMLDoc.RootElement();
   assert( root != NULL);
 
@@ -251,15 +248,9 @@
       // report an error
       PRINTF(2)("Specified XML File is not an orxonox campaign file (Campaign element missing)\n");
-      delete XMLDoc;
       return NULL;
     }
 
   // construct campaign
-  Campaign* c = new Campaign( root);
-
-  // free the XML data
-  delete XMLDoc;
-
-  return c;
+  return new Campaign( root);
 }
 
Index: branches/std/src/lib/util/loading/game_loader.h
===================================================================
--- branches/std/src/lib/util/loading/game_loader.h	(revision 7202)
+++ branches/std/src/lib/util/loading/game_loader.h	(revision 7203)
@@ -44,7 +44,7 @@
   static GameLoader* getInstance() { if(singletonRef == NULL) singletonRef = new GameLoader(); return singletonRef; }
 
-  ErrorMessage loadCampaign(const char* name);
+  ErrorMessage loadCampaign(const std::string& name);
   ErrorMessage loadDebugCampaign(Uint32 campaignID);
-  ErrorMessage loadNetworkCampaign(const char* fileName);
+  ErrorMessage loadNetworkCampaign(const std::string& fileName);
 
   ErrorMessage init();
@@ -62,5 +62,5 @@
   GameLoader ();
 
-  Campaign* fileToCampaign(const char* name);
+  Campaign* fileToCampaign(const std::string& name);
 
 
Index: branches/std/src/lib/util/loading/load_param.cc
===================================================================
--- branches/std/src/lib/util/loading/load_param.cc	(revision 7202)
+++ branches/std/src/lib/util/loading/load_param.cc	(revision 7203)
@@ -28,7 +28,7 @@
  * @param executor the Executor, that executes the loading procedure.
  */
-CLoadParam::CLoadParam(const TiXmlElement* root, const char* paramName, BaseObject* object, const Executor& executor, bool inLoadCycle)
-{
-  this->paramName = paramName;
+CLoadParam::CLoadParam(const TiXmlElement* root, const std::string& paramName, BaseObject* object, const Executor& executor, bool inLoadCycle)
+  :  paramName(paramName), object(object)
+{
   this->object = object;
   this->inLoadCycle = inLoadCycle;
@@ -37,6 +37,5 @@
   if (likely(!inLoadCycle))
     this->loadElem = grabParameterElement(root, paramName);
-  //this->loadString = grabParameter(root, paramName);
-  else if (!strcmp(root->Value(), paramName))
+  else if (paramName == root->Value())
     this->loadElem = (TiXmlElement*)root->FirstChild();
   else
@@ -46,6 +45,6 @@
   this->executor = executor.clone();
 
-  if (this->executor)
-    this->executor->setName(paramName);
+  //if (this->executor)
+  //  this->executor->setName(paramName);
 }
 
@@ -60,14 +59,13 @@
   if (likely(this->executor != NULL))
   {
+    std::string loadString;
     if (this->loadElem != NULL &&  this->loadElem->ToText())
-      this->loadString = this->loadElem->Value();
-    else
-      this->loadString = NULL;
+      loadString = this->loadElem->Value();
     if (likely(this->object != NULL) &&
-        ( this->loadString != NULL ||
+        ( !loadString.empty() ||
           ((this->executor->getType() & Executor_NoLoadString) == Executor_NoLoadString)))
     {
-      PRINTF(4)("Loading '%s' with Parameters '%s' onto: '%s'(%s)\n", this->paramName, this->loadString, this->object->getName(), this->object->getClassName());
-      this->executor->execute(this->object, this->loadString);
+      PRINTF(4)("Loading '%s' with Parameters '%s' onto: '%s'(%s)\n", this->paramName, loadString, this->object->getName(), this->object->getClassName());
+      this->executor->execute(this->object, &loadString);
     }
     delete this->executor;
@@ -99,7 +97,7 @@
  * @returns a pointer to itself.
 */
-CLoadParam& CLoadParam::describe(const char* descriptionText)
-{
-  if (LoadClassDescription::parametersDescription && this->paramDesc && !this->paramDesc->getDescription())
+CLoadParam& CLoadParam::describe(const std::string& descriptionText)
+{
+  if (LoadClassDescription::parametersDescription && this->paramDesc && this->paramDesc->getDescription().empty())
   {
     this->paramDesc->setDescription(descriptionText);
@@ -230,12 +228,11 @@
  * @returns the Value of the parameter if found, NULL otherwise
 */
-const char* grabParameter(const TiXmlElement* root, const char* parameterName)
+std::string grabParameter(const TiXmlElement* root, const std::string& parameterName)
 {
   const TiXmlElement* element;
   const TiXmlNode* node;
 
-  if (root == NULL || parameterName == NULL)
+  if (root == NULL)
     return NULL;
-  assert( parameterName != NULL);
 
   element = root->FirstChildElement( parameterName);
@@ -256,12 +253,11 @@
  * @returns the Element of the parameter if found, NULL otherwise
  */
-const TiXmlElement* grabParameterElement(const TiXmlElement* root, const char* parameterName)
+const TiXmlElement* grabParameterElement(const TiXmlElement* root, const std::string& parameterName)
 {
   const TiXmlElement* element;
   const TiXmlNode* node;
 
-  if (root == NULL || parameterName == NULL)
+  if (root == NULL)
     return NULL;
-  assert( parameterName != NULL);
 
   element = root->FirstChildElement( parameterName);
Index: branches/std/src/lib/util/loading/load_param.h
===================================================================
--- branches/std/src/lib/util/loading/load_param.h	(revision 7202)
+++ branches/std/src/lib/util/loading/load_param.h	(revision 7203)
@@ -87,12 +87,12 @@
 {
   public:
-    CLoadParam(const TiXmlElement* root, const char* paramName, BaseObject* object, const Executor& executor, bool inLoadCycle = false);
+    CLoadParam(const TiXmlElement* root, const std::string& paramName, BaseObject* object, const Executor& executor, bool inLoadCycle = false);
     virtual ~CLoadParam();
 
-    CLoadParam& describe(const char* descriptionText);
+    CLoadParam& describe(const std::string& descriptionText);
     CLoadParam& defaultValues(const MultiType& value0 = MT_NULL, const MultiType& value1 = MT_NULL,
                               const MultiType& value2 = MT_NULL, const MultiType& value3 = MT_NULL,
                               const MultiType& value4 = MT_NULL);
-    CLoadParam& attribute(const char* attributeName, const Executor& executor);
+    CLoadParam& attribute(const std::string& attributeName, const Executor& executor);
 
 
@@ -101,10 +101,9 @@
     Executor*                executor;
     BaseObject*              object;
-    const char*              paramName;
+    const std::string        paramName;
 
     LoadClassDescription*    classDesc;            //!< The LoadClassDescription of this CLoadParameter
     LoadParamDescription*    paramDesc;            //!< The LoadParameterDescription of this LoadParameter
     const TiXmlElement*      loadElem;             //!< The Element to load.
-    const char*              loadString;           //!< The string loaded by this LoadParam
     const void*              pointerToParam;       //!< A Pointer to a Parameter.
 
@@ -114,6 +113,6 @@
 // helper function
 
-const char* grabParameter(const TiXmlElement* root, const char* parameterName);
-const TiXmlElement* grabParameterElement(const TiXmlElement* root, const char* parameterName);
+std::string grabParameter(const TiXmlElement* root, const std::string& parameterName);
+const TiXmlElement* grabParameterElement(const TiXmlElement* root, const std::string& parameterName);
 
 #endif /* _LOAD_PARAM_H */
Index: branches/std/src/lib/util/loading/load_param_description.cc
===================================================================
--- branches/std/src/lib/util/loading/load_param_description.cc	(revision 7202)
+++ branches/std/src/lib/util/loading/load_param_description.cc	(revision 7203)
@@ -22,11 +22,9 @@
  * @param paramName the name of the parameter to load
  */
-LoadParamDescription::LoadParamDescription(const char* paramName)
+LoadParamDescription::LoadParamDescription(const std::string& paramName)
 {
   this->types = NULL;
-  this->description = NULL;
   this->defaultValues = NULL;
-  this->paramName = new char[strlen(paramName)+1];
-  strcpy(this->paramName, paramName);
+  this->paramName = paramName;
 }
 
@@ -46,6 +44,4 @@
   delete[] this->types;
   delete[] this->defaultValues;
-  delete[] this->paramName;
-  delete[] this->description;
 }
 
@@ -53,8 +49,7 @@
  * @param descriptionText The text to set as a description for this Parameter
  */
-void LoadParamDescription::setDescription(const char* descriptionText)
-{
-  this->description = new char[strlen(descriptionText)+1];
-  strcpy(this->description, descriptionText);
+void LoadParamDescription::setDescription(const std::string& descriptionText)
+{
+  this->description = descriptionText;
 }
 
@@ -64,5 +59,5 @@
 void LoadParamDescription::print() const
 {
-  PRINT(3)(" <%s>", this->paramName);
+  PRINT(3)(" <%s>", this->paramName.c_str());
   for (int i = 0; i < this->paramCount; i++)
   {
@@ -101,7 +96,7 @@
 //     }
   }
-  PRINT(3)("</%s>", this->paramName);
-  if (this->description)
-    PRINT(3)(" -- %s", this->description);
+  PRINT(3)("</%s>", this->paramName.c_str());
+  if (!this->description.empty())
+    PRINT(3)(" -- %s", this->description.c_str());
   // default values
   if (this->paramCount > 0)
@@ -213,5 +208,5 @@
   while (it != this->paramList.end())
   {
-    if (!strcmp((*it)->paramName, paramName))
+    if ((*it)->paramName == paramName)
     {
       return NULL;
Index: branches/std/src/lib/util/loading/load_param_description.h
===================================================================
--- branches/std/src/lib/util/loading/load_param_description.h	(revision 7202)
+++ branches/std/src/lib/util/loading/load_param_description.h	(revision 7203)
@@ -36,19 +36,19 @@
   friend class LoadParam;
   friend class LoadClassDescription;
- public:
-  LoadParamDescription(const char* paramName);
+public:
+  LoadParamDescription(const std::string& paramName);
   ~LoadParamDescription();
 
-  void setDescription(const char* descriptionText);
+  void setDescription(const std::string& descriptionText);
   /** @returns the descriptionString */
-  const char* getDescription() { return this->description; };
+  const std::string& getDescription() { return this->description; };
 
   void print() const;
 
- private:
-  char*         paramName;             //!< The name of the parameter.
+private:
+  std::string   paramName;             //!< The name of the parameter.
   int           paramCount;            //!< The count of parameters.
   int*          types;                 //!< What kind of parameters does this function take ??
-  char*         description;           //!< A longer description about this function.
+  std::string   description;           //!< A longer description about this function.
   char**        defaultValues;         //!< The 'Default Values'. @TODO MAKE THIS A MULTITYPE
 };
@@ -58,5 +58,5 @@
 {
   friend class CLoadParam;
- public:
+public:
   LoadClassDescription(const char* className);
   ~LoadClassDescription();
@@ -69,7 +69,7 @@
   static void printAll(const char* fileName = NULL);
   static std::list<const char*> searchClassWithShort(const char* classNameBegin);
-//  static const LoadParamDescription* getClass(const char* className);
+  //  static const LoadParamDescription* getClass(const char* className);
 
- private:
+private:
   static bool                              parametersDescription;  //!< if parameter-description should be enabled.
   static std::list<LoadClassDescription*>* classList;              //!< a list, that stores all the loadable classes. (after one instance has been loaded)
Index: branches/std/src/lib/util/loading/resource_manager.cc
===================================================================
--- branches/std/src/lib/util/loading/resource_manager.cc	(revision 7202)
+++ branches/std/src/lib/util/loading/resource_manager.cc	(revision 7203)
@@ -60,8 +60,6 @@
 
   this->dataDir = new char[3];
-  strcpy(this->dataDir, "./");
+  this->dataDir = "./";
   this->tryDataDir("./data");
-
-  this->_cwd = NULL;
 }
 
@@ -80,14 +78,4 @@
     PRINTF(1)("Not removed all Resources, since there are still %d resources registered\n", this->resourceList.size());
 
-  // deleting the Directorie Lists
-  while (!this->imageDirs.empty())
-  {
-    delete[] this->imageDirs.back();
-    this->imageDirs.pop_back();
-  }
-
-  delete[] this->dataDir;
-  if (this->_cwd)
-    delete[] this->_cwd;
   ResourceManager::singletonRef = NULL;
 }
@@ -97,29 +85,23 @@
  * @param dataDir the DataDirectory.
  */
-bool ResourceManager::setDataDir(const char* dataDir)
-{
-  char* realDir = ResourceManager::homeDirCheck(dataDir);
+bool ResourceManager::setDataDir(const std::string& dataDir)
+{
+  std::string realDir = ResourceManager::homeDirCheck(dataDir);
   if (isDir(realDir))
   {
-    delete[] this->dataDir;
-    if (dataDir[strlen(dataDir)-1] == '/' || dataDir[strlen(dataDir)-1] == '\\')
+    if (dataDir[dataDir.size()-1] == '/' || dataDir[dataDir.size()-1] == '\\')
     {
-      this->dataDir = new char[strlen(realDir)+1];
-      strcpy(this->dataDir, realDir);
+      this->dataDir = realDir;
     }
     else
     {
-      this->dataDir = new char[strlen(realDir)+2];
-      strcpy(this->dataDir, realDir);
-      this->dataDir[strlen(realDir)] = '/';
-      this->dataDir[strlen(realDir)+1] = '\0';
+      this->dataDir = realDir;
+      this->dataDir += '/';
     }
-    delete[] realDir;
     return true;
   }
   else
   {
-    PRINTF(1)("%s is not a Directory, and can not be the Data Directory, leaving as %s \n", realDir, this->dataDir);
-    delete[] realDir;
+    PRINTF(1)("%s is not a Directory, and can not be the Data Directory, leaving as %s \n", realDir.c_str(), this->dataDir.c_str());
     return false;
   }
@@ -132,26 +114,20 @@
  * this is essentially the same as setDataDir, but it ommits the error-message
  */
-bool ResourceManager::tryDataDir(const char* dataDir)
-{
-  char* realDir = ResourceManager::homeDirCheck(dataDir);
+bool ResourceManager::tryDataDir(const std::string& dataDir)
+{
+  std::string realDir = ResourceManager::homeDirCheck(dataDir);
   if (isDir(realDir))
   {
-    delete[] this->dataDir;
-    if (dataDir[strlen(dataDir)-1] == '/' || dataDir[strlen(dataDir)-1] == '\\')
+    if (dataDir[dataDir.size()-1] == '/' || dataDir[dataDir.size()-1] == '\\')
     {
-      this->dataDir = new char[strlen(realDir)+1];
-      strcpy(this->dataDir, realDir);
+      this->dataDir = realDir;
     }
     else
     {
-      this->dataDir = new char[strlen(realDir)+2];
-      strcpy(this->dataDir, realDir);
-      this->dataDir[strlen(realDir)] = '/';
-      this->dataDir[strlen(realDir)+1] = '\0';
+      this->dataDir = realDir;
+      this->dataDir += '/';
     }
-    delete[] realDir;
     return true;
   }
-  delete[] realDir;
   return false;
 }
@@ -162,17 +138,15 @@
  * @param fileInside is iniside of the given directory.
 */
-bool ResourceManager::verifyDataDir(const char* fileInside)
+bool ResourceManager::verifyDataDir(const std::string& fileInside)
 {
   bool retVal;
   if (!isDir(this->dataDir))
   {
-    PRINTF(1)("%s is not a directory\n", this->dataDir);
-    return false;
-  }
-
-  char* testFile = new char[strlen(this->dataDir)+strlen(fileInside)+1];
-  sprintf(testFile, "%s%s", this->dataDir, fileInside);
+    PRINTF(1)("%s is not a directory\n", this->dataDir.c_str());
+    return false;
+  }
+
+  std::string testFile = this->dataDir + fileInside;
   retVal = isFile(testFile);
-  delete[] testFile;
   return retVal;
 }
@@ -185,21 +159,15 @@
    false otherwise
 */
-bool ResourceManager::addImageDir(const char* imageDir)
-{
-  if (imageDir == NULL)
-    return false;
-
-  char* newDir;
-  if (imageDir[strlen(imageDir)-1] == '/' || imageDir[strlen(imageDir)-1] == '\\')
-  {
-    newDir = new char[strlen(imageDir)+1];
-    strcpy(newDir, imageDir);
-  }
-  else
-  {
-    newDir = new char[strlen(imageDir)+2];
-    strcpy(newDir, imageDir);
-    newDir[strlen(imageDir)] = '/';
-    newDir[strlen(imageDir)+1] = '\0';
+bool ResourceManager::addImageDir(const std::string& imageDir)
+{
+  std::string newDir;
+  if (imageDir[imageDir.size()-1] == '/' || imageDir[imageDir.size()-1] == '\\')
+  {
+    newDir = imageDir;
+  }
+  else
+  {
+    newDir = imageDir;
+    newDir += '/';
   }
   // check if the param is a Directory
@@ -207,11 +175,10 @@
   {
     // check if the Directory has been added before
-    std::vector<char*>::const_iterator imageDir;
+    std::vector<std::string>::const_iterator imageDir;
     for (imageDir = this->imageDirs.begin(); imageDir != this->imageDirs.end(); imageDir++)
     {
-      if (!strcmp(*imageDir, newDir))
+      if (*imageDir == newDir)
       {
-        PRINTF(3)("Path %s already loaded\n", newDir);
-        delete[] newDir;
+        PRINTF(3)("Path %s already loaded\n", newDir.c_str());
         return true;
       }
@@ -223,6 +190,5 @@
   else
   {
-    PRINTF(1)("%s is not a Directory, and can not be added to the Paths of Images\n", newDir);
-    delete[] newDir;
+    PRINTF(1)("%s is not a Directory, and can not be added to the Paths of Images\n", newDir.c_str());
     return false;
   }
@@ -239,21 +205,19 @@
  * @returns a pointer to a desired Resource.
 */
-BaseObject* ResourceManager::load(const char* fileName, ResourcePriority prio,
+BaseObject* ResourceManager::load(const std::string& fileName, ResourcePriority prio,
                                   const MultiType& param0, const MultiType& param1, const MultiType& param2)
 {
-  if (fileName == NULL)
-    return NULL;
   ResourceType tmpType;
 #ifndef NO_MODEL
 #define __IF_OK
-  if (!strncasecmp(fileName+(strlen(fileName)-4), ".obj", 4))
+  if (!strncasecmp(fileName.c_str()+(fileName.size()-4), ".obj", 4))
     tmpType = OBJ;
-  else if (!strncmp(fileName+(strlen(fileName)-4), ".md2", 4))
+  else if (!strncmp(fileName.c_str()+(fileName.size()-4), ".md2", 4))
     tmpType = MD2;
-  else if (!strcasecmp(fileName, "cube") ||
-           !strcasecmp(fileName, "sphere") ||
-           !strcasecmp(fileName, "plane") ||
-           !strcasecmp(fileName, "cylinder") ||
-           !strcasecmp(fileName, "cone"))
+  else if (!strcasecmp(fileName.c_str(), "cube") ||
+            !strcasecmp(fileName.c_str(), "sphere") ||
+            !strcasecmp(fileName.c_str(), "plane") ||
+            !strcasecmp(fileName.c_str(), "cylinder") ||
+            !strcasecmp(fileName.c_str(), "cone"))
     tmpType = PRIM;
 #endif /* NO_MODEL */
@@ -263,9 +227,9 @@
 #endif
 #define __IF_OK
-    if (!strncasecmp(fileName+(strlen(fileName)-4), ".wav", 4))
+    if (!strncasecmp(fileName.c_str()+(fileName.size()-4), ".wav", 4))
       tmpType = WAV;
-    else if (!strncasecmp(fileName+(strlen(fileName)-4), ".mp3", 4))
+    else if (!strncasecmp(fileName.c_str()+(fileName.size()-4), ".mp3", 4))
       tmpType = MP3;
-    else if (!strncasecmp(fileName+(strlen(fileName)-4), ".ogg", 4))
+    else if (!strncasecmp(fileName.c_str()+(fileName.size()-4), ".ogg", 4))
       tmpType = OGG;
 #endif /* NO_AUDIO */
@@ -275,5 +239,5 @@
 #endif
 #define __IF_OK
-      if (!strncasecmp(fileName+(strlen(fileName)-4), ".ttf", 4))
+      if (!strncasecmp(fileName.c_str()+(fileName.size()-4), ".ttf", 4))
         tmpType = TTF;
 #endif /* NO_TEXT */
@@ -283,5 +247,5 @@
 #endif
 #define __IF_OK
-        if (!strncasecmp(fileName+(strlen(fileName)-5), ".vert", 5))
+        if (!strncasecmp(fileName.c_str()+(fileName.size()-5), ".vert", 5))
           tmpType = SHADER;
 #endif /* NO_SHADERS */
@@ -308,9 +272,7 @@
  * during the initialisation instead of at Runtime.
  */
-bool ResourceManager::cache(const char* fileName, ResourceType type, ResourcePriority prio,
+bool ResourceManager::cache(const std::string& fileName, ResourceType type, ResourcePriority prio,
                             const MultiType& param0, const MultiType& param1, const MultiType& param2)
 {
-  assert(fileName != NULL);
-
   // searching if the resource was loaded before.
   Resource* tmpResource;
@@ -359,9 +321,7 @@
  * @returns a pointer to a desired Resource.
 */
-BaseObject* ResourceManager::load(const char* fileName, ResourceType type, ResourcePriority prio,
+BaseObject* ResourceManager::load(const std::string& fileName, ResourceType type, ResourcePriority prio,
                                   const MultiType& param0, const MultiType& param1, const MultiType& param2)
 {
-  assert(fileName != NULL);
-
   // searching if the resource was loaded before.
   Resource* tmpResource;
@@ -397,5 +357,5 @@
  * @returns a pointer to a desired Resource.
  */
-Resource* ResourceManager::loadResource(const char* fileName, ResourceType type, ResourcePriority prio,
+Resource* ResourceManager::loadResource(const std::string& fileName, ResourceType type, ResourcePriority prio,
                                         const MultiType& param0, const MultiType& param1, const MultiType& param2)
 {
@@ -406,9 +366,8 @@
   tmpResource->prio = prio;
   tmpResource->pointer = NULL;
-  tmpResource->name = new char[strlen(fileName)+1];
-  strcpy(tmpResource->name, fileName);
+  tmpResource->name = fileName;
 
   // creating the full name. (directoryName + FileName)
-  char* fullName = ResourceManager::getFullName(fileName);
+  std::string fullName = ResourceManager::getFullName(fileName);
   // Checking for the type of resource \see ResourceType
   switch(type)
@@ -425,5 +384,5 @@
       else
       {
-        PRINTF(2)("File %s in %s does not exist. Loading a cube-Model instead\n", fileName, dataDir);
+        PRINTF(2)("File %s in %s does not exist. Loading a cube-Model instead\n", fileName.c_str(), dataDir.c_str());
         tmpResource->pointer = ResourceManager::load("cube", PRIM, prio, tmpResource->param[0].getFloat());
       }
@@ -435,13 +394,13 @@
         tmpResource->param[0] = 1.0f;
 
-      if (!strcmp(tmpResource->name, "cube"))
+      if (tmpResource->name == "cube")
         tmpResource->pointer = new PrimitiveModel(PRIM_CUBE, tmpResource->param[0].getFloat());
-      else if (!strcmp(tmpResource->name, "sphere"))
+      else if (tmpResource->name == "sphere")
         tmpResource->pointer = new PrimitiveModel(PRIM_SPHERE, tmpResource->param[0].getFloat());
-      else if (!strcmp(tmpResource->name, "plane"))
+      else if (tmpResource->name == "plane")
         tmpResource->pointer = new PrimitiveModel(PRIM_PLANE, tmpResource->param[0].getFloat());
-      else if (!strcmp(tmpResource->name, "cylinder"))
+      else if (tmpResource->name == "cylinder")
         tmpResource->pointer = new PrimitiveModel(PRIM_CYLINDER, tmpResource->param[0].getFloat());
-      else if (!strcmp(tmpResource->name, "cone"))
+      else if (tmpResource->name == "cone")
         tmpResource->pointer = new PrimitiveModel(PRIM_CONE, tmpResource->param[0].getFloat());
       break;
@@ -468,5 +427,5 @@
         tmpResource->pointer = new Font(fullName, (unsigned int) tmpResource->param[0].getInt());
       else
-        PRINTF(2)("%s does not exist in %s. Not loading Font\n", fileName, this->dataDir);
+        PRINTF(2)("%s does not exist in %s. Not loading Font\n", fileName.c_str(), this->dataDir.c_str());
       break;
 #endif /* NO_TEXT */
@@ -494,21 +453,18 @@
       else
       {
-        std::vector<char*>::iterator imageDir;
+        std::vector<std::string>::iterator imageDir;
         for (imageDir = this->imageDirs.begin(); imageDir != this->imageDirs.end(); imageDir++)
         {
-          char* imgName = new char[strlen(*imageDir)+strlen(fileName)+1];
-          sprintf(imgName, "%s%s", *imageDir, fileName);
+          std::string imgName = *imageDir + fileName;
           if(isFile(imgName))
           {
             PRINTF(4)("Image %s resides to %s\n", fileName, imgName);
             tmpResource->pointer = new Texture(imgName, tmpResource->param[0].getInt());
-            delete[] imgName;
             break;
           }
-          delete[] imgName;
         }
       }
       if(!tmpResource)
-        PRINTF(2)("!!Image %s not Found!!\n", fileName);
+        PRINTF(2)("!!Image %s not Found!!\n", fileName.c_str());
       break;
 #endif /* NO_TEXTURES */
@@ -520,5 +476,5 @@
         {
           MultiType param = param0; /// HACK
-          char* secFullName = ResourceManager::getFullName(param.getCString());
+          std::string secFullName = ResourceManager::getFullName(param.getCString());
           if (ResourceManager::isFile(secFullName))
           {
@@ -526,5 +482,4 @@
             tmpResource->pointer = new Shader(fullName, secFullName);
           }
-          delete[] secFullName;
         }
         else
@@ -538,11 +493,9 @@
     default:
       tmpResource->pointer = NULL;
-      PRINTF(1)("No type found for %s.\n   !!This should not happen unless the Type is not supported yet. JUST DO IT!!\n", tmpResource->name);
+      PRINTF(1)("No type found for %s.\n   !!This should not happen unless the Type is not supported yet. JUST DO IT!!\n", tmpResource->name.c_str());
       break;
   }
   if (tmpResource->pointer != NULL)
     this->resourceList.push_back(tmpResource);
-  delete[] fullName;
-
 
   if (tmpResource->pointer != NULL)
@@ -550,6 +503,5 @@
   else
   {
-    PRINTF(2)("Resource %s could not be loaded\n", fileName);
-    delete[] tmpResource->name;
+    PRINTF(2)("Resource %s could not be loaded\n", fileName.c_str());
     delete tmpResource;
     return NULL;
@@ -597,6 +549,5 @@
       delete resource->pointer;
       // deleting the List Entry:
-      PRINTF(4)("Resource %s safely removed.\n", resource->name);
-      delete[] resource->name;
+      PRINTF(4)("Resource %s safely removed.\n", resource->name.c_str());
       std::vector<Resource*>::iterator resourceIT = std::find(this->resourceList.begin(), this->resourceList.end(), resource);
       this->resourceList.erase(resourceIT);
@@ -604,8 +555,8 @@
     }
     else
-      PRINTF(4)("Resource %s not removed, because there are still %d References to it.\n", resource->name, resource->count);
-  }
-  else
-    PRINTF(4)("not deleting resource %s because DeleteLevel to high\n", resource->name);
+      PRINTF(4)("Resource %s not removed, because there are still %d References to it.\n", resource->name.c_str(), resource->count);
+  }
+  else
+    PRINTF(4)("not deleting resource %s because DeleteLevel to high\n", resource->name.c_str());
   return true;
 }
@@ -633,5 +584,5 @@
           if (round == 3)
             PRINTF(2)("unable to unload %s because there are still %d references to it\n",
-                      this->resourceList[index]->name, this->resourceList[index]->count);
+                      this->resourceList[index]->name.c_str(), this->resourceList[index]->count);
           removeCount++;
         }
@@ -653,5 +604,5 @@
  * @returns a Pointer to the Resource if found, NULL otherwise.
 */
-Resource* ResourceManager::locateResourceByInfo(const char* fileName, ResourceType type,
+Resource* ResourceManager::locateResourceByInfo(const std::string& fileName, ResourceType type,
     const MultiType& param0, const MultiType& param1, const MultiType& param2) const
 {
@@ -659,5 +610,5 @@
   for (resource = this->resourceList.begin(); resource != this->resourceList.end(); resource++)
   {
-    if ((*resource)->type == type && !strcmp(fileName, (*resource)->name))
+    if ((*resource)->type == type && fileName == (*resource)->name)
     {
       bool match = false;
@@ -743,15 +694,15 @@
 }
 
-char* ResourceManager::toResourcableString(unsigned int i)
-{
-  int len = strlen(ResourceManager::ResourceTypeToChar(this->resourceList[i]->type));
-  len += strlen(this->resourceList[i]->name);
+std::string ResourceManager::toResourcableString(unsigned int i)
+{
+/*  int len = strlen(ResourceManager::ResourceTypeToChar(this->resourceList[i]->type));
+  len += this->resourceList[i]->name.size();
   if (this->resourceList[i]->param[0].getCString()) len += strlen(this->resourceList[i]->param[0].getCString()) +1;
   if (this->resourceList[i]->param[1].getCString()) len += strlen(this->resourceList[i]->param[1].getCString()) +1;
   if (this->resourceList[i]->param[2].getCString()) len += strlen(this->resourceList[i]->param[2].getCString()) +1;
   len += 10;
-  char* tmp = new char[len];
+  std::string tmp = new char[len];
   tmp[0] = '\0';
-  strcat( tmp, ResourceManager::ResourceTypeToChar(this->resourceList[i]->type));
+  strcat(tmp, ResourceManager::ResourceTypeToChar(this->resourceList[i]->type));
   strcat(tmp,",");
   strcat (tmp, this->resourceList[i]->name);
@@ -771,5 +722,5 @@
     strcat( tmp, this->resourceList[i]->param[2].getCString());
   }
-  return tmp;
+  return tmp;*/
 }
 
@@ -778,7 +729,7 @@
  * @param resourceableString the String to cache the resource from.
  */
-bool ResourceManager::fromResourceableString(const char* resourceableString)
-{
-  SubString splits(resourceableString, ',');
+bool ResourceManager::fromResourceableString(const std::string& resourceableString)
+{
+/*  SubString splits(resourceableString, ',');
   splits.debug();
   if (splits.getCount() == 2)
@@ -793,5 +744,5 @@
   else if (splits.getCount() == 5)
     return this->cache(splits[1], ResourceManager::stringToResourceType(splits[0]),
-                RP_LEVEL, splits[2], splits[3], splits[4]);
+                RP_LEVEL, splits[2], splits[3], splits[4]);*/
 }
 
@@ -802,27 +753,17 @@
  * @returns true if it is a directory/symlink false otherwise
 */
-bool ResourceManager::isDir(const char* directoryName)
-{
-  if (directoryName == NULL)
-    return false;
-
-  char* tmpDirName = NULL;
+bool ResourceManager::isDir(const std::string& directoryName)
+{
+  std::string tmpDirName = directoryName;
   struct stat status;
 
   // checking for the termination of the string given. If there is a "/" at the end cut it away
-  if (directoryName[strlen(directoryName)-1] == '/' ||
-      directoryName[strlen(directoryName)-1] == '\\')
-  {
-    tmpDirName = new char[strlen(directoryName)];
-    strncpy(tmpDirName, directoryName, strlen(directoryName)-1);
-    tmpDirName[strlen(directoryName)-1] = '\0';
-  }
-  else
-  {
-    tmpDirName = new char[strlen(directoryName)+1];
-    strcpy(tmpDirName, directoryName);
-  }
-
-  if(!stat(tmpDirName, &status))
+  if (directoryName[directoryName.size()-1] == '/' ||
+      directoryName[directoryName.size()-1] == '\\')
+  {
+    tmpDirName.erase(tmpDirName.size()-1);
+  }
+
+  if(!stat(tmpDirName.c_str(), &status))
   {
     if (status.st_mode & (S_IFDIR
@@ -832,18 +773,11 @@
                          ))
     {
-      delete[] tmpDirName;
       return true;
     }
     else
-    {
-      delete[] tmpDirName;
       return false;
-    }
-  }
-  else
-  {
-    delete[] tmpDirName;
-    return false;
-  }
+  }
+  else
+    return false;
 }
 
@@ -853,12 +787,10 @@
  * @returns true if it is a regular file/symlink, false otherwise
 */
-bool ResourceManager::isFile(const char* fileName)
-{
-  if (fileName == NULL)
-    return false;
-  char* tmpFileName = ResourceManager::homeDirCheck(fileName);
+bool ResourceManager::isFile(const std::string& fileName)
+{
+  std::string tmpFileName = ResourceManager::homeDirCheck(fileName);
   // actually checks the File
   struct stat status;
-  if (!stat(tmpFileName, &status))
+  if (!stat(tmpFileName.c_str(), &status))
   {
     if (status.st_mode & (S_IFREG
@@ -868,18 +800,11 @@
                          ))
     {
-      delete[] tmpFileName;
       return true;
     }
     else
-    {
-      delete[] tmpFileName;
       return false;
-    }
-  }
-  else
-  {
-    delete[] tmpFileName;
-    return false;
-  }
+  }
+  else
+    return false;
 }
 
@@ -888,19 +813,16 @@
  * @param fileName The file to touch
 */
-bool ResourceManager::touchFile(const char* fileName)
-{
-  char* tmpName = ResourceManager::homeDirCheck(fileName);
-  if (tmpName == NULL)
+bool ResourceManager::touchFile(const std::string& fileName)
+{
+  std::string tmpName = ResourceManager::homeDirCheck(fileName);
+  if (tmpName.empty())
     return false;
   FILE* stream;
-  if( (stream = fopen (tmpName, "w")) == NULL)
-  {
-    PRINTF(1)("could not open %s fro writing\n", fileName);
-    delete[] tmpName;
+  if( (stream = fopen (tmpName.c_str(), "w")) == NULL)
+  {
+    PRINTF(1)("could not open %s fro writing\n", fileName.c_str());
     return false;
   }
   fclose(stream);
-
-  delete[] tmpName;
 }
 
@@ -909,11 +831,8 @@
  * @param fileName the File to delete
 */
-bool ResourceManager::deleteFile(const char* fileName)
-{
-  if (fileName == NULL)
-    return false;
-  char* tmpName = ResourceManager::homeDirCheck(fileName);
-  unlink(tmpName);
-  delete[] tmpName;
+bool ResourceManager::deleteFile(const std::string& fileName)
+{
+  std::string tmpName = ResourceManager::homeDirCheck(fileName);
+  unlink(tmpName.c_str());
 }
 
@@ -923,10 +842,8 @@
  * IMPORTANT: this has to be deleted from the outside
  */
-char* ResourceManager::homeDirCheck(const char* name)
-{
-  if (name == NULL)
-    return NULL;
-  char* retName;
-  if (!strncmp(name, "~/", 2))
+std::string ResourceManager::homeDirCheck(const std::string& name)
+{
+  std::string retName;
+  if (!strncmp(name.c_str(), "~/", 2))
   {
     char tmpFileName[500];
@@ -936,11 +853,9 @@
     strcpy(tmpFileName, getenv("HOME"));
 #endif
-    retName = new char[strlen(tmpFileName)+strlen(name)];
-    sprintf(retName, "%s%s", tmpFileName, name+1);
-  }
-  else
-  {
-    retName = new char[strlen(name)+1];
-    strcpy(retName, name);
+    retName = tmpFileName + name;
+  }
+  else
+  {
+    retName = name;
   }
   return retName;
@@ -949,23 +864,17 @@
 /**
  * @param name the relative name of the File/Directory.
- * @returns a new char* with the name in abs-dir-format
- */
-char* ResourceManager::getAbsDir(const char* name)
-{
-  if (name == NULL)
-    return NULL;
-  char* retName;
-  if (strncmp(name, "/", 1))
-  {
-    if (*name == '.' && *(name+1) != '.')
-      name++;
-    const char* absDir = ResourceManager::cwd();
-    retName = new char[strlen(absDir)+strlen(name)+1];
-    sprintf(retName, "%s%s", absDir, name);
-  }
-  else
-  {
-    retName = new char[strlen(name)+1];
-    strcpy(retName, name);
+ * @returns a new std::string with the name in abs-dir-format
+ */
+std::string ResourceManager::getAbsDir(const std::string& name)
+{
+  if (name.empty())
+    return "";
+  std::string retName = name;
+  if (strncmp(name.c_str(), "/", 1))
+  {
+    if (name[0] == '.' && name[1] != '.')
+      retName.erase(0);
+    const std::string& absDir = ResourceManager::cwd();
+    retName = absDir + retName;
   }
   return retName;
@@ -978,19 +887,14 @@
  * !!IMPORTANT: this has to be deleted from the outside!!
 */
-char* ResourceManager::getFullName(const char* fileName)
-{
-  if (fileName == NULL || ResourceManager::getInstance()->getDataDir() == NULL)
+std::string ResourceManager::getFullName(const std::string& fileName)
+{
+  if (fileName.empty() || ResourceManager::getInstance()->getDataDir().empty())
     return NULL;
 
-  char* retName = new char[strlen(ResourceManager::getInstance()->getDataDir())
-                           + strlen(fileName) + 1];
-  sprintf(retName, "%s%s", ResourceManager::getInstance()->getDataDir(), fileName);
+  std::string retName = ResourceManager::getInstance()->getDataDir() +fileName;
   if (ResourceManager::isFile(retName) || ResourceManager::isDir(retName))
     return retName;
   else
-  {
-    delete[] retName;
     return NULL;
-  }
 }
 
@@ -1005,15 +909,14 @@
  * @returns the Current Woring Directory
  */
-const char* ResourceManager::cwd()
-{
-  if (ResourceManager::getInstance()->_cwd == NULL)
+const std::string& ResourceManager::cwd()
+{
+  if (ResourceManager::getInstance()->_cwd.empty())
   {
     char cwd[1024];
     char* errorCode = getcwd(cwd, 1024);
     if (errorCode == 0)
-      return NULL;
-
-    ResourceManager::getInstance()->_cwd = new char[strlen(cwd)+1];
-    strcpy(ResourceManager::getInstance()->_cwd, cwd);
+      return ResourceManager::getInstance()->_cwd;
+
+    ResourceManager::getInstance()->_cwd = cwd;
   }
   return ResourceManager::getInstance()->_cwd;
@@ -1026,13 +929,11 @@
  * @returns true if the file exists, false otherwise
  */
-bool ResourceManager::isInDataDir(const char* fileName)
-{
-  if (fileName == NULL || ResourceManager::getInstance()->getDataDir() == NULL)
+bool ResourceManager::isInDataDir(const std::string& fileName)
+{
+  if (fileName.empty() || ResourceManager::getInstance()->getDataDir().empty())
     return false;
 
   bool retVal = false;
-  char* checkFile = new char[strlen(ResourceManager::getInstance()->getDataDir())
-                             + strlen(fileName) + 1];
-  sprintf(checkFile, "%s%s", ResourceManager::getInstance()->getDataDir(), fileName);
+  std::string checkFile = ResourceManager::getInstance()->getDataDir() + fileName;
 
   if (ResourceManager::isFile(checkFile) || ResourceManager::isDir(checkFile))
@@ -1040,5 +941,4 @@
   else
     retVal = false;
-  delete[] checkFile;
   return retVal;
 }
@@ -1055,9 +955,9 @@
   // if it is not initialized
   PRINT(0)(" Reference is: %p\n", ResourceManager::singletonRef);
-  PRINT(0)(" Data-Directory is: %s\n", this->dataDir);
+  PRINT(0)(" Data-Directory is: %s\n", this->dataDir.c_str());
   PRINT(0)(" List of Image-Directories: ");
-  std::vector<char*>::const_iterator imageDir;
+  std::vector<std::string>::const_iterator imageDir;
   for (imageDir = this->imageDirs.begin(); imageDir != this->imageDirs.end(); imageDir++)
-    PRINT(0)("%s ", (*imageDir));
+    PRINT(0)("%s ", (*imageDir).c_str());
   PRINT(0)("\n");
 
@@ -1068,5 +968,5 @@
   {
     PRINT(0)("-----------------------------------------\n");
-    PRINT(0)("Name: %s; References: %d; Type: %s ", (*resource)->name, (*resource)->count, ResourceManager::ResourceTypeToChar((*resource)->type));
+    PRINT(0)("Name: %s; References: %d; Type: %s ", (*resource)->name.c_str(), (*resource)->count, ResourceManager::ResourceTypeToChar((*resource)->type));
 
     PRINT(0)("gets deleted at ");
Index: branches/std/src/lib/util/loading/resource_manager.h
===================================================================
--- branches/std/src/lib/util/loading/resource_manager.h	(revision 7202)
+++ branches/std/src/lib/util/loading/resource_manager.h	(revision 7203)
@@ -71,5 +71,5 @@
   unsigned int      count;             //!< How many times this Resource has been loaded.
 
-  char*             name;              //!< Name of the Resource.
+  std::string       name;              //!< Name of the Resource.
   ResourceType      type;              //!< ResourceType of this Resource.
   ResourcePriority  prio;              //!< The Priority of this resource. (This will only be increased)
@@ -96,20 +96,20 @@
   inline static ResourceManager* getInstance() { if (!singletonRef) singletonRef = new ResourceManager();  return singletonRef; };
 
-  bool setDataDir(const char* dataDir);
+  bool setDataDir(const std::string& dataDir);
   /** @returns the Name of the data directory */
-  inline const char* getDataDir() const { return this->dataDir; };
+  inline const std::string& getDataDir() const { return this->dataDir; };
 
 
-  bool tryDataDir(const char* dataDir);
-  bool verifyDataDir(const char* fileInside);
-  bool addImageDir(const char* imageDir);
+  bool tryDataDir(const std::string& dataDir);
+  bool verifyDataDir(const std::string& fileInside);
+  bool addImageDir(const std::string& imageDir);
 
-  bool cache(const char* fileName, ResourceType type, ResourcePriority prio = RP_NO,
+  bool cache(const std::string& fileName, ResourceType type, ResourcePriority prio = RP_NO,
              const MultiType& param0 = MultiType(), const MultiType& param1 = MultiType(), const MultiType& param2 = MultiType());
   BaseObject* copy(BaseObject* resourcePointer);
 
-  BaseObject* load(const char* fileName, ResourcePriority prio = RP_NO,
+  BaseObject* load(const std::string& fileName, ResourcePriority prio = RP_NO,
                    const MultiType& param0 = MultiType(), const MultiType& param1 = MultiType(), const MultiType& param2 = MultiType());
-  BaseObject* load(const char* fileName, ResourceType type, ResourcePriority prio = RP_NO,
+  BaseObject* load(const std::string& fileName, ResourceType type, ResourcePriority prio = RP_NO,
                    const MultiType& param0 = MultiType(), const MultiType& param1 = MultiType(), const MultiType& param2 = MultiType());
   bool unload(BaseObject* pointer, ResourcePriority prio = RP_NO);
@@ -117,10 +117,10 @@
   bool unloadAllByPriority(ResourcePriority prio);
 
-  Resource* locateResourceByInfo(const char* fileName, ResourceType type,
+  Resource* locateResourceByInfo(const std::string& fileName, ResourceType type,
                                  const MultiType& param0 = MultiType(), const MultiType& param1 = MultiType(), const MultiType& param2 = MultiType()) const;
   Resource* locateResourceByPointer(const void* pointer) const;
 
-  char* toResourcableString(unsigned int i);
-  bool fromResourceableString(const char* resourceableString);
+  std::string toResourcableString(unsigned int i);
+  bool fromResourceableString(const std::string& resourceableString);
   /** @returns the Count of Resources the ResourceManager handles */
   unsigned int resourceCount() const { return this->resourceList.size(); }
@@ -130,13 +130,13 @@
 
   // utility functions for handling files in and around the data-directory
-  static bool isDir(const char* directory);
-  static bool isFile(const char* fileName);
-  static bool touchFile(const char* fileName);
-  static bool deleteFile(const char* fileName);
-  static char* homeDirCheck(const char* fileName);
-  static char* getFullName(const char* fileName);
-  static bool isInDataDir(const char* fileName);
-  static char* getAbsDir(const char* fileName);
-  static const char* cwd();
+  static bool isDir(const std::string& directory);
+  static bool isFile(const std::string& fileName);
+  static bool touchFile(const std::string& fileName);
+  static bool deleteFile(const std::string& fileName);
+  static std::string homeDirCheck(const std::string& fileName);
+  static std::string getFullName(const std::string& fileName);
+  static bool isInDataDir(const std::string& fileName);
+  static std::string getAbsDir(const std::string& fileName);
+  static const std::string& cwd();
 
   static const char* ResourceTypeToChar(ResourceType type);
@@ -145,17 +145,17 @@
  private:
   ResourceManager();
-  Resource* loadResource(const char* fileName, ResourceType type, ResourcePriority prio,
+  Resource* loadResource(const std::string& fileName, ResourceType type, ResourcePriority prio,
                          const MultiType& param0, const MultiType& param1, const MultiType& param2);
 
  private:
-  static ResourceManager*  singletonRef;       //!< singleton Reference
+  static ResourceManager*    singletonRef;       //!< singleton Reference
 
-  char*                    _cwd;               //!< The currend Working directory.
-  char*                    dataDir;            //!< The Data Directory, where all relevant Data is stored.
-  std::vector<char*>       imageDirs;          //!< A list of directories in which images are stored.
+  std::string                _cwd;               //!< The currend Working directory.
+  std::string                dataDir;            //!< The Data Directory, where all relevant Data is stored.
+  std::vector<std::string>   imageDirs;          //!< A list of directories in which images are stored.
 
-  std::vector<Resource*>   resourceList;       //!< The List of Resources, that has already been loaded.
+  std::vector<Resource*>     resourceList;       //!< The List of Resources, that has already been loaded.
 
-  static const char*       resourceNames[RESOURCE_TYPE_SIZE];
+  static const char*         resourceNames[RESOURCE_TYPE_SIZE];
 };
 
