Just trying to set manually a TButton with client styles turned off to match Tab settings. I just can't seem to get the fill color for ttTabItemNormal and ttTabItemHot, is this possible ?
Just trying to set manually a TButton with client styles turned off to match Tab settings. I just can't seem to get the fill color for ttTabItemNormal and ttTabItemHot, is this possible ?
e.g.
LDetails := StyleServices.GetElementDetails(ttTabItemNormal);
StyleServices.GetElementColor(LDetails, ecFillColor, .FNormalColor);
StyleServices.GetElementColor(LDetails, ecTextColor, FFontNormalColor);
e.g.
LDetails := StyleServices.GetElementDetails(ttTabItemNormal);
StyleServices.GetElementColor(LDetails, ecFillColor, .FNormalColor);
StyleServices.GetElementColor(LDetails, ecTextColor, FFontNormalColor);
Just had a moment to step into the functions.
ReplyDeleteLooks like Vcl.Styles function for GetElementColor() does nothing if you dont have ecTextColor set
Unfortunately you can't get the colors of the tabs used because these are drawn using the bitmap linked to the current element (ttTabItemSelected, ttTabItemHot, ttTabItemNormal), Only the text color of the tabs can be retrieved by using the GetElementColor function.
ReplyDeleteRodrigo Ruz thanks, that explains what I was reading when stepping into the code
ReplyDelete