-1
I’m creating an app using Python 3 and Tkinter and I’m time a problem overlapping the widgets, I can’t see the error in the code.
import tkinter as tk
from tkinter import ttk
class MainFrame (ttk.Frame):
def __init__(self, container):
super().__init__(container)
divSearch = ttk.Frame(self)
searchLabel = ttk.Label(divSearch, text="Search:")
searchLabel.grid(row=0, column=0, sticky="W")
searchEntry = ttk.Entry(divSearch, text="")
searchEntry.grid(row=0, column=1, sticky="W")
divSearch.grid(row=0, column=0, sticky="NSEW")
divSubjects = ttk.Frame(self)
subjectsListBox = tk.Listbox(divSubjects)
subjectsListBox.grid(row=0, column=0, sticky="NSEW", pady=5, padx=5)
subjectsCreateButton = ttk.Button(divSubjects, text="Create")
subjectsCreateButton.grid(row=1, column=0, sticky="EW", pady=5, padx=5)
subjectsEditButton = ttk.Button(divSubjects, text="Edit")
subjectsEditButton.grid(row=1, column=0, sticky="EW", pady=5, padx=5)
subjectsDeleteButton = ttk.Button(divSubjects, text="Delete")
subjectsDeleteButton.grid(row=1, column=0, sticky="EW", pady=5, padx=5)
divSubjects.grid(row=1, column=0, sticky="NSEW")
divNotes= ttk.Frame(self)
divNotes.grid(row=1, column=1, sticky="NSEW")