0

How can I determine the background color of a TTabSheet when running on a OS with themes like XP and above?

Heinz Z.
  • 1,537
  • 3
  • 14
  • 29

1 Answers1

5

I would try GetThemeColor.

Edit: But note that tab sheets have a gradient under standard XP theming, so a single color probably is not what you need.

Uli Gerhardt
  • 13,748
  • 1
  • 45
  • 83
  • Thanks, although it is not what I want to hear. I placed a TForm on this tabsheet and would change the color of it to the color of tabsheet. After your answer, I think it is easier to make the form transparent. – Heinz Z. Feb 03 '10 at 11:27
  • 1
    And when I use TFrame instead of TForm it works like I wish (after a first look). – Heinz Z. Feb 03 '10 at 11:39
  • 1
    Frames have their problems, but I think they are just better suited as "subforms" than TForms are. (Probably because that's their reason of being. :-)) – Uli Gerhardt Feb 03 '10 at 12:03