Exemple #1
0
def open_lyrics():
    play_it = ''

    def edit_lyrics():
        def save_lyrics():
            val = display_label.get(1.0, END)
            play_it = queue[selected_song]
            abtmusic = EasyID3(play_it)
            var = abtmusic['title'][0]
            f = open("lyrics/" + var + ".txt", 'a')
            f.write(val)
            f.close()
            eabtm.destroy()
            open_lyrics()

        global display_label
        eabtm = tk.ThemedTk()
        eabtm.geometry('450x400+200+200')
        eabtm.title("ADD LYRICS")
        title = ttk.Label(
            eabtm,
            text=
            "To Add Lyrics Copy Lyrics From Internet And Paste In Below text area"
        )
        title.pack()
        display_label = Text(eabtm,
                             width=50,
                             height=20,
                             font="ariel",
                             fg="black",
                             bg="white")
        display_label.pack()
        saveBtn = ttk.Button(eabtm, text="Save", command=save_lyrics)
        saveBtn.pack()
        lyrm.destroy()

    selected_song = playlistbox.curselection()
    if not selected_song:
        tkinter.messagebox.showerror(
            'Error', 'Please Select A song from list to display about song')
    else:
        selected_song = int(selected_song[0])
        play_it = queue[selected_song]
        abtmusic = EasyID3(play_it)
        var = abtmusic['title'][0]
        lyrm = tk.ThemedTk()
        lyrm.title('LYRICS ~~' + var)
        lyrm.geometry('300x280+200+200')
        lyrm.iconbitmap(r'images/sur.ico')
        abm = Listbox(lyrm, width=50, height=15)
        abm.place(x=0, y=0)
        try:
            f = open("lyrics/" + var + ".txt", 'r')
            for x in f:
                abm.insert(END, x.split())
            f.close()
        except:
            abm.insert(END, "no lyrics")
            editBtn = ttk.Button(lyrm, text="Edit Data", command=edit_lyrics)
            editBtn.place(x=10, y=250)
def moreabt_song():
    global abm
    global abtm
    global play_it
    selected_song = playlistbox.curselection()
    if not selected_song:
        tkinter.messagebox.showerror(
            'Error', 'Please Select A song from list to display about song')
    else:
        selected_song = int(selected_song[0])
        play_it = queue[selected_song]
        try:
            abtmusic = EasyID3(play_it)
            filename = abtmusic['title'][0]
            abtm = tk.ThemedTk()
            abtm.geometry('300x280+200+200')
            abtm.title("About ~~ " + filename)
            abtm.iconbitmap(r'images/sur.ico')
            abm = Listbox(abtm, width=50, height=15)
            abm.place(x=0, y=0)
            for key in sorted(abtmusic.keys()):
                val = abtmusic[key]
                abm.insert(END, key + " : " + val[0])
            editBtn = ttk.Button(abtm, text="Edit Data", command=ed_gui)
            editBtn.place(x=10, y=250)
        except:
            tkinter.messagebox.showerror('File not found',
                                         'play the song to get info')
Exemple #3
0
    def func():

        l2.configure(text=cb.get())
        if (cb.get() == "Inorgánicos"):
            Nroot = tk.ThemedTk()
            Nroot.get_themes()  # Returns a list of all themes that can be set
            Nroot.set_theme("plastik")  # Sets an available # theme
            #w = Canvas(Nroot, width=100, height=100)
            #w.pack()

            statusbar = ttk.Label(Nroot, text="BIENVENIDOS AGRARIOS", relief=SUNKEN, anchor=W, font='Times 10 italic')
            statusbar.pack(side=BOTTOM, fill=X)
            menubar = Menu(Nroot)
            Nroot.config(menu=menubar)
            subMenu = Menu(menubar, tearoff=0)

            #menubar.add_cascade(label="File", menu=subMenu)
            #subMenu.add_command(label="Exit", command=root.destroy)

            Nroot.geometry("350x150")
            Nroot.title("UNIVERSIDAD AGRARIA DEL ECUADOR")
            Nroot.iconbitmap(r'descarga_gMJ_icon.ico ')
            leftframe = Frame(Nroot)
            leftframe.pack(side=LEFT, padx=30, pady=30)

            Label1 = ttk.Label(leftframe, text=" Valores inorgánicos ")
            Label1.grid(row=0, column=0, padx=10)

            none1 = ttk.Label(leftframe, text="")
            none1.grid(row=0, column=1, padx=10)

            medida = ttk.Label(leftframe, text="mg/l")
            medida.grid(row=0, column=2, padx=10)

            none2 = ttk.Label(leftframe, text="")
            none2.grid(row=0, column=3, padx=10)

            resultado = ttk.Label(leftframe, text="3.29")
            resultado.grid(row=0, column=4, padx=10)


            #======================================================================================================

            agua = ttk.Label(leftframe, text=" Turbiedad del agua")
            agua.grid(row=1, column=0, padx=10)

            none3 = ttk.Label(leftframe, text="")
            none3.grid(row=1, column=1, padx=10)

            medida2 = ttk.Label(leftframe, text="Pt-Cu")
            medida2.grid(row=1, column=2, padx=10)

            none4 = ttk.Label(leftframe, text="")
            none4.grid(row=1, column=3, padx=10)

            resultado2 = ttk.Label(leftframe, text="5")
            resultado2.grid(row=1, column=4, padx=10)


            Nroot.mainloop()
Exemple #4
0
def Valores():
    ven = tk.ThemedTk()
    ven.get_themes()  # Returns a list of all themes that can be set
    ven.set_theme("plastik")  # Sets an available theme
    ven.title("VALORES RECOMENDADOS")
    ven.geometry("900x500")
    ven.resizable(False, False)
    root.iconbitmap(r'descarga_gMJ_icon.ico ')

    newframe = Frame(ven)  # FRAME IZQUIERDO
    newframe.pack(side=LEFT,padx=30, pady=10)

    tex = "JULISSA"
    l1 = ttk.Label(newframe, text=tex)
    l1.grid(row=0,column =0)

    l1 = ttk.Label(newframe)
    l1.grid(row=0, column=1)

    l1 = ttk.Label(newframe, text=tex)
    l1.grid(row=0, column=2)

    l1 = ttk.Label(newframe)
    l1.grid(row=0, column=3)

    l1 = ttk.Label(newframe, text=tex)
    l1.grid(row=0, column=4)
    ven.mainloop()
Exemple #5
0
 def __init__(self):
     #self.root = Tk()
     self.root = tk.ThemedTk()
     self.root.get_themes()
     # self.root.set_theme('clam')
     self.root.set_theme('radiance')
     # self.root.geometry("{0}x{0}+0+0".format(self.root.winfo_screenwidth(), self.root.winfo_screenheight()))
     # self.root.resizable(0, 0)
     self.root.attributes('-fullscreen', True)
     mixer.init()
     mixer.music.load('song/Kbc.mp3')
     mixer.music.play()
     self.root.config(background="#090035")
     dp = PhotoImage(file="img/kbc_frontlook.png")
     Label(self.root, image=dp, bg='#090035').pack()
     self.lb_blank = Label(self.root, text="", bg="white")
     self.progress1 = ttk.Progressbar(self.root,
                                      orient="horizontal",
                                      length=400,
                                      mode="determinate")
     self.lb_blank.pack()
     self.progress1.pack()
     self.bytes = 0
     self.start()
     self.root.mainloop()
    def edit_lyrics():
        def save_lyrics():
            val = display_label.get(1.0, END)
            play_it = queue[selected_song]
            abtmusic = EasyID3(play_it)
            var = abtmusic['title'][0]
            f = open("lyrics/" + var + ".txt", 'a')
            f.write(val)
            f.close()
            eabtm.destroy()
            open_lyrics()

        global display_label
        eabtm = tk.ThemedTk()
        eabtm.geometry('450x400+200+200')
        eabtm.title("ADD LYRICS")
        title = ttk.Label(
            eabtm,
            text=
            "To Add Lyrics Copy Lyrics From Internet And Paste In Below text area"
        )
        title.pack()
        display_label = Text(eabtm,
                             width=50,
                             height=20,
                             font="ariel",
                             fg="black",
                             bg="white")
        display_label.pack()
        saveBtn = ttk.Button(eabtm, text="Save", command=save_lyrics)
        saveBtn.pack()
        lyrm.destroy()
Exemple #7
0
 def plotmap(p_table):
     
     no_hrs = int((end_time-st_time).seconds/3600)+24*(end_time-st_time).days
     if(no_hrs>48):
         Msg = mb.askyesno(title='Warning', message= 'The selected time range is very large \nHeatmap would not be clear \nWould you still want to continue?') 
     elif(no_hrs<=48):
         Msg = True
     
     if(Msg == True): 
         plwindow = tk.ThemedTk()
         plwindow.get_themes()
         plwindow.set_theme('breeze')
         plwindow.geometry('1000x1000') 
         plwindow.configure(background= '#ffc3a0')
         plwindow.title('Heat Map')
                 
         f = Figure(figsize = (10,10))
         f.clf()
         f.suptitle('Heatmap for 5 minutes')
         canvas = FigureCanvasTkAgg(f, master = plwindow)
         canvas.get_tk_widget().pack(fill = BOTH, expand = True)
 
         canvas._tkcanvas.pack(side = TOP, fill = BOTH, expand = True)
         a = f.add_subplot(111)
         Heatmap = sns.heatmap(p_table, cmap = 'RdYlGn', annot = p_table.values, ax=a).set_yticklabels(labels = p_table.index, rotation = 0)
         
         plwindow.mainloop()
Exemple #8
0
def estimateWindow():

	window = tk.ThemedTk()
	window.get_themes()
	window.set_theme("radiance")
	window.geometry("450x420")


	guessButton = Button(window, text = "Guess Window", command = openGuessWindow)
	guessButton.pack(expand = YES)
	# guessButton.grid(row = 1, column = 2)

	TableButton = Button(window, text = "K-L information statistics", command = tableKLStatistics)
	TableButton.pack(expand = YES)

	# TableButton.grid(row = 2, column = 2)

	TableButton1 = Button(window, text = "Optimisation Results", command = tableParameterEstimation)
	TableButton1.pack(expand = YES)

	# TableButton1.grid(row = 3, column = 2)
	PlotButton = Button(window, text = "Plot", command = GraphFunction)
	PlotButton.pack(expand=YES)

	window.mainloop()
Exemple #9
0
    def __init__(self):
        root = tk.ThemedTk()
        root.set_theme(theme_name='itft1')
        root.title('Tic Tac Toe')
        self._game_win = None
        frame = Frame(root)
        frame.pack(fill=X)
        Button(frame, text='Show Help', command=self.help_callback).pack(
            fill=X)  #Fill means expands in x-direction when window is resized

        Button(frame, text='Play Game',
               command=self.play_callback).pack(fill=X)

        Button(frame, text='Quit', command=root.quit).pack(fill=X)

        console = Text(frame, height=4, width=50)
        scroll = Scrollbar(frame)
        scroll.pack(side=RIGHT, fill=Y)
        console.pack(side=LEFT, fill=Y)

        #Use grid method rather than pack for more complexity

        scroll.config(command=console.yview)
        console.config(yscrollcommand=scroll.set)

        self._console = console
        self._root = root
Exemple #10
0
def auth():
    main = tk.ThemedTk()
    main.get_themes()
    main.set_theme("radiance")

    main.title("Module Registration System")
    main.iconbitmap(r'images/upes.ico')

    upesPhoto = PhotoImage(file='images/upes.png')
    label = Label(image=upesPhoto)
    label.pack(side=TOP, pady=20, padx=30)

    def r():
        main.destroy()
        register()

    def l():
        main.destroy()
        login()

    regBtn = ttk.Button(main, text="REGISTER", width=20, command=r)
    regBtn.pack(side=LEFT, pady=20, padx=20)

    logBtn = ttk.Button(main, text="LOGIN", width=20, command=l)
    logBtn.pack(pady=20, padx=20)

    main.resizable(0, 0)

    main.mainloop()
Exemple #11
0
    def check_gui(self):
        if self.args.gui:
            self.luciferManager.gui = True
            self.luciferManager.main_shell = Shell(
                self.luciferManager.next_shell_id, self.luciferManager)
            self.luciferManager.next_shell_id += 1
            root = themed_tk.ThemedTk()
            root.set_theme("arc",
                           toplevel=None,
                           themebg=('#%02x%02x%02x' % (39, 44, 53)))
            self.luciferManager.root = root
            application = LuciferGui(self.luciferManager, root)
            self.luciferManager.gui = application
            root.mainloop()

        else:
            self.luciferManager.colorama.init(autoreset=True)
            print(
                self.luciferManager.termcolor.colored(
                    self.luciferManager.version,
                    "red",
                    attrs=["bold", "underline"]))
            self.luciferManager.main_shell = Shell(
                self.luciferManager.next_shell_id, self.luciferManager)
            self.luciferManager.next_shell_id += 1
            self.luciferManager.main_shell.spawn()
    def __init__(self, name, FLAG, PathWay, Single):
        self.FLAG = FLAG
        self.PathWay = PathWay
        self.Single = Single
        self.textBox = []
        self.KeyValue = None

        # self.dataCon = []
        # self.pdfname = ''
        # self.contentList = []
        # self.contentListSec = []
        self.window = tk.ThemedTk()
        self.window.get_themes()
        self.window.set_theme("plastik")

        self.window.title(name)
        self.window.geometry('1000x550+300+30')
        self.window.resizable(False, False)
        self.window.iconbitmap('soa.ico')
        cdir = os.getcwd()
        """Menu section"""
        menubar = Menu()
        menubarcntent = Menu()
        menukeydir = Menu()
        menuHelp = Menu()

        menubar.add_cascade(label='File', menu=menubarcntent)
        menubarcntent.add_command(label='Open File', command=self.openFile)
        menubarcntent.add_command(label='clear memory',
                                  command=self.clearCaheMem)
        menubarcntent.add_command(label='Delete Previous file',
                                  command=self.deleteCode)

        menubar.add_cascade(label="Kifunguo", menu=menukeydir)
        menukeydir.add_command(label="Normal Key", command=self.normalKey)
        menukeydir.add_command(label="Admin Key", command=self.komplexKey)

        menubar.add_cascade(label="help", menu=menuHelp)
        menuHelp.add_command(label="Hola the Developer(L)")
        self.window.config(menu=menubar)

        # self.textBox = ttk.Text(self.window, height=30, bg='gray', bd=20)
        self.textBox = Text(self.window, height=30, bg='gray', bd=20)
        self.textBox.place(x=0, y=0)

        # encodeButton = Button(self.window, text='< ENCODE >', width=20, height=8, bg='lime', activebackground='red', bd=10,
        #                       font='helvitica', command=self.encodingKey)
        encodeButton = ttk.Button(self.window,
                                  text='< ENCODE >',
                                  width=20,
                                  command=self.encodingKey)
        encodeButton.place(x=750, y=1)
        # decodeButton = Button(self.window, text='< DECODE >', width=20, height=8, bg='brown', activebackground='red', bd=10,
        #                       font='helvitica', command=self.decodingKey)
        decodeButton = ttk.Button(self.window,
                                  text='< DECODE >',
                                  width=20,
                                  command=self.decodingKey)
        decodeButton.place(x=750, y=210)
        self.window.mainloop()
Exemple #13
0
        def clicked(tablename):
            #this function displays the availble stock of a product

            if (str(tablename) != ''):
                querry = "SELECT * FROM "
                querry = querry + str(tablename)
                cursor.execute(querry)
                field_names = Fetch.getFields(str(tablename))
                column = 0
                stock = tk.ThemedTk()
                stock.title("Stock for " + tablename)
                for j in range(len(field_names) -
                               1):  #populate upper row with column names
                    e = ttk.Entry(stock, width=20)
                    e.grid(row=0, column=j)
                    e.insert(END, field_names[j])
                i = 0

                for bags in cursor:  #popultate topmost row
                    for j in range(len(bags) - 1):
                        e = ttk.Entry(stock, width=20)
                        e.grid(row=i + 1, column=j)
                        e.insert(END, bags[j])
                    i = i + 1

            else:
                print('as')
Exemple #14
0
    def __init__(self):
        """ Init graphical user interface for pathfinding """

        self.algorithms = [
            'Breadth First Search', 'BFS Recursive', 'Depth First Search',
            'DFS Recursive', 'Dijkstra', 'A*'
        ]
        self.solve_mode = 0
        self.draw_modes = [1, 2, 3, 4]
        self.draw_mode = 1
        self.is_solving, self.solved = False, False
        self.start_node, self.finish_node, self.last_rendered_node = None, None, None
        self.root = theme.ThemedTk()
        self.menu_frame = tkk.Frame(self.root)
        self.graph_width, self.graph_height = 1220, 850
        self.canvas = tk.Canvas(self.root,
                                height=self.graph_height + 50,
                                width=self.graph_width,
                                bg='#333333')
        self.node_size = 20
        self.weight = 10
        self.n_cols, self.n_rows = None, None
        self.nodes, self.flat_nodes = None, None
        self.shapes = []
        self.wall_frequency = 0.05
        self.render_delay = 0
        self.config_root()
        self.config_menu()
        self.config_canvas()
        self.root.mainloop()
Exemple #15
0
        def exiting():
            if messagebox.askyesno("Confirmation",
                                   "Are you sure you want to exit?") == True:
                wnd.destroy()

                wnd__ = tk.ThemedTk()
                wnd__.get_themes()
                wnd__.set_theme('equilux')
                wnd__.title("Exiting....")
                wnd__.geometry("130x70+550+325")
                wnd__.iconbitmap('form.ico')
                wnd__.config(bg="black")
                wnd__.minsize(width=130, height=70)
                wnd__.maxsize(width=130, height=70)
                wnd__.overrideredirect(1)

                Label(text=" ", bg="black").pack()
                message = ttk.Label(wnd__,
                                    text="    Exiting....",
                                    width=120,
                                    font=("Helvetica, 15"),
                                    foreground="white",
                                    background="black")
                message.pack()
                Label(text=" ", bg="black").pack()

                def destroy():
                    wnd__.destroy()

                wnd__.after(1000, destroy)
                wnd__.mainloop()
                print("Thank You!")

            else:
                pass
def window2():
    global date
    date = dataset['Date']
    #date = [dt.datetime.strptime(str(date[i]), '%d-%m-%Y') for i in range(len(date))]
    window2 = tk.ThemedTk()
    window2.get_themes()
    window2.set_theme('clearlooks')
    window2.configure(background='#ffc3a0')
    window2.geometry('850x300')
    fr1 = Frame(window2, relief=RAISED, borderwidth=1)
    fr1.pack(side=TOP, fill=X)
    fr2 = Frame(window2)
    fr2.pack(side=TOP, fill=X)
    window2.title('Date selection')
    sdate_lbl2 = Label(fr1, text='Choose starting date')
    sdate_lbl2.pack(side=LEFT, pady=5)
    strt_cmb2 = Combobox(fr1)
    strt_cmb2.pack(side=LEFT, padx=5)
    strt_cmb2['values'] = tuple(np.unique(date))
    strt_cmb2.current(0)
    edate_lbl2 = Label(fr1, text='Choose ending date').pack(side=LEFT,
                                                            pady=5,
                                                            padx=5)
    end_cmb2 = Combobox(fr1)
    end_cmb2.pack(side=LEFT, padx=5)
    end_cmb2['values'] = tuple(np.unique(date))
    end_cmb2.current(0)
    style = Style()
    style.configure('W.TButton',
                    font=('Times New Roman', 12, 'bold'),
                    foreground='red',
                    background='#0000FF')

    def clicked2():
        global st_date, end_date
        st_date = pd.to_datetime(strt_cmb2.get())
        end_date = pd.to_datetime(end_cmb2.get())
        if st_date > end_date:
            mb.showerror("Date Error",
                         "End date must be greater than start date")
            window2.mainloop()
        #sdate_lbl3.configure(text = st_date)
        window2.destroy()
        window3()

    def bkclick():
        window2.destroy()
        main()

    back_bt = Button(fr2, text='Back', style='W.TButton', command=bkclick)
    back_bt.pack(side=LEFT, padx=10)
    time_bt = Button(fr2,
                     text='Proceed to time range selection',
                     style='W.TButton',
                     command=clicked2)
    time_bt.pack(side=BOTTOM, pady=5)
    window2.mainloop()
Exemple #17
0
    def __init__(self, root):
        super().__init__()
        self.root = root
        self.embed_file = ''
        self.encrypt = None
        self.window = tk.ThemedTk()
        self.window.title('PowerPoint Steganography Application')
        self.window.geometry('1366x768')
        self.window.set_theme('plastik')
        self.window.lift()

        self.sel_emb_file = ttk.Label(self.window,
                                      text='Select File to Embed: ')
        self.sel_emb_file.grid(column=0, row=0, padx=130, pady=20)

        self.sel_emb_file_btn = ttk.Button(
            self.window,
            text='Browse',
            command=self.sel_emb_file_btn_clicked,
            takefocus=False)
        self.sel_emb_file_btn.grid(column=1, row=0, padx=30, pady=20)

        self.em_file_lbl = ttk.Label(self.window,
                                     text='Selected File To Embed: ')
        self.em_file_lbl.grid(column=0, row=1, padx=130, pady=15)
        self.em_file_lbl.grid_remove()

        self.embed_file_lbl = ttk.Label(self.window, text=self.embed_file)
        self.embed_file_lbl.grid(column=1, row=1, padx=30, pady=15)
        self.embed_file_lbl.grid_remove()

        self.enc_file_lbl = ttk.Label(self.window, text='Encrypt file: ')
        self.enc_file_lbl.grid(column=0, row=2, padx=0, pady=15)
        self.enc_file_lbl.grid_remove()

        self.enc_file_y = ttk.Radiobutton(self.window,
                                          text='Yes',
                                          value=1,
                                          command=self.enc_file_y)
        self.enc_file_y.grid(column=1, row=2, padx=0, pady=15)
        self.enc_file_y.grid_remove()

        self.enc_file_n = ttk.Radiobutton(self.window,
                                          text='No',
                                          value=2,
                                          command=self.enc_file_n)
        self.enc_file_n.grid(column=2, row=2, padx=0, pady=15)
        self.enc_file_n.grid_remove()

        self.embed_btn = ttk.Button(self.window,
                                    text='Embed',
                                    command=self.embed_btn_clicked,
                                    takefocus=False)
        self.embed_btn.grid(column=2, row=3, padx=0, pady=15)
        self.embed_btn.grid_remove()

        self.window.mainloop()
Exemple #18
0
    def Verify_NewPhone(self, phone_n, widget):
        print(phone_n)
        if len(phone_n) == 11:
            widget.destroy()

            # Verification code
            verification_code = ""
            for i in range(0, 6):
                verification_code += str(randint(0, 9))

            verification_window = tk.ThemedTk()
            verification_window.wm_title("VERIFY- Phone Number")
            verification_window.geometry("410x64")
            verification_window.get_themes()
            verification_window.set_theme("radiance")

            code_entry = ttk.Entry(verification_window, width=20)
            code_entry.grid(row=1, column=0, padx=10, pady=5)
            code_entry.insert(END, "e.g 123456")
            code_entry.config(foreground="grey",
                              font=("Calibri", 10))  #Format of pin

            call_link = Label(verification_window,
                              text="Prefer a call?",
                              fg="blue",
                              cursor="hand2")
            call_link.config(font=("Calibri", 8))
            call_link.grid(row=2, column=0, padx=10)
            call_link.bind("<Button-1>",
                           lambda e: self.Call(phone_n, code_entry))

            verify_b = ttk.Button(
                verification_window,
                text="Verify",
                width=10,
                command=lambda: self.Verify(phone_n, code_entry.get(),
                                            verification_code))
            verify_b.grid(row=1, column=1, padx=3, pady=5)

            def on_enter(event):
                code_entry.delete(0, END)

            code_entry.bind("<Button-1>", on_enter)

            try_again_b = ttk.Button(
                verification_window,
                text="Send again",
                width=10,
                command=lambda: self.Send_Message(phone_n))
            try_again_b.grid(row=1, column=2, padx=2, pady=5)

            self.Send_Message(phone_n, verification_code)

            verification_window.mainloop()
        else:
            messagebox.showinfo("Invalid Number",
                                "Re-enter phone number as 07....")
Exemple #19
0
    def Restore_Password(self, code):
        window = tk.ThemedTk()
        window.wm_title("RESTORE-USERID & PASSWORD")
        window.geometry("510x150")

        window.get_themes()
        window.set_theme("radiance")

        #Username is clearly shown after identity has been proven

        userd_id = ttk.Label(window, text=" UserId: " + code.upper())
        userd_id.grid(row=1, column=2, padx=10, pady=5)
        userd_id.config(font=("Calibri", 20))

        #Labels and entry boxes so that user can make another password
        l1 = ttk.Label(window, text=" Type New Password").grid(row=2,
                                                               column=1,
                                                               padx=10,
                                                               pady=5)
        l2 = ttk.Label(window, text=" Retype New Password").grid(row=3,
                                                                 column=1,
                                                                 padx=10,
                                                                 pady=5)

        new_pass = ttk.Entry(window, width=30, show="*")
        new_pass.grid(row=2, column=2, padx=10, pady=2)

        retype_pass = ttk.Entry(window, width=30, show="*")
        retype_pass.grid(row=3, column=2, padx=10, pady=2)

        next_step_b = ttk.Button(
            window,
            text="Finish",
            width=10,
            command=lambda: self.Update_Password(code, new_pass, retype_pass,
                                                 window)).grid(row=4,
                                                               column=3,
                                                               pady=3)

        #Allows that when clicked entry box is cleared from its example
        def on_enter1(event):
            new_pass.delete(0, END)

        #Allows that when clicked entry box is cleared from its example
        def on_enter2(event):
            retype_pass.delete(0, END)

        new_pass.bind(
            "<Button-1>", on_enter1
        )  #Allows that when clicked entry box is cleared from its example

        retype_pass.bind(
            "<Button-1>", on_enter2
        )  #Allows that when clicked entry box is cleared from its example

        window.mainloop()
Exemple #20
0
def main1():
    Root_Room=tk.ThemedTk()
    Root_Room.get_themes()
    Root_Room.iconbitmap("icon.ico")
    Root_Room.set_theme("keramik")
    DataRoom(Root_Room)
    Root_Room.title("DataRoom")
    Root_Room.geometry("650x550+350+200")
    Root_Room.resizable(False,False)
    Root_Room.mainloop()
Exemple #21
0
def main():
    """The root or main engine of the app"""
    root = themes.ThemedTk()
    root.get_themes()  # Returns a list of all themes that can be set
    root.set_theme(
        "kroc"
    )  # ubuntu, winxpblue, radiance, kroc^^, elegance, clearlooks, blue, arc^^
    Player(root)
    # root.protocol("WM_DELETE_WINDOW", on_closing)
    root.mainloop()
Exemple #22
0
def common_theme():
    window = themed_tk.ThemedTk()
    window.set_theme('black')  # Theme selection
    window.option_add("*Button.Background",
                      "#e0e0e0")  # Changing button colors
    window.option_add("*Button.Foreground", "#444444")
    icon = PhotoImage(file='plane.gif')  # The application icon
    window.iconphoto(True, icon)

    return window
Exemple #23
0
def main():
    Root_Customer = tk.ThemedTk()
    Root_Customer.get_themes()
    Root_Customer.set_theme("keramik")
    Root_Customer.iconbitmap("icon.ico")
    app = Data_Customer(Root_Customer)
    Root_Customer.title("DataCustomer")
    Root_Customer.geometry("650x550+350+200")
    Root_Customer.resizable(False, False)
    Root_Customer.mainloop()
def deleteEntry():
    global roo, nam, clas, phon, addr
    root = t.ThemedTk(theme="radiance")
    root.title("Data Remove Portal")
    root.wm_iconbitmap(r"res/remm.ico")
    root.geometry("750x600")
    root.config(bg="#2C3335")
    Canvas1 = Canvas(root)

    Canvas1.config(bg="#2C3335")
    Canvas1.pack(expand=True, fill=BOTH)

    headingFrame1 = Frame(root, bg="#FFBB00", bd=5)
    headingFrame1.place(relx=0.25, rely=0.1, relwidth=0.5, relheight=0.13)

    headingLabel = Label(headingFrame1,
                         text="Delete Entry",
                         bg='black',
                         fg='white',
                         font=("hack 20"))
    headingLabel.place(relx=0, rely=0, relwidth=1, relheight=1)

    labelFrame = Frame(root, bg='black')
    labelFrame.place(relx=0.1, rely=0.3, relwidth=0.8, relheight=0.5)

    lb2 = Label(labelFrame,
                text="Roll N0. : ",
                bg='black',
                fg='white',
                font="hack 15")
    lb2.place(relx=0.05, rely=0.5)

    roo = Entry(labelFrame, width=8, font="firacode 17")
    roo.place(relx=0.3, rely=0.5, relwidth=0.62)

    s = ttk.Style().configure('my.TButton', font="firacode 15")
    ttk.Button(root,
               text="Enter",
               style="my.TButton",
               command=deleteThatSucker,
               width=15).place(relx=0.055, rely=0.87)
    ttk.Button(root,
               text="Clear",
               style="my.TButton",
               command=ClearInput,
               width=15).place(relx=0.36, rely=0.87)
    ttk.Button(root,
               text="Exit",
               style="my.TButton",
               command=root.destroy,
               width=15).place(relx=0.676, rely=0.87)
    root.mainloop()


# deleteEntry()
Exemple #25
0
def viewEntry():
    global mycursor
    root=t.ThemedTk(theme="radiance")
    root.title("View Data Section")
    root.geometry("1150x600")
    root.wm_iconbitmap(r"res/viewlogo.ico")
    root.config(bg="#2C3335")
    Canvas1 = Canvas(root)

    scrollbar = Scrollbar(root)
    scrollbar.pack(side=RIGHT, fill=Y)

    Canvas1.config(bg="#2C3335")
    Canvas1.pack(expand=True, fill=BOTH)

    headingFrame1 = Frame(root, bg="#FFBB00", bd=5)
    headingFrame1.place(relx=0.25, rely=0.1, relwidth=0.5, relheight=0.13)

    headingLabel = Label(headingFrame1, text="View Details",
                         bg='black', fg='white', font=("hack 20"))
    headingLabel.place(relx=0, rely=0, relwidth=1, relheight=1)

    labelFrame = Canvas(root,bg='black',yscrollcommand = scrollbar.set)
    labelFrame.place(relx=0.1, rely=0.3, relwidth=0.8, relheight=0.55)
    y = 0.25

    scrollbar.config(command=labelFrame.yview)



    mylabel=Label(labelFrame,text="%-20s%-32s%-30s%-40s%-50s" % ('RollNo', 'Name',
                                                     'Class', 'Phone No.',"Address"), bg='black', fg='white').place(relx=0.07, rely=0.1)
    Label(labelFrame, text="---------------------------------------------------------------------------------------------------------------------------------------------------------------------",
          bg='black', fg='white').place(relx=0.05, rely=0.2)
    


    Com=("SELECT * FROM student")
    try:
        mycursor.execute(Com)
        myresult = mycursor.fetchall()
        for i in myresult:
            Label(labelFrame, text="%-20s%-32s%-30s%-40s%-50s" %
                  (i[0], i[1], i[2], i[3],i[4]), bg='black', fg='white').place(relx=0.07, rely=y)
            y += 0.1
    except:
        tmsg.showerror("ERROR 404","Something Went Wrong\nUnable To Fetch Data,Try Again")

    s = ttk.Style().configure('my.TButton', font="hack 17")

    ttk.Button(root, text="Exit", style="my.TButton",
               command=root.destroy, width=15).place(relx=0.4, rely=0.89)

    root.mainloop()
def main():
    root = themed_tk.ThemedTk()
    # root = tkinter.Tk()
    root.get_themes()
    root.set_theme("arc")
    # icon = 'icon/482azelf.png'
    icon = 'icon/preciousball.png'
    # icon = 'icon/premiereball.png'
    root.iconphoto(True, tkinter.PhotoImage(file=icon))
    app = Application(root)
    app.mainloop()
Exemple #27
0
    def __init__(self):
        super().__init__()

        if 'output' not in os.listdir(os.getcwd()):
            os.mkdir('output')

        self.pptx_file = ''
        self.embed_file = ''
        self.key_file = ''
        self.psc = ''
        self.window = tk.ThemedTk()
        self.window.title('PowerPoint Steganography Application')
        self.window.geometry('1366x768')
        self.window.set_theme('plastik')

        self.ch_pptx_lbl = ttk.Label(self.window,
                                     text='Choose Cover PowerPoint File: ')
        self.ch_pptx_lbl.grid(column=0, row=0, padx=130, pady=20)

        self.browse_pptx_btn = ttk.Button(self.window,
                                          text='Browse',
                                          command=self.browse_pptx_clicked,
                                          takefocus=False)
        self.browse_pptx_btn.grid(column=1, row=0, padx=5, pady=20)

        self.se_pptx_lbl = ttk.Label(self.window,
                                     text='Selected PowerPoint File: ')
        self.se_pptx_lbl.grid(column=0, row=1, padx=130, pady=5)

        self.pptx_file_lbl = ttk.Label(self.window, text=self.pptx_file)
        self.pptx_file_lbl.grid(column=1, row=1, padx=5, pady=5)

        self.psc_lbl = ttk.Label(self.window,
                                 text='PowerPoint Steganographic Capacity: ')
        self.psc_lbl.grid(column=0, row=2, padx=130, pady=20)

        self.psc_result = ttk.Label(self.window, text=self.psc)
        self.psc_result.grid(column=1, row=2, padx=5, pady=20)

        self.embed_rad = ttk.Radiobutton(self.window,
                                         text='Embed',
                                         value=1,
                                         command=self.embed_rad_clicked)
        self.embed_rad.grid(column=0, row=3, padx=130, pady=30)
        self.embed_rad.grid_remove()

        self.extract_rad = ttk.Radiobutton(self.window,
                                           text='Extract',
                                           value=2,
                                           command=self.extract_rad_clicked)
        self.extract_rad.grid(column=1, row=3, padx=30, pady=30)
        self.extract_rad.grid_remove()

        self.window.mainloop()
    def __init__(self):

        self.defaultlocation = Window.root_folder

        #======================
        # Create instance
        #======================

        self.master = tk.ThemedTk()

        # Disable resizing the window
        #self.master.resizable(0,0)
        lst_themes=["aquativo", "arc","black","blue","clearlooks","equilux",\
                    "itft1","smog", \
                    "elegance","kroc","keramik",\
                    "plastik","radiance",\
                    "winxpblue"]

        self.master.set_theme("itft1")
        #self.master.set_theme(lst_themes[np.random.randint(low=0, high=14)])

        #(1 #final run),(0 atleastconnect) (-1 very fast checking)
        self.realrun = 1
        try:
            self.realrun = int(input("Type_of_run:"))
        except:
            print("Not a number")

        #self.realrun=-1

        #different tabs now in different module
        self.diff_tabs = different_tabs(self)

        self.especscheduler = Espec_Scheduler(self)
        self.espec_comm = Espec_Communication(self, self.realrun)
        self.aerotec_comm = Aero_Position_Communication(self, self.realrun)
        self.datalogger_comm = Datalogger_Communication(self, self.realrun)
        self.acquisition = Acquisition(self, self.realrun)
        self.analysis_obj = Analysis(self, self.realrun)

        self.analysis_obj_thej2 = Analysis_thej2(self, self.realrun)
        # Add a title
        self.master.title("DATA ACQUISITION SYSTEM ARDF")

        #populating the tabs
        self.diff_tabs.createtabs()
        self.especscheduler.populate_tab_schedule_espec()
        self.especscheduler.populate_tab_retrieveschedule()
        self.especscheduler.populate_tab_deleteschedule()

        self.diff_tabs.populate_tab_input()

        def closing_protocol(self):
            pass
Exemple #29
0
def main3():
    Root_BAction = tk.ThemedTk()
    app = BAction(Root_BAction)
    Root_BAction.get_themes()
    Root_BAction.iconbitmap("icon.ico")
    Root_BAction.set_theme("keramik")
    Root_BAction.bind('<Return>',app.Upload)
    Root_BAction.title("Business activities")
    Root_BAction.geometry("950x550+350+200")
    Root_BAction.resizable(False, False)
    Root_BAction.mainloop()
Exemple #30
0
    def __init__(self):
        self.wn=tk.ThemedTk()
        # self.wn=Tk()
        self.wn.configure(bg="#6262ED")
        self.wn.title("Parking Details")
        self.wn.geometry("620x480+200+100")

        self.park=Park()
        self.item_index = ""
        self.my_index = 1

        self.frame1=Frame(self.wn,bg="#6262ED")
        self.frame1.place(x=10,y=30)

        self.lb_spot= Label(self.frame1,font=("Calibri",14,"bold"),text="Spot no:",bg="#6262ED",fg="black")
        self.lb_spot.grid(row=0,column=0)

        self.ent_spot=Entry(self.frame1,font=("Calibri",12),width=7)
        self.ent_spot.grid(row=0,column=1)

        self.btn_add=Button(self.frame1, text='Add', font=('Calibri', 11,"bold"), fg="white",background='#6262ED',width=12, bd=1,command=self.add_park)
        self.btn_add.grid(row=0,column=2,padx=10)

        self.frame2=Frame(self.wn,bg="#6262ED")
        self.frame2.place(x=10,y=100)

        self.details_tree = ttk.Treeview(self.frame2, columns=('Username','Brand', 'Model','Vechile Type', 'Spot','booking time'))
        self.details_tree.grid(row=0,column=0)
        self.details_tree['show'] = 'headings'
        self.details_tree.column('Username', width=100, anchor='center')
        self.details_tree.column('Brand', width=100, anchor='center')
        self.details_tree.column('Model', width=100, anchor='center')
        self.details_tree.column('Vechile Type', width=120, anchor='center')        
        self.details_tree.column('Spot', width=60, anchor='center')
        self.details_tree.column('booking time', width=100, anchor='center')
        self.details_tree.heading('Username', text="Username")
        self.details_tree.heading('Brand', text="Brand")
        self.details_tree.heading('Model', text="Model")
        self.details_tree.heading('Vechile Type', text="Vechile Type")
        self.details_tree.heading('Spot', text="Spot")
        self.details_tree.heading('booking time', text="Booking Time")


        self.delete_button=Button(self.wn, text="Delete", font=('Calibri', 11,"bold"), fg="white",background='#C31616',width=15, bd=1,command=self.deleteBooking)
        self.delete_button.place(x=10,y=390)

        self.details_tree.bind("<Double-1>", self.select_item)


        self.show_menu()
        self.showDetails()

        self.wn.mainloop()