DListView_Column:SetFixedWidth

  DListView_Column:SetFixedWidth( number width )

Açıklama

Sütunun sabit genişliğini ayarlar.

Dahili olarak bu, SetMinWidth ve SetMaxWidth değerlerini sağlanan değere ayarlar.

Argümanlar

1 number width
Sabit bir genişlik belirleyecek olan sayısal değer.

Örnek

Bir DListView oluşturur ve bunu iki sütun ve iki öğe ile doldurur; aynı anda yalnızca biri seçilebilir.

İlk sütun, ikinci sütundan daha uzun olacaktır.

local Frame = vgui.Create( "DFrame" ) Frame:SetSize( 500, 500 ) Frame:Center() Frame:MakePopup() local SimpleList = vgui.Create( "DListView", Frame ) SimpleList:Dock( FILL ) SimpleList:SetMultiSelect( false ) SimpleList:AddColumn( "Column 1" ) SimpleList:AddColumn( "Column 2" ):SetFixedWidth(125) SimpleList:AddLine( "First", "Column" ) SimpleList:AddLine( "Second", "Column" )
Çıktı:

Tüm sunucular · GmodTR Launcher · Rehber · GMod Wiki · GmodTR nedir? · Sunucu ekle · Discord