Add support for empty and scalar quality scores

Also add tests for degap().