Day 4: Exploring Python with Projects

Let us explore few more resources that list python projects:

As we get into relatively bigger projects, we need to learn to use external libraries, for example, the official documentation lists Graphical User Interfaces with Tk.

The site w3schools has page GUI Programming with the following sample code:

import tkinter as tk
from tkinter import *
from tkinter import ttk

class karl( Frame ):
def __init__( self ):
self.button1 = Button( self, text = “CLICK HERE”, width = 25,
command = self.new_window )
self.button1.grid( row = 0, column = 1, columnspan = 2, sticky = W+E+N+S )
def new_window(self):
self.newWindow = karl2()
class karl2(Frame):
def __init__(self):
new =tk.Frame.__init__(self)
new = Toplevel(self)
new.title(“karlos More Window”)
new.button = tk.Button( text = “PRESS TO CLOSE”, width = 25,
command = self.close_window )
def close_window(self):
def main():
if __name__ == ‘__main__’:

This covers lot of fundamental concepts hopefully taking us soon beyond the beginner level.

One thought on “Day 4: Exploring Python with Projects

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s