Show the text editor menu on macOS
The only problem was that the editor window had an owner; if it doesn't, Qt uses the menubar correctly.
BUG:391600 (cherry picked from commit ba17603826792acee3441578fc9eef448be185c3)