View Single Post
Old 11-04-2012, 01:42 PM   #32
andyh2000
Fanatic
andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.andyh2000 ought to be getting tired of karma fortunes by now.
 
andyh2000's Avatar
 
Posts: 564
Karma: 1568694
Join Date: Apr 2009
Location: UK
Device: Samsung Galaxy S4 Mini phone / Kindle 4 Black / Kindle Paperwhite
Quote:
Originally Posted by KevinShort View Post
Sorry about the permission denied, I forgot to set it as public.

I really don't know why it can't load the font file. I'm looking into it.
Does it work if you change the font-loading lines in weather.py to use a default font?
Code:
tiny_font = pygame.font.Font(None, 18)
small_font = pygame.font.Font(None, 22)
font = pygame.font.Font(None, 40)
comfortaa = pygame.font.Font(None, 60)
comfortaa_small = pygame.font.Font(None, 35)
Yeah, I guessed about the file permission thing.

I lied in my last post, I can't leave anything alone until it's working...

It looks like it can't load the TrueType fonts. When I converted them to otf format and used those instead it worked. Then I just had to copy full_update from .python into the weather app folder (or change line 363 in the weather.py script to point to it) and it worked perfectly! Presumably full_update looks in the current directory for a file called image.png and blats it to the display?

Click image for larger version

Name:	2012-11-04 18.29.33.jpg
Views:	223
Size:	152.0 KB
ID:	95437

Thanks ever so much for this. Now I've got it working I'm going to make an astronomer's version, possibly based on data from 7timer.com.

I can't quite believe that the Kobo can run Python and pygame natively - that is so cool!

Andrew
andyh2000 is offline   Reply With Quote