Use a retractable keyring holder and trim pot. Just super glue the trim pot's screw to the shaft of the keyring holder. Gives pretty good linearity even though the string winds up on the drum, but if that's a problem, you can make a lookup correction table or a correction function for it. Without correcting, yields about 1/4" or better resolution over about five feet.
This setup was used to provide feedback for all of
this robot's actuators. I'm friends with the person who built the thing... so... pretty good bet this should work for you too.
-q