Ensure minWidth and maxWidth are applied correctly

When splicing an element of the percentArray or asteriksArray within a
loop certain array elements would be skipped during processing if the
counter is not decremented.