[ROOT] Problems with new multi-page print method.

From: Brett Viren (bv@bnl.gov)
Date: Wed Aug 28 2002 - 19:47:50 MEST


Hi, 

I am using ROOT 3.03/08 from CVS ca. 8/26) GhostScript 6.0 via GV
3.5.8 on Debian x86, GCC 3.0.4.

I am trying to use the new multi-page TPad::Print method but get odd
behavior.  In viewing a 3 page output, as I go down the pages in GV I
see:

	page 1 blank
	page 2 okay
	page 3 okay
	page 2 okay
	page 1 okay
	page 2 blank
	page 3 HUGE zoom of lower right corner
	page 2 same
	page 1 same
	page 2 same
	page 3 blank
	page 2 HUGE zoom of lower right corner
	etc.

Appended is some test code (am I using the feature correctly?) and
attached is the PS file.

-Brett.

// test_hist.C
//
// run like: root test_hist.C
//    needs: hsimple.root from root/test in CWD
//  creates: test.ps
//
TCanvas* canvas=0;
TFile* hist_file=0;

void plot_one ()
{
//    canvas->Clear();        // no effect
    TH2D* hpxpy = hist_file->Get("hpxpy");
    hpxpy->Draw("colz");
}

void test_hist ()
{
    hist_file = new TFile("hsimple.root");

    gStyle->SetOptStat(0);
    canvas = new TCanvas("test","test",1100,850);

    canvas->Print("test.ps(");
    plot_one();
    canvas->Print("test.ps");
    plot_one();
    canvas->Print("test.ps");
    plot_one();
    canvas->Print("test.ps)");

    delete canvas;
    canvas=0;
}






This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:51:06 MET