Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Plugins

Notices

Reply
 
Thread Tools Search this Thread
Old 10-06-2014, 06:05 PM   #496
theducks
Grand Sorcerer
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 15,268
Karma: 6022733
Join Date: Aug 2009
Location: (The original) Silicon Valley, USA
Device: Galaxy Tab 2, Astak Pocket Pro, K4NT
You could rename 'generate_cover.json' to something else and see if that works.
You will lose all cover cover template settings ore you can carefully edit the bad 'name' value to choose one that exists
theducks is offline   Reply With Quote
Old 10-06-2014, 06:59 PM   #497
Pocket of Books
Junior Member
Pocket of Books began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Oct 2014
Device: Marvin, Nook Glow
Better Red.... Thanks for your reply. I did find that my font book had most of the fonts disabled (no idea why). I enabled them all, but it still didn't fix my problem. How do I find out what font Generate Cover is looking for without being able to get into the plugin? This is probably obvious, but I'm not seeing it. Thank you for any help.
Pocket of Books is offline   Reply With Quote
Old 10-06-2014, 07:15 PM   #498
theducks
Grand Sorcerer
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 15,268
Karma: 6022733
Join Date: Aug 2009
Location: (The original) Silicon Valley, USA
Device: Galaxy Tab 2, Astak Pocket Pro, K4NT
Quote:
Originally Posted by Pocket of Books View Post
Better Red.... Thanks for your reply. I did find that my font book had most of the fonts disabled (no idea why). I enabled them all, but it still didn't fix my problem. How do I find out what font Generate Cover is looking for without being able to get into the plugin? This is probably obvious, but I'm not seeing it. Thank you for any help.
The JSON file in the config folder\Plugins

It can be opened with Notepad(++)
theducks is offline   Reply With Quote
Old 10-07-2014, 01:17 AM   #499
BetterRed
null operator
BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.BetterRed ought to be getting tired of karma fortunes by now.
 
Posts: 3,991
Karma: 2925589
Join Date: Mar 2012
Location: NSW Australia
Device: none
Quote:
Originally Posted by Pocket of Books View Post
Better Red.... Thanks for your reply. I did find that my font book had most of the fonts disabled (no idea why). I enabled them all, but it still didn't fix my problem. How do I find out what font Generate Cover is looking for without being able to get into the plugin? This is probably obvious, but I'm not seeing it. Thank you for any help.
@Pocket of Books - as per post 496 from theducks, close calibre and rename %CALIBRE_CONFIG_DIRECTORY%\plugins\Generate Cover.json to something like ...over.json.save. The PI should create a new Generate Cover.json that will allow you to ensure that it works on 'default settings'

If you've only got a few pro-forma covers it may be easier to recreate them, you'll find the images in the %CALIBRE_CONFIG_DIRECTORY%\resources\images\genera te_cover folder. Otherwise once you know the PI is working then you could edit the original json file to replace the font names with something 'boring' like Times New Roman. You'd need to change the value of "name", from say Freestyle Script to Times New Roman, in lines such as these:

Code:
"fonts": {
        "title": {
          "size": 42, 
          "name": "Freestyle Script", 
          "align": "center"
        }, 
        "series": {
          "size": 18, 
          "name": "Freestyle Script", 
          "align": "center"
        }, 
        "custom": {
          "size": 18, 
          "name": "Forte", 
          "align": "center"
        }, 
        "author": {
          "size": 36, 
          "name": "Freestyle Script", 
          "align": "center"
        }
      },
BR

Last edited by BetterRed; 10-07-2014 at 01:20 AM.
BetterRed is offline   Reply With Quote
Old 10-08-2014, 12:04 PM   #500
Tanjamuse
Addict
Tanjamuse began at the beginning.
 
Posts: 329
Karma: 10
Join Date: Jan 2014
Device: Samsung Galaxy Tab 3
It would be really nice if you could set conditions for the different covers like with icons.
Tanjamuse is offline   Reply With Quote
Old 10-09-2014, 09:18 PM   #501
JimmXinu
Plugin Developer
JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.JimmXinu ought to be getting tired of karma fortunes by now.
 
Posts: 1,821
Karma: 510215
Join Date: Dec 2011
Location: Midwest USA
Device: Nook STR w/Glowlight, Kindle 3g, Droid
Quote:
Originally Posted by Pocket of Books View Post
I'm getting the following message upon using "Generate Cover":ERROR: Unhandled exception: <b>KeyError</b>:u'generate_cover_title_font'.
I've had a FFDL user report this same issue (FFDL can call GC), so I was investigating it. And it looks like it is a real problem with fresh calibre installs caused by the fact that calibre's tweaks no longer have a generate_cover_title_font value.

I see the same issue with GC running in a fresh portable install.

The relevant code in GC is:

Code:
...
from calibre.utils.config import tweaks
...
def get_font_or_default(font_name):
    default_font = tweaks['generate_cover_title_font']
...
The attached test version changes that to:

Code:
...
from calibre.utils.config import tweaks
...
def get_font_or_default(font_name):
    default_font = tweaks.get('generate_cover_title_font',None)
...
...so it works for both fresh installs and existing that have generate_cover_title_font set to something. (Also changes the only other 'tweaks' value in the PI similarly.)

If I can a confirmation or two of the problem and that this fixes it, I'll ask Kovid to update the release version.
Attached Files
File Type: zip Generate Cover.zip (53.2 KB, 26 views)
JimmXinu is offline   Reply With Quote
Old 10-10-2014, 03:44 AM   #502
Feynor
Enthusiast
Feynor began at the beginning.
 
Posts: 29
Karma: 10
Join Date: Sep 2013
Device: Samsung Galaxy Note 10.1 2014 ed. with Moon Reader+ and Google Books.
Thumbs up

Quote:
Originally Posted by JimmXinu View Post
If I can a confirmation or two of the problem and that this fixes it, I'll ask Kovid to update the release version.
I can confirm that your fix works. Thanks

Win 7 64-bit
Calibre 2.5 64-bit
Feynor is offline   Reply With Quote
Old 10-10-2014, 07:47 AM   #503
Pocket of Books
Junior Member
Pocket of Books began at the beginning.
 
Posts: 3
Karma: 10
Join Date: Oct 2014
Device: Marvin, Nook Glow
I too can confirm that the new version fixed my problem. I can stop banging my head against the wall now. I appreciate all the help.
Pocket of Books is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[GUI Plugin] Goodreads Sync kiwidude Plugins 694 Yesterday 12:07 PM
[GUI Plugin] Open With kiwidude Plugins 251 12-15-2014 01:07 PM
[GUI Plugin] User Category kiwidude Plugins 36 10-31-2014 07:08 AM
[GUI Plugin] Quick Preferences kiwidude Plugins 32 09-13-2014 11:34 PM
[GUI Plugin] Clipboard Search kiwidude Plugins 9 08-12-2014 04:36 AM


All times are GMT -4. The time now is 08:49 AM.


MobileRead.com is a privately owned, operated and funded community.