[ROOT-6841] TLegend Fill Color in TexDump Mode Created: 22/Oct/14  Updated: 23/Oct/14  Resolved: 23/Oct/14

Status: Closed
Project: ROOT
Component/s: Graphics
Affects Version/s: 5.34/21, 6.02/01
Fix Version/s: None

Type: Bug Priority: Medium
Reporter: Jean-François Caron Assignee: Olivier Couet
Resolution: Fixed Votes: 0
Labels: None
Environment:

OSX 10.9.5


Attachments: File doc.tex     File doc.tex     File make_plot.py     File make_plot.py    
Development:

 Description   

When saving a canvas using c1.SaveAs("foo.tex"), if a TLegend is present, the fill style for the legend icons is not respected, they are always black. The attached files should fully illustrate what is going on. You can run it as follows:
python make_plot.py
pdflatex plot.tex

Then look at the resulting pdf file. The legend icons are black, even though the objects in the legend have their FillColor set to 0.



 Comments   
Comment by Olivier Couet [ 22/Oct/14 ]

I'll check. But it could be that TeX graphics does not support the fill styles.

Comment by Jean-François Caron [ 22/Oct/14 ]

I tried changing the h and g objects in make_plot.py into TH1D and the problem goes away (i.e. the legend icon fill style is white).

Comment by Jean-François Caron [ 22/Oct/14 ]

I tried also with TGraphs, it looks like the problem it might be specific to TF1 entries in a TLegend... I will attach a new script & doc that illustrates.

Comment by Jean-François Caron [ 22/Oct/14 ]

New script & doc file to illustrate. Run "python make_plot.py" then "pdflatex doc.tex".

Comment by Olivier Couet [ 23/Oct/14 ]

Fixed in 5.34-patches 6.02-patches and root-trunk (6)
Thanks for reporting.

Generated at Sat Sep 21 06:38:50 CEST 2019 using Jira 7.13.1#713001-sha1:5e06076c2d215a6f699b7e5c90ab2fae7ba5a1ce.