Music player using python #Part 2 | Music player using python tutorial video|Design a Music player using python






Note:-
You have to paste the path of image files in the code else it will display error messages.
To know where you have to paste the path of image files please watch tutorial which is present below the source code.
This is just a small part of the MUSIC PLAYER code.You will get the full code in our blog or you can also find it on our Youtube channel.

CODE:-

from tkinter import *
import tkinter as tk

root=tk.Tk()
root.geometry("1020x2180")
root.title("Music Player")
root.config(bg='white')

frame1=tk.Frame(root,bg='white')
frame1.pack()

frame2=tk.Frame(root,bg='white')
frame2.pack()

frame3=tk.Frame(root,bg='white')
frame3.pack()

frame4=tk.Frame(root,bg='white')
frame4.pack(pady=50)

#TOPBAR 
Top_btn=Label(frame1,text="Top Bar")
Top_btn.pack(padx=20,pady=20)

#Timebar
time_label=Label(frame3,text="0:00")
time_label.pack(padx=20,pady=20)
#Center Image

Centerimage=PhotoImage(file='/storage/emulated/0/pixelLab/20211111_134042.png')

#Center image placement

Centerimgbutton=Button(frame2,image=Centerimage,borderwidth=2,bg='white')
Centerimgbutton.grid(padx=50,pady=300)

#BUTTON IMAGES
img_play_btn=PhotoImage(file='/storage/emulated/0/pixelLab/20211111_131217.png')
img_stop_btn=PhotoImage(file='/storage/emulated/0/pixelLab/20211005_133042.png')
img_fwd_btn=PhotoImage(file='/storage/emulated/0/pixelLab/20211111_130319.png')
img_back_btn=PhotoImage(file='/storage/emulated/0/pixelLab/20211111_130655.png')
img_shuffle_btn=PhotoImage(file='/storage/emulated/0/pixelLab/20211111_131516.png')
img_loop_btn=PhotoImage(file='/storage/emulated/0/pixelLab/20211111_131551.png')
#BUTTONS

shuffle_btn=Button(frame4,image=img_shuffle_btn,bg='white')
play_btn=Button(frame4,bg='white',image=img_play_btn,borderwidth=0)
#stop_btn=Button(frame4,image=img_stop_btn,borderwidth=0)
fwd_btn=Button(frame4,bg='white',image=img_fwd_btn,borderwidth=0)
back_btn=Button(frame4,bg='white',image=img_back_btn,borderwidth=0)
loop_btn=Button(frame4,bg='white',image=img_loop_btn)


shuffle_btn.pack(side=LEFT,padx=50,pady=10)
back_btn.pack(side=LEFT,padx=10,pady=10)
play_btn.pack(side=LEFT,padx=10,pady=10)
fwd_btn.pack(side=LEFT,padx=10,pady=10)
loop_btn.pack(side=LEFT,padx=50,pady=10)



root.mainloop()
#Code ended



Youtube tutorial


"Hope it helped"
Have anything in mind? Let me 
know in the comment section👇
Next Post Previous Post
No Comment
Add Comment
comment url