Some refactoring of interval selection. Added possibility to register quirk solutions