This setting is stored in HKEY_CURRENT_USER\Control Panel\Desktop\UserPreferencesMask. The registry value itself is a binary value that represents a bitmask of various settings.
Its format is documented here
Unfortunately this document is a bit oudated and does not contain information about this particular setting. By experimenting with this value I have found that the settins is stored in bit 32. When this bit is on, input switches for each application separately.
Example of HKEY_CURRENT_USER\Control Panel\Desktop\UserPreferencesMask with setting on:
9e 1e 07 80 92 00 00 00
With setting off:
9e 1e 07 80 12 00 00 00
Here is a Powershell script example to turn it on:
$prefMask = (Get-ItemProperty -Path 'HKCU:\Control Panel\Desktop' -Name 'UserPreferencesMask').UserPreferencesMask
if (($prefMask[4] -band 0x80) -eq 0) {
$prefMask[4] = ($prefMask[4] -bor 0x80)
New-ItemProperty -Path 'HKCU:\Control Panel\Desktop' -Name 'UserPreferencesMask' -Value $prefMask -PropertyType ([Microsoft.Win32.RegistryValueKind]::Binary) -Force | Out-Null
}
Was tested on quite a bunch of win8.1 machines (both x86 and x64) and appears to work as expected.
Note that the setting takes effect immediately, but displays wrong in language panel settings dialog. So you need to logoff and logon back for panel settings to pick up the change.