# DShape

- **Ortam:** İstemci
- **İngilizce aslı:** https://wiki.facepunch.com/gmod/DShape
- **Çeviri tarihi:** 2025-09-08

## Açıklama

Bir derma paneli üzerine bir şekil çizer. Kullanılabilen tek şekil türü bir dikdörtgendir.

[Kaynağı görüntüle](https://github.com/Facepunch/garrysmod/blob/master/garrysmod/lua/vgui/dshape.lua)

## Ebeveyn

Bu sayfada listelenmeyen metotları vb. [DPanel](https://gmod.tr/wiki/DPanel)'dan türetir.

## Metotlar

[table](https://gmod.tr/wiki/table) DShape:[GetBorderColor](https://gmod.tr/wiki/DShape:GetBorderColor)()

Panelin görüntülemek üzere ayarlandığı mevcut şekil türünü döndürür. Bkz. DShape:SetBorderColor.

[table](https://gmod.tr/wiki/table) DShape:[GetColor](https://gmod.tr/wiki/DShape:GetColor)()

Şekli görüntülemek için ayarlanan rengi döndürür.

[string](https://gmod.tr/wiki/string) DShape:[GetType](https://gmod.tr/wiki/DShape:GetType)()

Panelin görüntülemek üzere ayarlandığı mevcut şekil türünü döndürür. Bkz. DShape:SetType.

DShape:[SetBorderColor](https://gmod.tr/wiki/DShape:SetBorderColor)( [table](https://gmod.tr/wiki/table) clr )

Şeklin kenarlık rengini ayarlar. Şu anda hiçbir şey yapmaz.

DShape:[SetColor](https://gmod.tr/wiki/DShape:SetColor)( [table](https://gmod.tr/wiki/table) clr )

Şekli görüntülemek için kullanılacak rengi ayarlar.

DShape:[SetType](https://gmod.tr/wiki/DShape:SetType)( [string](https://gmod.tr/wiki/string) type )

Çizilecek şekli ayarlar.

### Örnek

Küçük bir açılır pencere çerçevesi içinde DShape dikdörtgeni oluşturur

```lua
local Frame = vgui.Create( "DFrame" ) -- Bir çerçeve oluştur
Frame:SetTitle( "Test panel" )
Frame:SetSize(400,400)
Frame:Center()
Frame:MakePopup()

local Shape = vgui.Create( "DShape", Frame )
Shape:SetType( "Rect" ) -- Olabileceği tek tür budur
Shape:SetPos( 100, 100 )
Shape:SetColor( Color(0, 255, 0, 255) )
Shape:SetSize( 200, 200 )
```

**Çıktı:** ![](https://gmod.tr/api/uploads/wiki/fcfeb412c8aed137fec8.png)

- [GMod Wiki ana sayfası](https://gmod.tr/wiki)

---

[Tüm sunucular](https://gmod.tr/) · [GmodTR Launcher](https://gmod.tr/launcher) · [Rehber](https://gmod.tr/rehber) · [GMod Wiki](https://gmod.tr/wiki) · [GmodTR nedir?](https://gmod.tr/hakkinda) · [Sunucu ekle](https://gmod.tr/sunucu-ekle) · [Discord](https://discord.gg/gmodtr)

Kaynak: https://gmod.tr/wiki/DShape
