Ultrafast scanning electron microscope (USEM) integrates pump-probe technique with microscopic imaging, enabling visualization of photon-induced surface charge dynamics with high spatial and temporal resolution. This capability is crucial for high-resolution detection of semiconductor surface states and optoelectronic devices. This work discusses the parametric design of a thermionic emission electron gun that has been modified into a photoemission electron gun, based on a home-built ultrafast scanning electron microscope. The transition to photoemission requires the removal of the self-bias voltage function of the original electron microscope power supply to ensure proper operation of the wehnelt electrode, given that the dose of the photoemitting electron beam is often significantly lower than that of thermionic emission. We quantitatively analyze the dependencies of bias voltage, cathode, wehnelt electrode, and anode on the position, spot size and divergence angle of crossover point, which aids in parameter adjustments for the modified electron gun. The analysis results indicate that if the distance between the wehnelt and the anode is adjusted from 8 mm to 23 mm, the distance between the filament and wehnelt is adjusted from 0.65 mm to 0.45 mm to cooperate with the bias adjustment, so that the normal use of high-resolution thermionic emission mode, low voltage mode and photoemission mode can be realized. Subsequently, the effect of the mirror's position on the electron optical path was analyzed. It was found that when the anode was raised 1.4 mm above the mirror, the influence on the electron optical path became negligible. Additionally, the zero-of-time and temporal broadening of the photo-electron pulse were further simulated. The results indicate that as the bias voltage increases, the time zero point of photoemission shifts later, and the temporal broadening increases. This study lays a foundation for the future development of ultrafast electron microscope and the design of photoemission electron sources.