Skip to content

Commit

Permalink
more UI changes
Browse files Browse the repository at this point in the history
  • Loading branch information
TheNupurC committed Jul 7, 2022
1 parent 6d39c09 commit 5d4d474
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,16 @@

obj = PasswordWallet() #Adding the password wallet-class from main.py

primary_color = "#00353F" # primary color (blue)
background_color = "#6CE6DB" #secondary (black)
primary_color = "#00353F" # primary color (white)
background_color = "#6CE6DB" #secondary (blue)
gray = "#4D4D4D" # Gray

class operations():
def draw_window():
global window_name
window_name = Tk() #Creates a blank window
window_name.geometry("1280x720") # Defined window geometry
window_name.title("Uni-Pass") # Defined window title
window_name.title("Encrypt-It") # Defined window title

icon = PhotoImage(file=r'Assets/images/logo.png') #imported window logo from its saved location
window_name.iconphoto(True,icon) # added window logo
Expand All @@ -26,18 +27,17 @@ def text(content,size,x,y):
title = Label(window_name,text=content,font=("Arial",size,"bold"),fg=primary_color,bg=background_color) # addes a text widget
title.place(relx=x,rely=y,anchor = CENTER) # places the text widget in place

def button(task,content,size,x,y):
signup_button = Button(window_name,command=task,text=content,font=("Comic Sans",size,"bold"),bg=primary_color,fg=background_color,activeforeground=primary_color,activebackground=background_color,borderwidth=0) # addes a button widget
def button(task,content,size,x,y,width):
signup_button = Button(window_name,command=task,text=content,font=("Comic Sans",size,"bold"),bg=gray,fg=primary_color,activeforeground=primary_color,activebackground=background_color,borderwidth=0,width = width) # addes a button widget
signup_button.place(relx=x,rely=y,anchor = CENTER) # places the button widget in place

class Window:
def home(): # The main home function (gets called at the start)
operations.draw_window()
operations.text("Encrypt-It",100,0.5,0.3) # adds title
operations.text("Remembering passwords just got alot easier!",20,0.5,0.45) # adds subtitle

operations.button(Window.login,"Login",20,0.4,0.7) # login button
operations.button(Window.sign_up,"Sign-up",20,0.6,0.7) # signup button
operations.button(Window.login,"Login",40,0.5,0.6,20) # login button
operations.button(Window.sign_up,"Sign-up",40,0.5,0.7,20) # signup button

window_name.mainloop() # mainloop for the code to run (v-imp)

Expand Down

0 comments on commit 5d4d474

Please sign in to comment.