0

I wanted to insert a menubar but I noticed that it doesn't appear, I also asked chatGPT but the data code didn't work anyway, I'm on a mac so I thought there was some problem since there are differences between menubars with window but I couldn't find anything about.

from tkinter import *
from tkinter import ttk

root = Tk(className = "Menubar")

root.geometry ("500x500")

menubar = Menu(root)
root.config(menu=menubar)

file_menu = Menu(menubar)
menubar.add_cascade(label="file",menu=file_menu)

root.mainloop ()

Bryan Oakley
  • 370,779
  • 53
  • 539
  • 685
Tino
  • 1
  • 2
  • On a mac, the menu will not appear at the top of the window. Instead, it appears at the top of your monitor just like for any other mac app. – Bryan Oakley May 16 '23 at 16:08
  • Does this answer help? https://stackoverflow.com/questions/68331195/how-to-customize-tkinter-menubar-on-mac – toyota Supra May 16 '23 at 19:44

0 Answers0