use of macros, log scale

From: Otto Schaile (Otto.Schaile@Physik.uni-muenchen.de)
Date: Mon May 12 1997 - 10:06:13 MEST


Dear roots,

probably a beginners question:

I have a (simplified) macro:
------------------------------------------------------------
#include <iostream.h>
int t1 (const char* b_node="etphp02")
{
  gROOT->Reset();
  cv1 = new TCanvas("cv1","Backup history",100,100,600,600);
//  and so on 
}
---------------------------------------------------
typing .x t1.C works

I would like to call it from a control panel:
-----------------------------------------------------
{
   gROOT->Reset("a");
   bar = new TControlBar("vertical");
   bar->AddButton("t1",    ".x t1.C()", "Blabla");
   bar->Show();
   gROOT->SaveContext();
}
--------------------------------------------------------------
this o n l y works if I call directly from the command line before
using it from the control bar. What do I have to put in addition?

======================

Unrelated to this: Is there a way to have log scales when drawing 
                   histograms?

Cheers,


----------------------------------------------------------------------------
Otto Schaile                    Sektion Physik der LMU Muenchen
Phone: (+49 89)289 14070        Am Coulombwall 1, D-85748 Garching, Germany
FAX:   (+49 89)289 14072        EMail: Otto.Schaile@Physik.Uni-Muenchen.DE



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:26:18 MET