Fix rendering of banner cover style at small scale factors

This commit is contained in:
Kovid Goyal 2015-11-18 00:47:10 +05:30
parent 5164e4b005
commit 95471f746a

View File

@ -371,7 +371,7 @@ class Banner(Style):
def __call__(self, painter, rect, color_theme, title_block, subtitle_block, footer_block): def __call__(self, painter, rect, color_theme, title_block, subtitle_block, footer_block):
painter.fillRect(rect, self.color1) painter.fillRect(rect, self.color1)
top = title_block.position.y + 10 top = title_block.position.y + 2
extra_spacing = subtitle_block.line_spacing // 2 if subtitle_block.line_spacing else title_block.line_spacing // 3 extra_spacing = subtitle_block.line_spacing // 2 if subtitle_block.line_spacing else title_block.line_spacing // 3
height = title_block.height + subtitle_block.height + extra_spacing + title_block.leading height = title_block.height + subtitle_block.height + extra_spacing + title_block.leading
right = rect.right() - self.hmargin right = rect.right() - self.hmargin