Garry's Mod Wiki

Revision Difference

DAlphaBar#514229

<panel>⤶ <name>DAlphaBar</name>⤶ <parent>DPanel</parent>⤶ <description>A bar to select the opacity (alpha level) of a color.</description>⤶ ⤶ </panel>⤶ ⤶ ⤶ <example>⤶ <description>Creates a DAlphaBar and sets its value to 25%.</description>⤶ <code>⤶ local DAlphaBar = vgui.Create( "DAlphaBar" )⤶ DAlphaBar:SetPos( 20, 30 )⤶ DAlphaBar:SetSize( 25, 125 )⤶ DAlphaBar:SetValue( 0.25 )⤶ DAlphaBar.OnChange = function( newvalue )⤶ print( "DAlphaBar value changed to " .. newvalue )⤶ end⤶ </code>⤶ ⤶ </example>⤶ ⤶