Refactor hxlcut to use a command function.  Add unit tests for hxlcut filter.