Greek symbols on GIF files

From: Rene Brun (Rene.Brun@cern.ch)
Date: Mon Apr 06 1998 - 08:26:47 MEST


Sean Kincaid wrote:
> 
> There is a world of symbols/greek letters that we can
> get for postscript files, but is there a way to get those
> symbols/letters for the creation of gif files?
> 
> Thanks,
> Sean Kincaid

Hi Sean,
Root does not support (yet) the interpretation of Postscript
special symbols on the screen or GIF files.
What you can do is to generate the ps file, then convert this file
into gif format using standard utilities.

The macro togif.C below illustrates how to do it.

Rene Brun

// this macro illustrates how to make a GIF file with a canvas
// containing greek characters. (Unix only)
void togif()
{
   // execute the Root tutorial macro psexam.
   // this macro shows how to use Postscript special symbols.
   gROOT->Macro("$ROOTSYS/tutorials/psexam.C");

   // make a Postscript eps file from the default canvas c1
   char file[] = "psexam";
   char cmd[100];
   sprintf(cmd,"%s.eps",file);
   c1.Print(cmd);

   // convert the eps file into a GIF file. On Unix systems, this can be
done
   // via 2 standard utilities found in /usr/local/bin/X11
   sprintf(cmd,"pstopnm -ppm -xborder 0 -yborder 0 -portrait
%s.eps",file);
   gSystem->Exec(cmd);
   sprintf(cmd,"ppmtogif %s.eps001.ppm >%s.gif",file,file);
   gSystem->Exec(cmd);
}



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