OT feature code: some wishes

After writing some OT feature code using the built-in editor, I have a few wishes:

  1. The syntax colouring is nice but I’d like classes and glyph names to be in different colours.

  2. It would be handy to be able to subtract one class from the other, like

@r_and_x = [r r.short r.somethingElse racute x];
@all_lowercase_except_r_and_x = @Lowercase - @r_and_x;
  1. It would be very handy to define classes based on another, with suffix removed, like
@substitutes = [f.myExtension f.short.myExtension t.myExtension];
@substitutees = [@substitutes each with '.myExtension' removed];

In the above example, the substitutes are a hand-picked selection of glyphs.

Or, in a typical, simple case like small caps, one could do:

@substitutes = [$[name endswith '.sc']];
@substitutees = [@substitutes each with '.sc' removed];

Maybe I am missing something and some of the above can be achieved as elegantly using the currently available tokens?

You can use token predicates like this one:

name in class(SomeClass)

This allows arbitrary set operations, not just subtraction. See the examples in the Guten Tag Handbook on page 11:

Ah, thanks! Let me see if I got this right. The above example would be translated as:

@r_and_x = [r r.short r.somethingElse racute x];
@all_lowercase_except_r_and_x = [$[name in class(@Lowercase) AND NOT name in class(@r_and_x)]];

Right?

Yes, except that the at sign is not needed in the token.

and

Any thoughts on these?

like this?
Screenshot 2023-12-18 at 11.31.56
Or stronger?