  X-ray free-electron lasers (FELs) are promising tools for structural
determination of macromolecules via coherent x-ray scattering. During
ultrashort and ultraintense x-ray pulses with an atomic scale wavelength,
samples are subject to radiation damage and possibly become highly ionized,
which may influence the quality of x-ray scattering patterns. We develop a
toolkit to treat detailed ionization, relaxation, and scattering dynamics for
an atom within a consistent theoretical framework. The coherent x-ray
scattering problem including radiation damage is investigated as a function of
x-ray FEL parameters such as pulse length, fluence, and photon energy. We find
that the x-ray scattering intensity saturates at a fluence of ~10^7
photons/{\AA}^2 per pulse, but can be maximized by using a pulse duration much
shorter than the time scales involved in the relaxation of the inner-shell
vacancy states created. Under these conditions, both inner-shell electrons in a
carbon atom are removed, and the resulting hollow atom gives rise to a
scattering pattern with little loss of quality for a spatial resolution > 1
{\AA}. Our numerical results predict that in order to scatter from a carbon
atom 0.1 photons per x-ray pulse, within a spatial resolution of 1.7 {\AA}, a
fluence of 10^7 photons/{\AA}^2 per pulse is required at a pulse length of 1 fs
and a photon energy of 12 keV. By using a pulse length of a few hundred
attoseconds, one can suppress even secondary ionization processes in extended
systems. The present results suggest that high-brightness attosecond x-ray FELs
would be ideal for single-shot imaging of individual macromolecules.
