Garry's Mod Wiki

Garry's Mod Wiki

  Panel:SizeToContents()

Description

Resizes the panel so that its width and height fit all of the content inside.

Only works on Label derived panels such as DLabel by default, and on any panel that manually implemented the Panel:SizeToContents method, such as DNumberWang and DImage.
You must call this function AFTER setting text/font, adjusting child panels or otherwise altering the panel.

This site is a community mirror of the official Garry's Mod wiki.. This site is not maintained by Facepunch Studios.

Page content is automatically updated four times a day. Edits and history are not available.

Last Parsed: Loading...