# Panel:SetCursor

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

```lua
Panel:SetCursor( string cursor )
```

## Açıklama

İmlecin görünümünü ayarlar. Mevcut tüm imleçlerin resimli önizlemeleriyle birlikte bir listesini [burada](https://gmod.tr/wiki/Cursors) bulabilirsiniz.

## Argümanlar

1. [string](https://gmod.tr/wiki/string) **cursor**: Ayarlanacak imleç. Aşağıdakilerden biri olabilir: - [arrow](https://gmod.tr/wiki/Cursors#:~:text=arrow) - [beam](https://gmod.tr/wiki/Cursors#:~:text=beam) - [hourglass](https://gmod.tr/wiki/Cursors#:~:text=hourglass) - [waitarrow](https://gmod.tr/wiki/Cursors#:~:text=waitarrow) - [crosshair](https://gmod.tr/wiki/Cursors#:~:text=crosshair) - [up](https://gmod.tr/wiki/Cursors#:~:text=up) - [sizenwse](https://gmod.tr/wiki/Cursors#:~:text=sizenwse) - [sizenesw](https://gmod.tr/wiki/Cursors#:~:text=sizenesw) - [sizewe](https://gmod.tr/wiki/Cursors#:~:text=sizewe) - [sizens](https://gmod.tr/wiki/Cursors#:~:text=sizens) - [sizeall](https://gmod.tr/wiki/Cursors#:~:text=sizeall) - [no](https://gmod.tr/wiki/Cursors#:~:text=no) - [hand](https://gmod.tr/wiki/Cursors#:~:text=hand) - [blank](https://gmod.tr/wiki/Cursors#:~:text=blank) Varsayılan geri dönüş olan "none" olarak ayarlamak için başka bir şeye ayarlayın. Unutmayın ki, "none" değeri sanıldığı gibi imlecin hiç çizilmemesi anlamına gelmez - imleci gizlemek için bunun yerine "blank" değeri gereklidir.

### Örnek

```lua
function draw.CustomCursor(panel, material)
	-- Özel imleci çizer
	local cursorX, cursorY = panel:LocalCursorPos()

	surface.SetDrawColor(255, 255, 255, 240)
	surface.SetMaterial(material)
	surface.DrawTexturedRect(cursorX, cursorY, 20, 20)
end

local myPanel = vgui.Create("DFrame")
myPanel:SetCursor("blank") -- Varsayılan imlecin kaybolmasını sağlar

local customCursorMaterial = Material("vgui/your_cursor")
myPanel.Paint = function(s, w, h)
	draw.CustomCursor(s, customCursorMaterial)
end
```

![cursor.png](https://gmod.tr/api/uploads/wiki/dc05f043a59a38afb74b.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:SetCursor
