On 12/4/2021 11:50 AM, Juri Linkov wrote:
`context-menu-middle-separator' is a function, so it requires the
`context-menu-' prefix. It adds the menu item [middle-separator].
Since "middle" is an adjective, the word order can't be
"separator-middle".
But "buffers-separator" doesn't look nicer than `separator-buffers'.
I think `FOO-separator' is the best choice here for the separators
themselves. `FOO' acts as a noun adjunct[1], modifying the underlying
object: a separator. For functions that just make a separator, they'd be
named `MODULE-[FOO-]-separator', with `FOO-' being optional if it would
be redundant with the module name. So then
`context-menu-middle-separator' is the right function name, and it adds
a separator named `middle-separator'.
`buffers-separator' is a bit of an odd phrasing since, as the Wikipedia
article mentions, "Noun adjuncts were traditionally mostly singular".
However, I think it's still a bit easier to read that correctly as "the
separator used to mark the buffers", whereas `separator-buffers' reads
more like "buffers used to separate things" to me.
Since this should just be a trivial renaming, hopefully we can merge
that into Emacs 28 so we're not locked into the current names.
[1] https://en.wikipedia.org/wiki/Noun_adjunct