Electron scattering studies of BF and BF2