Returns the overall opacity of the frame. Unlike
:GetAlpha() which returns the opacity of the frame relative to its parent, this function returns the absolute opacity of the frame, taking into account the relative opacity of parent frames.
Signature:
Code
alpha = Frame:GetEffectiveAlpha()
Returns:
- alpha - Effective alpha (opacity) of the region (0.0 = fully transparent, 1.0 = fully opaque) (number)
Examples:
CreateFrame("Frame","Frame1", UIParent)
Frame1:SetAlpha(0.5)
CreateFrame("Frame","Frame2", Frame1)
Frame2:SetAlpha(0.2)
CreateFrame("Frame","Frame3", Frame2)
Frame3:SetAlpha(0.25)
UIParent:GetEffectiveAlpha()
-- returns 1
Frame1:GetEffectiveAlpha()
-- returns approximately 0.5
Frame2:GetEffectiveAlpha()
-- returns approximately 0.1
Frame3:GetEffectiveAlpha()
-- returns approximately 0.025