Derma and parenting

Hello, my question would be: how is it possible to parent a derma element (with :SetParent()) to the mouse?

not relay, you wil need some code for it,

first you get the window pos



local windowpos = window:GetPos() -- tha mighty window pos!
local mousepos = gui.MousePos() -- the ugly pointer!

local addpos = {x = mousepos.x - windowpos.x, y = mousepos.y - windowpos.y} -- calculates how much space is between them!

window:SetPos(mousepos + addpos) -- simply calcuate the 2 numbers

-- Shine and rise Mr. Freemen