How can i find a disabled TsEdit's color ? TsSkinManager's GetActiveEditColor returns TsEdit's normal color not disabled color. I was look gd[index], ma[index] etc. but i couldn't find it.
Note: I dont want to send a message to control for find a color.
For example; just imagine that TsEdit is disabled state
…
var
ActiveColor,
DisabledColor : TColor;
begin
ActiveColor := SkinManager.GetActiveEditColor;
DisabledColor := ??
end;
i was tried following;
var
R,G,B, Gray : Byte;
ActiveColor,
DisabledColor : TColor;
begin
ActiveColor := SkinManager.GetActiveEditColor;
R := GetRValue(ActiveColor);
G := GetGValue(ActiveColor);
B := GetBValue(ActiveColor);
Gray := (R + G +
Hello
Sorry for delay, I'm not always here
So, disabled edit haven't constant color, because control is alphablended.
For some skins this color will not be changed and may be calculated, but in many skins this color depended from a color of parent :
[attachment=3334:disedit.png]
So, solution depends from a your task.
Try this code for receiving average color between active edit and main skin color :
CODE
uses sGraphUtils, sDefaults;
Color := MixColors(SkinManager.GetActiveEditColor, SkinManager.GetGlobalColor, DefDisabledBlend);
Maybe it helps.