AutoHotKey Script - activate blender window under cursor

Windows 10 has a function build in to activate the window which is under the cursor automatically but if you use blender with multiple (popout) windows it doesnt toggle the main blender window somehow. Edit: As a user reported the same faulty behaviour is also on mac.

the reason is that blender windows have no unique window class , just a ghost class, most of the other programs have defined window classes like “Chrome_WidgetWin” or “MozillaWindowClass_widget”…
anybody up to make a bug report on blender developers with this ?

anyways , ive written a simple auto hotkey script to kinda hack it on top , with this the blender windows are activated automatically. its not a good script for every program because it also raises the window to the front , but since i use blender windows only in fullscreen mode and popout windows automatically hover over the main window it works very nice in this case.

With this you can go with mouse from one window to another in multimonitor setup and can directly use shortcuts without having to click the window before.

4 Likes

edit: complete re-wright lol , it introduced some other problems , which i now fixed the best i can. but ohh my shitlord , its so jarring working around a bug.

can anybody help me setup a working build environment for blender ? i think its better fixed in the sourcecode than this. until then its the best i can muster up

1 Like

Thank you very much for creating this… this is really helpfull !

update:

  • it works only between the windows of one blender instance now , no accidental swapping between different blender instances
  • small performance enhancement (it was always at 0% cpu anyways lol)

As of blender 3.6 alpha (beginning of march) a similar behaviour is build into blender.

Blender’s solution has the same problem as mine does → the console accidently vanishes behind the other windows.

Thats why i wrote an additional script which sets “always on top” for any console window a blender.exe process might spawn. Same link as OP.