Trying to establish a GUI whereby the user clicks a button and set information appears in the relevant rows and columns.
Print doesn't achieve the desired outcome and I don't understand GUIs well enough to try other things. I'm a rookie so I'm very lost.
normal = {'Protein' : {'32.50'},
'Carbohydrates' : {'60'},
'Fat' : {'40.86'}}
from tkinter import *
from tkinter import ttk
root = Tk()
root.title('Diet Information')
frame = ttk.Frame(root, padding='150 150 300 300')
frame.grid(column=0, row=0, sticky=(N, W, E, S))
frame.columnconfigure(0, weight=1)
frame.rowconfigure(0, weight=1)
d_label = ttk.Label(frame, text='Selected diet: ')
d_label.grid(column=1, row=3, sticky=W)
p_label = ttk.Label(frame, text='Protein (g): ')
p_label.grid(column=1, row=4, sticky=W)
c_label = ttk.Label(frame, text='Carbohydrates (g): ')
c_label.grid(column=1, row=5, sticky=W)
f_label = ttk.Label(frame, text='Fat (g): ')
f_label.grid(column=1, row=6, sticky=W)
k_label = ttk.Label(frame, text='Kilojoules (kJ): ')
k_label.grid(column=1, row=7, sticky=W)
s_label = ttk.Label(frame, text='Select a diet to display:')
s_label.grid(column=3, row=8, sticky=W)
n_button = ttk.Button(frame, text='Normal', command=print(normal))
n_button.grid(column=3, row=9, sticky=W)
I wish for the 'normal' button to return the information required for each label. I will then use this method for multiple buttons.