$${E(\omega) = \int_{-\infty}^\infty E(t) \exp(-i \omega t) dt = \int_{-\tau/2}^{\tau/2} E_0 \exp[i(\omega_0 - \omega)t] dt}$$