move SegmentType to Segment::Type and make int again

needed to make it available to the plugin framework
and the memory saved is not worth the performance penalty