Re: TPad based legend shown on screen and eps, not png/gif.

From: Valeriy Onuchin <Valeri.Onoutchine_at_cern.ch>
Date: Thu, 19 May 2005 21:00:02 +0200


Hi Brett,
strange ... no idea yet why it's happend. Be fixed asap. However the following solution can help:

TImageDump *di = new TImageDump("test.png"); c1->Paint();
di->Close();

You can do it even in batch mode.

Regarda. Valeriy

Brett Viren wrote:

> Hi,
>
> I'm using yesterday's ROOT CVS and I have a macro that uses a TPad to
> hold a custom-built legend made from TPaveText's and TMarker/TLine's
> which is then placed on top of my plot. The resulting canvas shows
> the legend as does printing it (via TCanvas::Print) to EPS, but
> printing to gif/png lacks it.
>
> Any ideas?
>
> I've tried to distil the code down to a smallish example macro. It
> and the three output files are here (30KB) :
>
> http://minos.phy.bnl.gov/~bviren/cern/root/test_legend.tgz
>
> This is on Debian x86, GCC 3.3.5. I've not been generating .gif or
> .png until now so can't say when this started happening.
>
> Thanks for any help,
> -Brett.
Received on Thu May 19 2005 - 21:00:10 MEST

This archive was generated by hypermail 2.2.0 : Tue Jan 02 2007 - 14:45:08 MET