DY0
7 discussion posts
I'm trying to use DisplayFusion to create 8 "zones" on my 2 monitors. Whenever I open a new window of a program, I want it to send it to the first zone that is unoccupied, i.e. it checks to see if the zone has a window of the program already running in it. If it doesn't, it places it in the zone and resizes itself to fill the zone and if it does, sends it to the next available zone. I searched the forums for something like this and found "open notepad in position A or B", but that appears to be for 2 windows and not up to 8. Can anyone help me in scaling this code to include more windows and zones?
Have you setup the 8 zones using Monitor Splitting? We may be able to write up a sample script for you.
Thanks!
DY0
7 discussion posts
Hi Keith,
That would be great! As a more manual workaround currently, I assigned 8 functions with hotkeys that send the window to these designated zones (specified by X Y positions and length/width), each 25% of the screen but with a 1 pixel overlap. I tried using the monitor splitting for this, but didn't like the 1 pixel gap between my windows that appeared, hence using the specific positions with a tiny overlap.
However, if you could script and automate this process, I'd have no problem with the 1 pixel gap. Let me know if I need to provide any more details!
I think we could do a script without monitor splitting too. Could you send me the EXE name for the app you want moved, and the X,Y,Width, and Height values for the 8 zones?
DY0
7 discussion posts
Thanks, the file name is BovadaPoker.exe but once it executes and starts running, Task Manager shows the file name as Lobby.exe. It's a client for a poker site and I essentially open new game tables from the lobby. I'm trying to get it to configure my tables in a certain way once they open so I don't have to do it manually, if that makes sense. Not sure how that might change the viability of creating this code.
Each table has width 963 and height 521.
My zones are:
Zone 1 X: -1 Y: 0
Zone 2 X: 960 Y: 0
Zone 3 X: -1 Y: 521
Zone 4 X: 960 Y: 520
Zone 5 X: -964 Y: 0
Zone 6 X: -1927 Y: 0
Zone 7 X: -964 Y: 520
Zone 8 X: -1927 Y: 520
Thanks! I've uploaded a script to the repository called "Move application to first available zone." It's already got your positions in it, but you'll need to change "notepad.exe" on line 27 to "Lobby.exe".
After downloading the script and making that change, apply the DF settings. Then create a Trigger rule for Lobby.exe and have the rule run the "Move application to first available zone" function.
Hope that helps!
DY0
7 discussion posts
Keith,
Thanks! I followed your instructions, downloaded the code, and it works great. If I have multiple programs that I want included in this function without creating a rule for each one, is there a quick add for line 27? Or should I just create a different trigger and function for each one?
Glad to hear it! Do you want the other apps to skip a zone if it's already in use by one of the other apps? For example, if it was Notepad and Calculator, if Notepad is in zone 1, and you launch Calculator, do you want it to skip zone 1 and move to zone 2?
DY0
7 discussion posts
Yes, I would like it to skip a zone if that's possible.
DY0
7 discussion posts
It would be the former - if one of the specified applications is in the zone.
Ok, I'll see what I can do!
Ok, give the attached one a try. If it works, I'll post it to the repository as well.