I often use hexadecimal color codes and convert them to TColor using TColor::GetColor (const char *hexcolor) [1] for coloring TH1, TGraph, etc. However, when I store the histograms or graphs in a root file and try to draw them later, they appear invisible, i.e. the color is forgotten. How can I make sure that the color is also stored in the root file and used automatically?
Is there a more flexible/portable/shareable/self-contained version of this? i.e. not sending everyone your rootlogon.C file so they can work with the same plots.
Not really. The Colors are not stored on purpose. They might be a lot of them and we cannot afford storing them in the root file. Colors should be redefined.