What are the variables needed to access focus properties in split screen view?
I've been searching for this answer for years, and I've become very good at tracking down hidden functionality... To no avail unfortunately. Apple has no mechanism for doing anything with spaces programmatically. The only facility I found is by running the defaults command and (under one of the defaults whose name I can't recall at the moment) there is an area that'll give you cryptic window numbers and the spaces they belong to. The issue is that list isn't updated live, so it isn't really that useful. I'm still searching, but I'm fairly certain there is no Apple-approved way to interact with spaces, or split screen, or any of its other manifestations.

EDIT: Oh yes, it's "com.apple.spaces". Run the command defaults read com.apple.spaces in the terminal to get to what I was talking about.

EDIT2: Also, there's a way to activate spaces with a little bit of C code:

CoreDockSendNotification(CFSTR("com.apple.expose.awake"));
CoreDockSendNotification(CFSTR("com.apple.expose.front.awake"));
CoreDockSendNotification(CFSTR("com.apple.showdesktop.awake"));


Each of these lines will make mission control do stuff, not that it's all that useful. There are other ways to do this...