I just downloaded xojo and built the Task Manager app in the Desktop tutorial. The Window, Buttons, and Text Fields all work as expected. At the top of the screen, however, the MenuBar does not look like I would expect, given that the MainMenuBar defined within the program should be: ? File Edit. Instead I get: ? TaskManager.debug File Edit. The File menu has NO menuitems assigned to it and the Edit menu doesn’t have the menuitems that the program stipulates.
I’ve checked that the MainMenuBar is the assigned menubar for the app and window. Did I miss a step in the tutorial that allows the menubar to function properly?
Although your images are not showing, my guess is that you’re building on macOS.
In the Menu Editor of the Xojo IDE, the first three buttons show which OS “mode” your menus will look like, but it sounds like you have the “Windows” mode showing the in the IDE, so that the name of your app doesn’t show in the menu bar (at least not in the IDE).
When you run your app on macOS, the “TaskManager.debug” shows by default because it is a required Application Menu Item for macOS.
Note: After you do a full “build” of your app, the “.debug” suffix will not be there. It’s only there when running your app from the IDE to help you identify your app in debug mode.
I don’t think you’re doing anything wrong, I think what you’re seeing is expected.
Hopefully that makes sense, but let us know if you need further help. Have fun!
Sorry, after re-reading your post more carefully, I’ll add that on macOS, the “Quit” menu item which is added under “File” will get moved to the “TaskManager.debug” menu list automatically, because that is a design rule for macOS. This is handled by the fact that the Quit menu is of type QuitMenuItem.
Also on macOS, the OS will automatically add some additional items under the “Edit” menu, such as “Start Dictation…” and “Emoji & Symbols”. See this blog post about that Localize Your Edit Menu on Mac, which will explain a bit about why this happens.
I hope that helps.
Thank you for the responses Scott and Alberto. By experimenting with the menu editing, I found you are correct Scott. The “Quit” menuitem gets stolen to the TaskManager.debug menu; the Clear menuitem gets changed to the word Delete; and the “Start Dictation” and “Emojis & Symbols” get added on to the Edit menu “just because”.
It’s odd behavior but maybe it translates better on a PC (I am on a Mac).
Thanks for taking the time to steer a newbie in the right direction.
Yes, the Menus you specify in the Xojo IDE come out on Windows as much more predictable than macOS.
This is a thing you’ll learn using Xojo for cross-platform Desktop development. Many of the common controls you incorporate in your application may or will have some subtle behaviour or visual differences - simply because Mac and Windows have some different design or functional goals.
So you will need to be a bit ambidextrous when it comes to your application design and implementation, but the bonus is, you can do it all with just one language, in one IDE, Xojo!
You’re welcome. Always happy to help. Good luck!
The behaviour of the menu editor is legacy. Some items of the File menu are automatically shown in the app menu. For others you can set the super to AppleMenuItem to move them over.