The transformation of inhomogeneously broadened spectra due to frequency migration