In one embodiment, a method for correcting distortions in a scanned image
of a page is disclosed. The method comprises identifying at least one set
of collinear elements in the scanned image; and generating a corrected
image based on the scanned image including for at least some of the
collinear elements in each set applying a spatial location correction to
position all collinear elements in the set on a common horizontal
rectilinear base line in the corrected image.