title: How to style and customize tkinter/guizero menu bar?
body: <p>I am working with Tkinter and <em>guizero</em> and am trying to style the menu bar.I am using Python 3.8.2</p>
  <p><strong>Things I am trying to change</strong></p>
  <ol>
  <li><p>Remove the border/3D effect on the menu bar and options.</p>
  </li>
  <li><p>Remove the menu bar top padding(the little space above and on the left side).</p>
  </li>
  <li><p>Active select color for both toplevel/menu bar and options.</p>
  </li>
  </ol>
  <pre class="lang-py prettyprint-override"><code>from guizero import App, MenuBar
  
  def file_function():
      print(&quot;File option&quot;)
  
  def about_function():
      print(&quot;about option&quot;)
  
  app = App(title=&quot;My app&quot;, height=300, width=500,bg='white')
  menubar = MenuBar(app,
                      toplevel=[&quot;File&quot;, &quot;About&quot;],
                      options=[
                          [ [&quot;New&quot;, file_function], [&quot;Save&quot;, file_function]],
                          [ [&quot;Report Bug&quot;, about_function], [&quot;About&quot;, about_function] ]
                      ])
  
  menubar.bg=(111, 77, 124)
  
  # none of the styling below works and this is what I've tried
  menubar.border=0
  menubar.toplevel.border=False
  menubar.options.border=0
  menubar.toplevel.options.bg='gray'
  menubar.toplevel.focus.bg='yellow'
  menubar.toplevel.focus.fg='yellow'
  menubar.toplevel.options.border=False
  app.display()
  </code></pre>
  <p><em>Image:</em></p>
  <p><a href="https://i.stack.imgur.com/ApKVb.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ApKVb.png" alt="enter image description here" /></a></p>
  <p><strong>Update</strong></p>
  <p>The menu is not meant to currently look good the strange colors are to see what does and doesn't works. I am able to use guizero widget and all of their functionality.</p>
  <p>Current Problems</p>
  <ol>
  <li>Unable to remove 3d/possible padding effect on menu and sub menu when item is selected</li>
  </ol>
  <p>I have tried setting border to 0  and highlightthickness to 0</p>
  <p><strong>Updated code</strong></p>
  <pre><code>from guizero import *
  from tkinter import *
  
  app=App(title='Test',bg=(53, 60, 81))
  root = app.tk
  
  def hello():
      print (&quot;hello!&quot;)
  
  
  #creates menubar
  menubar = Menu(root,relief=FLAT,bd=0)
  
  
  
  
  # Sets menubar background color and active select but does not remove 3d  effect/padding
  menubar.config(bg = &quot;GREEN&quot;,fg='white',activebackground='red',activeforeground='pink',relief=FLAT)
  
  
  # First item on menubar and creates sub options
  filemenu = Menu(menubar, tearoff=0,relief=FLAT, font=(&quot;Verdana&quot;, 12),activebackground='red')
  filemenu.config(bg = &quot;GREEN&quot;) 
  filemenu.add_command(label=&quot;New (Ctrl + N)&quot;, command=hello)
  filemenu.add_command(label=&quot;Save(Ctrl + S)&quot;, command=hello)
  filemenu.add_separator()
  filemenu.add_command(label=&quot;Exit&quot;, command=root.quit)
  menubar.add_cascade(label=&quot;File&quot;, menu=filemenu)
  
  
  
  # Adds to menubar and creates sub options
  editmenu = Menu(menubar, tearoff=0)
  editmenu.add_command(label=&quot;Cut&quot;, command=hello)
  editmenu.add_command(label=&quot;Copy&quot;, command=hello)
  editmenu.add_command(label=&quot;Paste&quot;, command=hello)
  menubar.add_cascade(label=&quot;Edit&quot;, menu=editmenu)
  
  helpmenu = Menu(menubar, tearoff=0,bg='green',fg='blue')
  
  helpmenu.add_command(label=&quot;Report bug&quot;, command=hello)
  helpmenu.add_command(label=&quot;About&quot;, command=hello)
  menubar.add_cascade(label=&quot;Help&quot;, menu=helpmenu)
  
  helpmenu.activebackground='red'
  
  
  
  root.config(menu=menubar)
  app.display()
  </code></pre>