Origin of the large polarization in multiferroic YMnO3 thin films revealed by soft- and hard-X-ray diffraction.