convert as many "enum" as possible to "enum class", and make them ": char" in the due course #6

Follow up of PR #914, #927, #935, #936 and #946
Several enum types are "enum class" (i.e. typesafe C++ enums), several others are not.
Also making them ": char" should reduce the size of structures using them.

Not to be merged just now, I just (mis-)use Travis for the tests...