reduce buffer lookup by Windows

Perform lookup once per edit session instead of once per edit command.