Spin-polarized electron gun for electron spectroscopies