mirror of
git://github.com/kovidgoyal/calibre.git
synced 2025-12-18 06:34:27 +01:00
Fix #939256 (Chinese characters shown as boxes in masthead image)
This commit is contained in:
parent
bef9a554a4
commit
aaf41d735d
1 changed files with 5 additions and 1 deletions
|
|
@ -215,7 +215,11 @@ def unit_convert(value, base, font, dpi):
|
|||
def generate_masthead(title, output_path=None, width=600, height=60):
|
||||
from calibre.ebooks.conversion.config import load_defaults
|
||||
from calibre.utils.fonts import fontconfig
|
||||
font_path = default_font = P('fonts/liberation/LiberationSerif-Bold.ttf')
|
||||
from calibre.utils.config import tweaks
|
||||
fp = tweaks['generate_cover_title_font']
|
||||
if not fp:
|
||||
fp = P('fonts/liberation/LiberationSerif-Bold.ttf')
|
||||
font_path = default_font = fp
|
||||
recs = load_defaults('mobi_output')
|
||||
masthead_font_family = recs.get('masthead_font', 'Default')
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue