:GetTall() not returning anything on wrapped DLabel
0 replies, posted
Hello there!
I am using a DLabel with wrap and I used DLabel:SetAutoStretchVertical(true) so the height is automatically set, when I try to get the height of the label panel it returns 0 (the height set with :SetSize()), so it appears that it does not set the actual height of the DLabel for some reason... Am I missing something?
If I try to paint the DLabel the height in the argument is correct as-well. I don't know why it is not working :/
local desc = isp:Add("DLabel")
desc:SetSize(isp:GetWide()-40, 0)
desc:SetColor(color_white)
desc:SetFont("nutSmallFont")
desc:SetText(info.desc)
desc:SetAutoStretchVertical(true)
desc:SetWrap(true)
desc:SetPos(0, 20 + rankTitle:GetTall()+10)
desc:CenterHorizontal()
function desc:Paint(w,h)
draw.RoundedBox(0, 0, 0, w, h, Color(255,0,0))
end
Thanks for the support in advance,
Cheers!
Sorry, you need to Log In to post a reply to this thread.