Canvas->SaveAs(*.ps) Does not show Latex symbols

Hi rooters,

I am trying to save a canvas that is divided

c->Divide(2,5);

When I try either of the following

c->SaveAs("img.jpg");
c->SaveAs("img.png");

The output picture looks messy and the pads over lap. What works is saving it as .ps, the pads look good and with high resolution. However, all Latex symbols (theta, delta…etc) are not shown in the saved picture but are shown in the canvas.

Is there a way to save the picture in high resolution, and have the symbols showing?
(I am using root 5.34/36)

Thanks!

Sharey

Can you post a small example of the issue?

sure!

Attached are the output as *.jpeg and .ps ( had to convert ps to jpg because the website doesn’t support .ps)

Thanks, but I meant a small example of code that we can run.

Sorry I misunderstood. The code is long and reading from several root files. The canvas shows a good results but I have a saving issue

It will be difficult to debug without the smallest example that reproduces the problem.

Hi,

I wrote a code just for filling the pads. The same issue

rootforum.C (3.2 KB)

I ran your example and I do not see the missing symbol in the ps file. I am using root 6 (master version) on mac. Note that the png file looks nice for me.

On your output I see that the missing character is #theta , It should work even with an old root version. Can you send the ps file ?

Hi, I couldn’t upload the ps file on this website. However, the second attachment from the previous post is the ps file but converted to jpg

I wanted the ps file to see its internal and try to understand what it there for #theta.
May be try to change the file name extension in order to upload it ?

Having the code running for you made me try running it in root 6 and it worked!
I am working on a computer cluster for work, so I decided to run the code on my desktop with root 5 and again it worked :confused:
It seems that something is going on with saving the ps files and converting them to pdf when using root 5 on work machines.
Attached is what I got. Thanks!!

May be the conversion utility you used to go to pdf has a problem.
Good you found a solution.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.