Factor out calculations and rendering

The first step to handling drawing the comparison is to un-link the
drawing and calculation code from the first inputs