Garry's Mod Wiki

Revision Difference

DPanel:GetBackgroundColor#550516

<function name="GetBackgroundColor" parent="DPanel" type="panelfunc"> <ispanel>yes</ispanel> <description> Returns the panel's background color. <note>By default this returns **nil** even though the default background color is white</note> </description> <realm>Client</realm>⤶ <realm>Client and Menu</realm>⤶ <rets> <ret name="" type="table">Color of the panel's background.</ret> </rets> </function> <example> <description>Prints out the default panel background color.</description> <code> BGPanel = vgui.Create("DPanel") BGPanel:SetPos(20, 20) BGPanel:SetSize(200, 200) print(BGPanel:GetBackgroundColor()) </code> <output>nil</output> </example>