mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
E-book viewer: Fix books that set side margins on body using percentages not working correctly. Fixes #1608458 [Private bug](https://bugs.launchpad.net/calibre/+bug/1608458)
This commit is contained in:
parent
df1d52a7ef
commit
202528eda9
@ -921,6 +921,9 @@ class DocumentView(QWebView): # {{{
|
|||||||
def load_path(self, path, pos=0.0):
|
def load_path(self, path, pos=0.0):
|
||||||
self.initial_pos = pos
|
self.initial_pos = pos
|
||||||
self.last_loaded_path = path
|
self.last_loaded_path = path
|
||||||
|
# This is needed otherwise percentage margins on body are not correctly
|
||||||
|
# evaluated in read_document_margins() in paged mode.
|
||||||
|
self.document.setPreferredContentsSize(QSize())
|
||||||
|
|
||||||
def callback(lu):
|
def callback(lu):
|
||||||
self.loading_url = lu
|
self.loading_url = lu
|
||||||
|
Loading…
x
Reference in New Issue
Block a user