Johannes VIII., Imperium Byzantinum, Imperator