View Single Post
Old 03-20-2022, 08:36 AM   #52
LWTBP
Member
LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.LWTBP ought to be getting tired of karma fortunes by now.
 
LWTBP's Avatar
 
Posts: 16
Karma: 222088
Join Date: Aug 2011
Device: Kindle Paperwhite
Smile

Quote:
Originally Posted by DNSB View Post
I haven't used Prettify Cover in quite a while. I found that I prefer using GIMP directly for the individualized control over the images. I hadn't tried changing the default resolution from the 1000x1500 that I had set back then. I just tried now and get the unicode error.

Looking at the config.py file, line 170 reads:
Code:
        if unicode(self.item(row, 2).text()).strip() == 'Default':
and line 173 reads:
Code:
        for update_row in range(0, self.rowCount()):
I'm not the greatest programmer around but I do seem to remember that in Python 2, unicode was a specialized variant of the str function whereas Python 3 pretty much uses Unicode as it's default. There was also a use of xrange in line 173. Changing the unicode to str and the xrange to range allows me to add a new size and make it the default. Please note that this will break Python 2 compatibility so I bumped the minimum calibre version in __init__.py to 5.0.0.

I've attached the modified file to this message if anyone wants to give it a try.
That solved the problem. I really appreciate it. Thank you!
LWTBP is offline   Reply With Quote