Есть код. Но не могу сделать так, чтобы текст с кнопки отсылался в консоль. Тоесть: нажал кнопку, текст с кнопки отобразился в консоли.
import tkinter as tk
from tkinter import *
from PIL import ImageTk, Image
#Панель управления
def show_image(path):
root = tk.Tk()
img = Image.open(path)
width = 500
ratio = (width / float(img.size[0]))
height = int((float(img.size[1]) * float(ratio)))
imag = img.resize((width, height), Image.ANTIALIAS)
image = ImageTk.PhotoImage(imag)
panel = tk.Label(root, image=image)
panel.pack(side="top", fill="both", expand="no")
tk.Button(root, text='Запуск', command=root.quit).place(x=250, y=250)
root.mainloop()
show_image('C:/Users/111/Рабочий стол/Новая папка/Новая папка (3)/хлам/БОЛЬШАЯ ФЕРМА.jpg')