Fix padding in connection with the xy2ijk functionality.