Index: /trunk/MagicSoft/Mars/mars.cc
===================================================================
--- /trunk/MagicSoft/Mars/mars.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mars.cc	(revision 1082)
@@ -1,4 +1,9 @@
 #include <TROOT.h>
 #include <TApplication.h>
+
+#include "MAGIC.h"
+
+#include "MLog.h"
+#include "MLogManip.h"
 
 #include "MMars.h"
@@ -15,6 +20,70 @@
 //    started by  h. kornmayer      january, 3rd  2001 
 
+void Usage()
+{
+    gLog << "Sorry the usage is:" << endl;
+    gLog << "   mars [-vn]" << endl << endl;
+    gLog << "     -v0: verbosity level: as less as possible" << endl;
+    gLog << "     -v1: errors only"                          << endl;
+    gLog << "     -v2: errors and warnings <default>"        << endl;
+    gLog << "     -v3: errors, warnings and infos"           << endl;
+}
+
 int main(int argc, char **argv )
 {
+    gLog << all;
+
+    //                1         2         3         4         5
+    //       12345678901234567890123456789012345678901234567890
+    gLog << "==================================================" << endl;
+    gLog << "                    MARS v0.5                     " << endl;
+    gLog << "    Magic Analysis and Reconstruction Software    " << endl;
+    gLog << "            Compiled on <" << __DATE__ << ">"       << endl;
+    gLog << "               Using ROOT v" << ROOTVER             << endl;
+    gLog << "==================================================" << endl;
+    gLog << endl;
+
+    //
+    // check for the right usage of the program
+    //
+    if (argc<1 || argc>2)
+    {
+        Usage();
+        return -1;
+    }
+
+    if (argc==2)
+    {
+        if (argv[1][0]!='-' || argv[1][1]!='v')
+        {
+            Usage();
+            return -1;
+        }
+
+        switch (argv[1][2])
+        {
+        case '0':
+            gLog.SetDebugLevel(0);
+            break;
+        case '1':
+            gLog.SetDebugLevel(1);
+            break;
+        case '2':
+            gLog.SetDebugLevel(2);
+            break;
+        case '3':
+            gLog.SetDebugLevel(3);
+            break;
+        default:
+            Usage();
+            return -1;
+        }
+    }
+    else
+        gLog.SetDebugLevel(2);
+
+    //
+    // Swtich of TObjectStreamer in our base classes derived from TObject
+    //
     MArray::Class()->IgnoreTObjectStreamer();
     MParContainer::Class()->IgnoreTObjectStreamer();
Index: /trunk/MagicSoft/Mars/merpp.cc
===================================================================
--- /trunk/MagicSoft/Mars/merpp.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/merpp.cc	(revision 1082)
@@ -54,4 +54,9 @@
         return -1;
     }
+
+    //
+    // Set verbosity to highest level.
+    //
+    gLog.SetDebugLevel(2);
 
     //
Index: /trunk/MagicSoft/Mars/mgui/MCamDisplay.cc
===================================================================
--- /trunk/MagicSoft/Mars/mgui/MCamDisplay.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mgui/MCamDisplay.cc	(revision 1082)
@@ -36,4 +36,10 @@
     // Construct all hexagons. Use new-operator with placement
     //
+
+    // root 3.02
+    //  * base/inc/TObject.h:
+    //    register BIT(8) as kNoContextMenu. If an object has this bit set it will
+    //    not get an automatic context menu when clicked with the right mouse button.
+
     fPixels = new TClonesArray("MHexagon", fNumPixels);
     for (UInt_t i=0; i<fNumPixels; i++)
Index: /trunk/MagicSoft/Mars/mgui/MGeomCam.cc
===================================================================
--- /trunk/MagicSoft/Mars/mgui/MGeomCam.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mgui/MGeomCam.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -37,4 +37,6 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
+
 #include "MGeomPix.h"
 #include "MHexagon.h"
@@ -105,5 +107,5 @@
     //   Print Information about the Geometry of the camera
     //
-    *fLog << " Number of Pixels (" << GetTitle() << "): " << fNumPixels << endl;
+    *fLog << all << " Number of Pixels (" << GetTitle() << "): " << fNumPixels << endl;
 
     for (UInt_t i=0; i<fNumPixels; i++)
Index: /trunk/MagicSoft/Mars/mgui/MGeomCamCT1.cc
===================================================================
--- /trunk/MagicSoft/Mars/mgui/MGeomCamCT1.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mgui/MGeomCamCT1.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -42,4 +42,6 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
+
 #include "MGeomPix.h"
 
@@ -208,5 +210,5 @@
     // fill the geometry class with the coordinates of the CT1 camera
     //
-    *fLog << " Create CT1 geometry " << endl;
+    *fLog << inf << " Create CT1 geometry " << endl;
 
     //
Index: /trunk/MagicSoft/Mars/mgui/MGeomCamMagic.cc
===================================================================
--- /trunk/MagicSoft/Mars/mgui/MGeomCamMagic.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mgui/MGeomCamMagic.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -38,4 +38,6 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
+
 #include "MGeomPix.h"
 
@@ -63,5 +65,5 @@
     //   fill the geometry class with the coordinates of the MAGIC camera
     //
-    *fLog << " Creating Magic geometry " << endl ;
+    *fLog << inf << " Creating Magic geometry " << endl ;
 
     //
Index: /trunk/MagicSoft/Mars/mgui/MGeomPix.cc
===================================================================
--- /trunk/MagicSoft/Mars/mgui/MGeomPix.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mgui/MGeomPix.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -36,4 +36,5 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
 
 ClassImp(MGeomPix);
@@ -80,5 +81,5 @@
 { 
     //   information about a pixel
-    gLog << "MPixGeom:  x= " << fX
+    *fLog << all << "MPixGeom:  x= " << fX
         << "  y= " << fY
         << "  r= " << fR
Index: /trunk/MagicSoft/Mars/mgui/MHexagon.cc
===================================================================
--- /trunk/MagicSoft/Mars/mgui/MHexagon.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mgui/MHexagon.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mhist/MFillH.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MFillH.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MFillH.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  07/2001 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  07/2001 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -44,4 +44,6 @@
 //   yourself, using MReadTree::EnableBranch()                              //
 //                                                                          //
+//   Checkout the Warning in MTaskList.                                     //
+//                                                                          //
 //  Input Containers:                                                       //
 //   A parameter container                                                  //
@@ -88,6 +90,6 @@
     Init(name, title);
 
+    fHName = hist;
     fParContainerName = par;
-    fHName = hist;
 }
 
@@ -105,6 +107,7 @@
     Init(name, title);
 
+    fHName = hist;
     fParContainer = par;
-    fHName = hist;
+    fParContainerName = par->GetName();
 }
 
@@ -122,6 +125,7 @@
     Init(name, title);
 
+    fH = hist;
+    fHName = hist->GetName();
     fParContainerName = par;
-    fH = hist;
 }
 
@@ -139,6 +143,8 @@
     Init(name, title);
 
+    fH = hist;
+    fHName = hist->GetName();
     fParContainer = par;
-    fH = hist;
+    fParContainerName = par->GetName();
 }
 
@@ -158,5 +164,5 @@
         if (!fParContainer)
         {
-            *fLog << dbginf << fParContainerName << " [MParContainer] not found... aborting." << endl;
+            *fLog << err << dbginf << fParContainerName << " [MParContainer] not found... aborting." << endl;
             return kFALSE;
         }
@@ -172,5 +178,5 @@
     if (!fH->InheritsFrom("MH"))
     {
-        *fLog << dbginf << fH->GetDescriptor() << " ";
+        *fLog << err << dbginf << fH->GetDescriptor() << " ";
         *fLog << "doesn't inherit from MH - cannot be used for MFillH... aborting." << endl;
         return kFALSE;
Index: /trunk/MagicSoft/Mars/mhist/MH.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MH.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MH.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  07/2001 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  07/2001 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mhist/MHFadcCam.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MHFadcCam.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MHFadcCam.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -44,5 +44,4 @@
 //  creates an a list of histograms for all pixels and both gain channels
 //
-#include <iostream.h>
 MHFadcCam::MHFadcCam(const char *name, const char *title)
 {
Index: /trunk/MagicSoft/Mars/mhist/MHFadcPix.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MHFadcPix.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MHFadcPix.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mhist/MHHillas.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MHHillas.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MHHillas.cc	(revision 1082)
@@ -1,2 +1,26 @@
+/* ======================================================================== *\
+!
+! *
+! * This file is part of MARS, the MAGIC Analysis and Reconstruction
+! * Software. It is distributed to you in the hope that it can be a useful
+! * and timesaving tool in analysing Data of imaging Cerenkov telescopes.
+! * It is distributed WITHOUT ANY WARRANTY.
+! *
+! * Permission to use, copy, modify and distribute this software and its
+! * documentation for any purpose is hereby granted without fee,
+! * provided that the above copyright notice appear in all copies and
+! * that both that copyright notice and this permission notice appear
+! * in supporting documentation. It is provided "as is" without express
+! * or implied warranty.
+! *
+!
+!
+!   Author(s): Thomas Bretz  2001 <mailto:tbretz@uni-sw.gwdg.de>
+!
+!   Copyright: MAGIC Software Development, 2000-2001
+!
+!
+\* ======================================================================== */
+
 ///////////////////////////////////////////////////////////////////////
 //
Index: /trunk/MagicSoft/Mars/mhist/MHMcCollectionArea.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MHMcCollectionArea.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MHMcCollectionArea.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!              Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mhist/MHMcEnergy.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MHMcEnergy.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MHMcEnergy.cc	(revision 1082)
@@ -16,5 +16,6 @@
 !
 !
-!   Author(s): Javier Lopez 05/2001 (jlopez@ifae.es)
+!   Author(s): Javier Lopez 05/2001 <mailto:jlopez@ifae.es>
+!   Author(s): Thomas Bretz 05/2001 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -42,4 +43,7 @@
 
 #include "MH.h"
+
+#include "MLog.h"
+#include "MLogManip.h"
 
 ClassImp(MHMcEnergy);
@@ -210,5 +214,5 @@
 void MHMcEnergy::Print(Option_t*) const
 {
-    cout << "Threshold: " << fThreshold << " +- " << fThresholdErr << endl;
+    *fLog << all << "Threshold: " << fThreshold << " +- " << fThresholdErr << endl;
 }
 
Index: /trunk/MagicSoft/Mars/mhist/MHMcRate.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MHMcRate.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MHMcRate.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -196,5 +196,5 @@
 void MHMcRate::Print(Option_t *) const
 {
-    *fLog << "Incident rate " << fShowerRate << " Hz " << endl;
+    *fLog << all << "Incident rate " << fShowerRate << " Hz " << endl;
     *fLog << "Trigger Rate " << fTriggerRate << " +- " << fTriggerRateError << " Hz" << endl;
 }
@@ -206,10 +206,10 @@
 void MHMcRate::Draw(Option_t *)
 {
-    *fLog << dbginf << "To be iplemented" << endl;
+    *fLog << all << dbginf << " - MHMcRate::Draw: To be iplemented" << endl;
 }
 
 TObject *MHMcRate::DrawClone(Option_t *) const
 {
-    *fLog << dbginf << "To be iplemented" << endl;
+    *fLog << all << dbginf << " - MHMcRate::DrawClone: To be iplemented" << endl;
     return NULL;
 } 
Index: /trunk/MagicSoft/Mars/mhist/MHStarMap.cc
===================================================================
--- /trunk/MagicSoft/Mars/mhist/MHStarMap.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mhist/MHStarMap.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mmain/MAnalysis.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmain/MAnalysis.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmain/MAnalysis.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  9/2001 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  9/2001 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mmain/MBrowser.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmain/MBrowser.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmain/MBrowser.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mmain/MCameraDisplay.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmain/MCameraDisplay.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmain/MCameraDisplay.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mmain/MDataCheck.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmain/MDataCheck.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmain/MDataCheck.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mmain/MEvtDisp.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmain/MEvtDisp.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmain/MEvtDisp.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mmain/MMars.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmain/MMars.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmain/MMars.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mmain/MMonteCarlo.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmain/MMonteCarlo.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmain/MMonteCarlo.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mmontecarlo/MMcCollectionAreaCalc.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmontecarlo/MMcCollectionAreaCalc.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmontecarlo/MMcCollectionAreaCalc.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!              Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -66,5 +66,5 @@
     if (!fMcEvt)
     {
-        *fLog << dbginf << "MMcEvt not found... exit." << endl;
+        *fLog << err << dbginf << "MMcEvt not found... exit." << endl;
         return kFALSE;
     }
@@ -73,5 +73,5 @@
     if (!fMcTrig)
     {
-        *fLog << dbginf << fObjName << " [MMcTrig] not found... exit." << endl;
+        *fLog << err << dbginf << fObjName << " [MMcTrig] not found... exit." << endl;
         return kFALSE;
     }
Index: /trunk/MagicSoft/Mars/mmontecarlo/MMcThresholdCalc.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmontecarlo/MMcThresholdCalc.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmontecarlo/MMcThresholdCalc.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Javier Lopez 05/2001 (jlopez@ifae.es)
-!              Thomas Bretz 06/2001 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Javier Lopez 05/2001 <mailto:jlopez@ifae.es>
+!   Author(s): Thomas Bretz 06/2001 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -107,5 +107,5 @@
     if (!fMcEvt)
     {
-        *fLog << dbginf << "MMcEvt not found... aborting." << endl;
+        *fLog << err << dbginf << "MMcEvt not found... aborting." << endl;
         return kFALSE;
     }
@@ -117,5 +117,5 @@
     if (num != fNum)
     {
-        *fLog << dbginf << fNum << " MMcTrig objects requested, ";
+        *fLog << err << dbginf << fNum << " MMcTrig objects requested, ";
         *fLog << num << " are available... aborting." << endl;
         return kFALSE;
@@ -126,5 +126,5 @@
     if (num != fNum)
     {
-        *fLog << dbginf << fNum << " MHMcEnergy objects requested, ";
+        *fLog << err << dbginf << fNum << " MHMcEnergy objects requested, ";
         *fLog << num << " are available... aborting." << endl;
         return kFALSE;
Index: /trunk/MagicSoft/Mars/mmontecarlo/MMcTriggerRateCalc.cc
===================================================================
--- /trunk/MagicSoft/Mars/mmontecarlo/MMcTriggerRateCalc.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mmontecarlo/MMcTriggerRateCalc.cc	(revision 1082)
@@ -16,6 +16,6 @@
 !
 !
-!   Author(s): Harald Kornmayer 1/2001 (harald@mppmu.mpg.de)
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
+!   Author(s): Harald Kornmayer 1/2001
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -131,5 +131,5 @@
     if (!fMcEvt)
     {
-        *fLog << dbginf << "MMcEvt not found... aborting." << endl;
+        *fLog << err << dbginf << "MMcEvt not found... aborting." << endl;
         return kFALSE;
     }
@@ -141,5 +141,5 @@
     if (num != fNum)
     {
-        *fLog << dbginf << fNum << " MMcTrig objects requested, ";
+        *fLog << err << dbginf << fNum << " MMcTrig objects requested, ";
         *fLog << num << " are available... aborting." << endl;
         return kFALSE;
@@ -150,5 +150,5 @@
     if (num != fNum)
     {
-        *fLog << dbginf << fNum << " MHMcRate objects requested, ";
+        *fLog << err << dbginf << fNum << " MHMcRate objects requested, ";
         *fLog << num << " are available... aborting." << endl;
         return kFALSE;
Index: /trunk/MagicSoft/Mars/mraw/MRawCrateArray.cc
===================================================================
--- /trunk/MagicSoft/Mars/mraw/MRawCrateArray.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mraw/MRawCrateArray.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
Index: /trunk/MagicSoft/Mars/mraw/MRawCrateData.cc
===================================================================
--- /trunk/MagicSoft/Mars/mraw/MRawCrateData.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mraw/MRawCrateData.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -39,4 +39,5 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
 
 ClassImp(MRawCrateData);
@@ -64,6 +65,7 @@
 void MRawCrateData::Print(Option_t *t) const
 {
-    gLog << "Crate Number " << fDAQCrateNumber << ":  ";
-    gLog << "FADCEventNr=" << fFADCEvtNumber << "  ";
-    gLog << "FADCClockTick=" << fFADCClockTick << " (20MHz)" << endl;
+    *fLog << all;
+    *fLog << "Crate Number " << fDAQCrateNumber << ":  ";
+    *fLog << "FADCEventNr=" << fFADCEvtNumber << "  ";
+    *fLog << "FADCClockTick=" << fFADCClockTick << " (20MHz)" << endl;
 }
Index: /trunk/MagicSoft/Mars/mraw/MRawEvtData.cc
===================================================================
--- /trunk/MagicSoft/Mars/mraw/MRawEvtData.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mraw/MRawEvtData.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -49,6 +49,4 @@
 
 #include "MRawEvtData.h"
-
-#include <iomanip.h>
 
 #include <fstream.h>
@@ -155,5 +153,5 @@
     fLog->unsetf(ios::showbase);
 
-    *fLog << dec;
+    *fLog << dec << all;
     *fLog << "HiGain: " << nHiPix << " Pixels with " << (Int_t)nHiSamp << " Samples" << endl;
     *fLog << "LoGain: " << nLoPix << " Pixels with " << (Int_t)nLoSamp << " Samples";;
@@ -213,5 +211,5 @@
     if (GetNumPixels()==0)
     {
-        *fLog << "Sorry, no pixel to draw!" << endl;
+        *fLog << warn << "Sorry, no pixel to draw!" << endl;
         return;
     }
@@ -229,5 +227,5 @@
             num= GetNumPixels();
 
-        *fLog << "Drawing Graph: Pixel #" << num << " of " << (int)GetNumPixels() << endl;
+        *fLog << inf << "Drawing Graph: Pixel #" << num << " of " << (int)GetNumPixels() << endl;
 
         const Int_t n = GetNumHiGainSamples();
@@ -288,5 +286,5 @@
     }
 
-    *fLog << dbginf << "Warning - You must specify either 'GRAPH' or 'HIST'" << endl;
+    *fLog << warn << dbginf << "Warning - You must specify either 'GRAPH' or 'HIST'" << endl;
 }
 
@@ -375,5 +373,5 @@
     if (nSamp && ns!=nSamp)
     {
-        *fLog << "RawEvtData::AddPixel: Error, number of samples in ";
+        *fLog << err << "RawEvtData::AddPixel: Error, number of samples in ";
         *fLog << "TArrayC doesn't match actual number" << endl;
         return;
Index: /trunk/MagicSoft/Mars/mraw/MRawEvtHeader.cc
===================================================================
--- /trunk/MagicSoft/Mars/mraw/MRawEvtHeader.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mraw/MRawEvtHeader.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -99,4 +99,6 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
+
 #include "MTime.h"
 #include "MArrayB.h"
@@ -117,5 +119,4 @@
     //   set all member to zero, init the pointer to ClonesArray,
     //
-
     fPixLoGainOn = new MArrayB;
 
@@ -180,4 +181,5 @@
 void MRawEvtHeader::Print(Option_t *o) const
 {
+    *fLog << all;
     *fLog << "DAQEvtNr: " << dec << fDAQEvtNumber << "  (";
     *fLog << "Trigger: ";
@@ -214,7 +216,5 @@
 
     *fLog << endl;
-
     *fLog << endl;
-
 }
 
Index: /trunk/MagicSoft/Mars/mraw/MRawEvtPixelIter.cc
===================================================================
--- /trunk/MagicSoft/Mars/mraw/MRawEvtPixelIter.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mraw/MRawEvtPixelIter.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -143,8 +143,5 @@
 void MRawEvtPixelIter::Draw(Option_t *t)
 { 
-  char *txt = new char[6+strlen(t)];
-  sprintf(txt, "%s%d", t, *fHiGainId);
-  fData->Draw(txt);
-  delete txt; 
+    fData->Draw(Form("%s%d", t, *fHiGainId));
 }
 
Index: /trunk/MagicSoft/Mars/mraw/MRawFileRead.cc
===================================================================
--- /trunk/MagicSoft/Mars/mraw/MRawFileRead.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mraw/MRawFileRead.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -44,4 +44,6 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
+
 #include "MTime.h"
 #include "MParList.h"
@@ -92,14 +94,10 @@
 //
 MRawFileRead::MRawFileRead(const char *fname, const char *name, const char *title)
-    : fFileName(fname)
+    : fFileName(fname), fIn(NULL)
 {
     fName  = name  ? name  : "MRawFileRead";
     fTitle = title ? title : "Read task to read DAQ binary files";
 
-    //
-    // open the input stream
-    //
-    fFileName = fname;
-    fIn = new ifstream(fname);
+    fIn = new ifstream;
 }
 
@@ -132,10 +130,12 @@
 {
     //
+    // open the input stream
     // first of all check if opening the file in the constructor was
     // successfull
     //
+    fIn->open(fFileName);
     if (!(*fIn))
     {
-        *fLog << "Error: Cannot open file '" << fFileName << "'" << endl;
+        *fLog << err << "Error: Cannot open file '" << fFileName << "'" << endl;
         return kFALSE;
     }
@@ -231,14 +231,17 @@
 // --------------------------------------------------------------------------
 //
-//  Checks whether the number of read events differs from the number the
-//  file should containe (MRawRunHeader). Prints a warning if it doesn't
-//  match.
+//  Close the file. Check whether the number of read events differs from
+//  the number the file should containe (MRawRunHeader). Prints a warning
+//  if it doesn't match.
 //
 Bool_t MRawFileRead::PostProcess()
 {
+    //
+    // Sanity check for the number of events
+    //
     if (fRawRunHeader->GetNumEvents() == GetNumExecutions()-1)
         return kTRUE;
 
-    *fLog << "WARNING - number of read events (" << GetNumExecutions()-1;
+    *fLog << warn << "Warning - number of read events (" << GetNumExecutions()-1;
     *fLog << ") doesn't match number in run header (";
     *fLog << fRawRunHeader->GetNumEvents() << ")." << endl;
Index: /trunk/MagicSoft/Mars/mraw/MRawFileWrite.cc
===================================================================
--- /trunk/MagicSoft/Mars/mraw/MRawFileWrite.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mraw/MRawFileWrite.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -130,5 +130,5 @@
     if (!fRawEvtHeader)
     {
-        *fLog << dbginf << "MRawEvtHeader not found... aborting." << endl;
+        *fLog << err << dbginf << "MRawEvtHeader not found... aborting." << endl;
         return kFALSE;
     }
@@ -137,5 +137,5 @@
     if (!fRawEvtData)
     {
-        *fLog << dbginf << "MRawEvtData not found... aborting." << endl;
+        *fLog << err << dbginf << "MRawEvtData not found... aborting." << endl;
         return kFALSE;
     }
@@ -144,5 +144,5 @@
     if (!fRawCrateArray)
     {
-        *fLog << dbginf << "MRawCrateArray not found... aborting." << endl;
+        *fLog << err << dbginf << "MRawCrateArray not found... aborting." << endl;
         return kFALSE;
     }
@@ -151,5 +151,5 @@
     if (!fRawEvtTime)
     {
-        *fLog << dbginf << "MRawEvtTime not found... aborting." << endl;
+        *fLog << err << dbginf << "MRawEvtTime not found... aborting." << endl;
         return kFALSE;
     }
@@ -158,5 +158,5 @@
     if (!fRawRunHeader)
     {
-        *fLog << dbginf << "MRawRunHeader not found... aborting." << endl;
+        *fLog << err << dbginf << "MRawRunHeader not found... aborting." << endl;
         return kFALSE;
     }
@@ -254,6 +254,6 @@
     }
 
-    *fLog << dbginf << "Got wrong number for the trigger type: " << type;
-    *fLog << "  - skipping" << endl;
+    *fLog << warn << dbginf << "Got wrong number for the trigger type: " << type;
+    *fLog << " - skipped" << endl;
 
     return kCONTINUE;
Index: /trunk/MagicSoft/Mars/mraw/MRawRunHeader.cc
===================================================================
--- /trunk/MagicSoft/Mars/mraw/MRawRunHeader.cc	(revision 1081)
+++ /trunk/MagicSoft/Mars/mraw/MRawRunHeader.cc	(revision 1082)
@@ -16,5 +16,5 @@
 !
 !
-!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!   Author(s): Thomas Bretz  12/2000 <mailto:tbretz@uni-sw.gwdg.de>
 !
 !   Copyright: MAGIC Software Development, 2000-2001
@@ -37,4 +37,6 @@
 
 #include "MLog.h"
+#include "MLogManip.h"
+
 #include "MArrayS.h"
 
@@ -79,5 +81,5 @@
     if (fMagicNumber != kMagicNumber)
     {
-        *fLog << "Error: Wrong Magic Number: Not a Magic File!" << endl;
+        *fLog << err << "Error: Wrong Magic Number: Not a Magic File!" << endl;
         return;
     }
@@ -122,5 +124,5 @@
 void MRawRunHeader::Print(Option_t *t) const
 {
-    *fLog << endl;
+    *fLog << all << endl;
     *fLog << "MagicNumber:  0x" << hex << fMagicNumber << " - " << (fMagicNumber==kMagicNumber?"OK":"Wrong!") << endl;
     *fLog << "Version:      " << dec << "Format=" << fFormatVersion << "  ";
