1 Create your first GUI application

2 Create a label widget

2.1 Set label font size

2.2 Setting window size

3 Adding a button widget

3.1 Change button foreground and background colors

3.2 Handle button click event

4 Get input using Entry class (Tkinter textbox)

4.1 Set focus to entry widget

4.2 Disable entry widget

5 Add a combobox widget

6 Add a Checkbutton widget (Tkinter checkbox)

6.1 Set check state of a Checkbutton

7 Add radio buttons widgets

7.1 Get radio button value (selected radio button)

8 Add a ScrolledText widget (Tkinter textarea)

8.1 Set scrolledtext content

8.2 Delete/Clear scrolledtext content

9 Create a MessageBox

9.1 Show warning and error messages

9.2 Show askquestion dialogs

10 Add a SpinBox (numbers widget)

10.1 Set default value for Spinbox

11 Add a Progressbar widget

11.1 Change Progressbar color

12 Add a filedialog (file & directory chooser)

12.1 Specify file types (filter file extensions)

13 Add a Menu bar

14 Add a Notebook widget (tab control)

14.1 Add widgets to Notebooks

15 Add spacing for widgets (padding)

orbat:

Good old Tcl. Man, that language just absolutely refuses to die.

I remember learning in sometime in the 90's specifically to use Tk for some personal project or another. What a weird language. Pathologically dynamic where everything can be (re)defined at runtime, including control structures; "stringly" typed, so everything's a string; you can get at the variables in functions higher up the call stack, effectively "transforming the call stack into a call tree".

It's interesting to see that it's still alive and being used, and that TkInter is apparently "a thin object-oriented layer on top of Tcl/Tk.".


posted 2284 days ago