/SUBSYSTEM option. java.exe and javaw.exe, the script host comes with cscript.exe and wscript and devenv has devenv.com and devenv.exe etc. mch_is_gui_executable() in src/os_win32.c that determines the subsystem of the running vim executable/DLL: int
mch_is_gui_executable(void)
{
PBYTE pImage = (PBYTE)GetModuleHandle(NULL);
PIMAGE_DOS_HEADER pDOS = (PIMAGE_DOS_HEADER)pImage;
PIMAGE_NT_HEADERS pPE;
if (pDOS->e_magic != IMAGE_DOS_SIGNATURE)
return FALSE;
pPE = (PIMAGE_NT_HEADERS)(pImage + pDOS->e_lfanew);
if (pPE->Signature != IMAGE_NT_SIGNATURE)
return FALSE;
if (pPE->OptionalHeader.Subsystem == IMAGE_SUBSYSTEM_WINDOWS_GUI)
return TRUE;
return FALSE;
}
smss.exe (Windows Session Manager) Required under registry key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\SubSystems.