티스토리 뷰

from tkinter import *
# ---------------------------- CONSTANTS ------------------------------- #
PINK = "#e2979c"
RED = "#e7305b"
GREEN = "#9bdeac"
YELLOW = "#f7f5dd"
FONT_NAME = "Courier"
WORK_MIN = 25
SHORT_BREAK_MIN = 5
LONG_BREAK_MIN = 20
# ---------------------------- TIMER RESET ------------------------------- # 
# ---------------------------- TIMER MECHANISM ------------------------------- # 
# ---------------------------- COUNTDOWN MECHANISM ------------------------------- # 
# ---------------------------- UI SETUP ------------------------------- #
window = Tk()
window.title("Pomodoro. 14May2022, kio")
window.config(padx=100, pady=50, bg=YELLOW)
Top_label = Label(text="Timer", fg=GREEN, bg=YELLOW, font=(FONT_NAME, 50, "bold"))
Top_label.grid(column=1, row=0)
canvas = Canvas(width=200, height=224, bg=YELLOW, highlightthickness=0)
tomato_img = PhotoImage(file="tomato.png")
canvas.create_image(100,112,image=tomato_img)
canvas.create_text(102,128,text="00:00", fill="white",font=(FONT_NAME, 26, "bold"))
#canvas.pack()
canvas.grid(column=1, row=1)
start_button = Button(text="Start", highlightthickness=0)
start_button.grid(column=0 , row=3)
reset_button = Button(text="Reset", highlightthickness=0)
reset_button.grid(column=3 , row=3)
check_mark = Label(text="♡", bg=YELLOW, fg=GREEN, font=(FONT_NAME, 20, "bold"))
check_mark.grid(column=1, row=4)
window.mainloop()

 

댓글
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2025/08   »
1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31
글 보관함