Index: /orxonox/branches/updater/src/gui/orxonox_gui.h
===================================================================
--- /orxonox/branches/updater/src/gui/orxonox_gui.h	(revision 3298)
+++ /orxonox/branches/updater/src/gui/orxonox_gui.h	(revision 3299)
@@ -28,7 +28,7 @@
   ~OrxonoxGui ();
 
+  void copyOptionsToGameStruct();
 };
 
 
-
 #endif /* _ORXONOX_GUI_H */
Index: /orxonox/branches/updater/src/gui/orxonox_gui_flags.cc
===================================================================
--- /orxonox/branches/updater/src/gui/orxonox_gui_flags.cc	(revision 3298)
+++ /orxonox/branches/updater/src/gui/orxonox_gui_flags.cc	(revision 3299)
@@ -32,16 +32,14 @@
 OrxonoxGuiFlags::OrxonoxGuiFlags (Widget* widget)
 {
-  flagText = (char*) malloc (1024);
+  this->flagsFrame = new Frame ("Orxonox-Startup-Flags:");
+  this->flagsBox = new Box ('v');
 
-  flagsFrame = new Frame ("Orxonox-Startup-Flags:");
-  flagsBox = new Box ('v');
+  this->flagsLabel = new Label ();
+  this->flagsLabel->setSize (260,60);
+  this->flagsBox->fill (flagsLabel);
+  this->shortFlags = new CheckButton ("shortFlags");
+  this->flagsBox->fill (shortFlags);
 
-  flagsLabel = new Label ();
-  flagsLabel->setSize (260,60);
-  flagsBox->fill (flagsLabel);
-  shortFlags = new CheckButton ("shortFlags");
-  flagsBox->fill (shortFlags);
-
-  flagsFrame->fill (flagsBox);
+  this->flagsFrame->fill (flagsBox);
 }
 
@@ -52,5 +50,5 @@
 Widget* OrxonoxGuiFlags::getWidget ()
 {
-  return flagsFrame;
+  return this->flagsFrame;
 }
 
@@ -61,8 +59,12 @@
 void OrxonoxGuiFlags::setTextFromFlags (Widget* widget)
 {
-  sprintf (flagText, "");
-  strcat (flagText, "orxonox");
-  FlagsText (widget);
-  flagsLabel->setTitle(flagText);
+  FlagInfo flagInfo;
+  flagInfo.shortFlags = this->shortFlags;
+  flagInfo.flagsLabel = this->flagsLabel;
+
+  this->flagsLabel->ereaseText();
+  this->flagsLabel->appendText("orxonox");
+  widget->walkThrough(OrxonoxGuiFlags::flagsText, &flagInfo, 0);
+  //  flagsLabel->setTitle(flagText);
 }
 
@@ -71,35 +73,26 @@
     \param widget like OrxonoxGuiFlags::setTextFromFlags(widget)
 */
-void OrxonoxGuiFlags::FlagsText(Widget* widget)
+void OrxonoxGuiFlags::flagsText(Widget* widget, void* flagInfo)
 {
+  FlagInfo* info = (FlagInfo*)flagInfo;
   if (widget->isOption >= 1)
-    if  (static_cast<Option*>(widget)->value != static_cast<Option*>(widget)->defaultValue && (static_cast<Option*>(widget)->flagName || static_cast<Option*>(widget)->flagNameShort ))
+    if  (static_cast<Option*>(widget)->value != static_cast<Option*>(widget)->defaultValue )
       {
-	if (shortFlags->isActive())
+	if (info->shortFlags->isActive() && static_cast<Option*>(widget)->flagNameShort)
 	  {
-	    strcat (flagText, " -");
-	    strcat (flagText, static_cast<Option*>(widget)->flagNameShort);
+	    info->flagsLabel->appendText(" -");
+	    info->flagsLabel->appendText(static_cast<Option*>(widget)->flagNameShort);
 	  }
-	else
+	else if (!info->shortFlags->isActive() && static_cast<Option*>(widget)->flagName)
 	  {
-	    strcat (flagText, " --");
-	    strcat (flagText, static_cast<Option*>(widget)->flagName);
+	    info->flagsLabel->appendText(" --");
+	    info->flagsLabel->appendText(static_cast<Option*>(widget)->flagName);
 	  }
+
 	if (static_cast<Option*>(widget)->isOption == 2)
 	  {
-	    sprintf (flagText, "%s=%i", flagText, static_cast<Option*>(widget)->value);
+	    info->flagsLabel->appendText("=");
+	    info->flagsLabel->appendInt(static_cast<Option*>(widget)->value);
 	  }
       }
-  switch (widget->isOption)
-    {
-    case -1:
-      FlagsText (static_cast<Container*>(widget)->down);
-      break;
-    case -2:
-      FlagsText (static_cast<Box*>(widget)->down);
-      break;
-    } 
-  
-  if (widget->next != NULL)
-    FlagsText (widget->next);
 }
Index: /orxonox/branches/updater/src/gui/orxonox_gui_flags.h
===================================================================
--- /orxonox/branches/updater/src/gui/orxonox_gui_flags.h	(revision 3298)
+++ /orxonox/branches/updater/src/gui/orxonox_gui_flags.h	(revision 3299)
@@ -17,5 +17,4 @@
   CheckButton* shortFlags;    //!< CheckButton to change the display of short and long flags \todo show long if long not availible...
   Label* flagsLabel;          //!< The Label of the Flags
-  char* flagText;             //!< The Text of the Label. \todo Delete when Object is destroyed.
 
  public:
@@ -24,6 +23,11 @@
 
   void setTextFromFlags (Widget* widget);
-  void OrxonoxGuiFlags::FlagsText(Widget* widget);
+  static void flagsText(Widget* widget, void* flagInfo);
   
+  struct FlagInfo
+  {
+    CheckButton* shortFlags;
+    Label* flagsLabel;
+  };
   Widget* getWidget ();
 };
Index: /orxonox/branches/updater/src/gui/orxonox_gui_gtk.cc
===================================================================
--- /orxonox/branches/updater/src/gui/orxonox_gui_gtk.cc	(revision 3298)
+++ /orxonox/branches/updater/src/gui/orxonox_gui_gtk.cc	(revision 3299)
@@ -1513,4 +1513,50 @@
 
 /**
+   \brief ereases the Text of a Label
+*/
+void Label::ereaseText(void)
+{
+  this->setTitle("");
+}
+
+/** 
+    \brief appends some Text to a Label
+    \param textToAppend The text that will be appended to this Label
+*/
+void Label::appendText(char* textToAppend)
+{
+  if (this->title)
+    {
+      char* tmpTitle = new char[strlen(this->title)+strlen(textToAppend)+1];
+      strcpy(tmpTitle, title);  
+      strcat(tmpTitle, textToAppend);
+      delete []this->title;
+      this->title = tmpTitle;
+    }
+  else
+    {
+      this->title = new char[strlen(textToAppend)];
+    }
+  
+#ifdef HAVE_GTK2
+  gtk_label_set_text (GTK_LABEL (this->widget), title);
+#endif /* HAVE_GTK2 */
+}
+
+/** 
+    \brief Appends some integer to the Label
+    \param intToAppend The Int that will be added.
+    
+    it does this by just converting the int into a char* and send it to appendText
+*/
+void Label::appendInt(int intToAppend)
+{
+  char append [20];
+  sprintf(append, "%d", intToAppend);
+  this->appendText(append);
+}
+
+
+/**
    \brief get the Text of a Label
    \return The Text the Label holds.
Index: /orxonox/branches/updater/src/gui/orxonox_gui_gtk.h
===================================================================
--- /orxonox/branches/updater/src/gui/orxonox_gui_gtk.h	(revision 3298)
+++ /orxonox/branches/updater/src/gui/orxonox_gui_gtk.h	(revision 3299)
@@ -316,5 +316,5 @@
 };
 
-//! A CharLabel is a simple Label, that holds a char*, and will be updated, if changed.
+//! A OptionLabel is a simple Label, that holds a char*, and will be updated, if changed.
 class OptionLabel : public Option
 {
@@ -347,4 +347,7 @@
   
   void setTitle(char* text);
+  void ereaseText(void);
+  void appendText(char* textToAppend);
+  void appendInt(int intToAppend);
   char* getText ();
 };
Index: /orxonox/branches/updater/src/gui/rc
===================================================================
--- /orxonox/branches/updater/src/gui/rc	(revision 3298)
+++ /orxonox/branches/updater/src/gui/rc	(revision 3299)
@@ -120,17 +120,17 @@
 # just listed in this document for the users reference.
 
-widget_class "GtkWindow" style "window"
-widget_class "GtkFrame" style "window"
-widget_class "Gtk*EventBox" style "window"
-widget_class "GtkDialog" style "window"
-widget_class "GtkFileSelection" style "window"
-widget_class "*Gtk*Scale" style "scale"
-widget_class "*GtkCheckButton*" style "toggle_button"
-widget_class "*Gtk*Menu*" style "toggle_button"
-widget_class "*GtkRadioButton*" style "toggle_button"
-widget_class "*GtkButton*" style "button"
-widget_class "*Ruler" style "ruler"
-widget_class "*GtkText" style "text"
-widget_class "*GtkLabel" style "text"
+widget_class "GtkWindow"           style "window"
+widget_class "GtkFrame"            style "window"
+widget_class "Gtk*EventBox"        style "window"
+widget_class "GtkDialog"           style "window"
+widget_class "GtkFileSelection"    style "window"
+widget_class "*Gtk*Scale"          style "scale"
+widget_class "*GtkCheckButton*"    style "toggle_button"
+widget_class "*Gtk*Menu*"          style "toggle_button"
+widget_class "*GtkRadioButton*"    style "toggle_button"
+widget_class "*GtkButton*"         style "button"
+widget_class "*Ruler"              style "ruler"
+widget_class "*GtkText"            style "text"
+widget_class "*GtkLabel"           style "text"
 
 
