An XPS study of thin NiO films deposited on MgO(100)