# Panel:DockMargin

- **Ortam:** İstemci, Menü
- **İngilizce aslı:** https://wiki.facepunch.com/gmod/Panel:DockMargin
- **Çeviri tarihi:** 2025-09-08

```lua
Panel:DockMargin( number marginLeft, number marginTop, number marginRight, number marginBottom )
```

## Açıklama

Panelin yerleştirme kenar boşluğunu (dock margin) ayarlar.

Yerleştirme kenar boşluğu, bu element ana elementinin içine yerleştirildiğinde kenarında bırakılacak olan ek boşluktur.

## Argümanlar

1. [number](https://gmod.tr/wiki/number) **marginLeft**: Ana elemente olan sol kenar boşluğu.
2. [number](https://gmod.tr/wiki/number) **marginTop**: Ana elemente olan üst kenar boşluğu.
3. [number](https://gmod.tr/wiki/number) **marginRight**: Ana elemente olan sağ kenar boşluğu.
4. [number](https://gmod.tr/wiki/number) **marginBottom**: Ana elemente olan alt kenar boşluğu.

### Örnek

DockMargin ve DockPadding'in etkilerini gösteren örnek

```lua
local frame = vgui.Create("DFrame")
frame:SetSize(600, 300)
frame:SetTitle("Docking Demonstration")
frame:Center()
frame:MakePopup(true)

local panel = vgui.Create("DPanel", frame)
panel:DockMargin(10, 20, 30, 40)
panel:DockPadding(40, 30, 20, 10)
panel:Dock(FILL)

local button = vgui.Create("DButton", panel)
button:SetText("Lopsided proportions!")
button:Dock(FILL)
```

**Çıktı:** ![](https://gmod.tr/api/uploads/wiki/1dffbc9466082f3c9a3b.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/Panel:DockMargin
