Calculate ruler position more reliably

We used to measure the width of one space and multiply that by the
ruler column to calculate the ruler position.  This approach has the
disadvantage that if the space width measurement is slightly
inaccurate, the error is multiplied, and will end up significantly
distorting the ruler position.

To avoid this, measure the width of as many spaces as the requested
ruler column.  If there is a measurement error, it will at least not
be multiplied, so the end result should be more reliable.

At this point in time, this fixes a significant error in the ruler
position in current Blink based browsers (Chrome / Opera) while
making no significant difference in Presto based Opera.