Improve pair and quote seeking

Seeking is much more robust and consistent now.

Close #8.
Close #24.