This commit is contained in:
Lukas Schulz 2020-12-20 01:22:50 +01:00
parent 937b3d5bbf
commit f1bd69f9c1

View file

@ -47,9 +47,9 @@ def get_track():
global song_name
song_name = track['item']['name']
global artist_name
artist_name = track['item']['artists'][0]['name']
#artist_name = track['item']['artists'][0]['name']
for i in range(len(track['item']['artists'])):
artist_name += track['item']['artists'][i]['name']
artist_name +=', ' track['item']['artists'][i]['name']
#print(track['item']['name'] + ' - ' + track['item']['artists'][0]['name'])
#print('getting image')
image_url = track['item']['album']['images'][0]['url']
@ -102,8 +102,10 @@ def drawCanvas():
x.start()
print('scrolling text started')
if(font.getsize(artist_name)[0]>160):
y = threading.Thread(target=scrolling_text,args=(artist_name,songinfo_offset_x,songinfo_offset_y))
y.start()
showImage(canvas)