Every line of 'tkinter drop down menu' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your Python code is secure.
156 def new_menu(self,parent,tearoff=False): 157 158 """Wrapper for the Tkinter new_menu menu method.""" 159 160 if self.font: 161 try: 162 return Tk.Menu(parent,tearoff=tearoff,font=self.font) 163 except Exception: 164 g.es_exception() 165 return Tk.Menu(parent,tearoff=tearoff) 166 else: 167 return Tk.Menu(parent,tearoff=tearoff)
737 def set_menu(self, default=None, *values): 738 menu = self['menu'] 739 menu.delete(0, 'end') 740 for val in values: 741 menu.add_radiobutton(label=val, command=Tkinter._setit(self._variable, val, self._callback)) 742 743 if default: 744 self._variable.set(default)
752 def popup(self): 753 self.tk.call(self._w, 'popup')