window at mouse pointer


hi all,

is it possible to create a window at mouse pointer?


you can use the draggerContext command to get the mouse position, which you could then feed to the window -tlc flag to build a window at a specific point. However this only works on a viewport, so you wouldn’t be able to do this wherever you liked (i.e. over another UI).

You can get more complex mouse info/functionality from the API via python though, but I can’t tell you much about doing it that way…



thanks NaughtyNathan

but that does’nt work.

correct me if i m wrong

i think there are two different spaces 1. screen space and 2. UI space

both r having different coordinates. context is working on screen & window is on UI

that is the reason i m not getting window at mouse position


If you’re relying on mel I cant help, but if you have no problem doing it with python - you just need to install ‘xlib’ package and than just use this:

[li]from Xlib import X, display[/li][li]d = display.Display().screen().root.query_pointer()._data[/li]
[li]print "x="[/li][li]print d["root_x"][/li][li]print "y="[/li][li]print d["root_y"][/li][/ol]

oops, forgot to mention it’s for linux only


This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.