Comments (2)
The following changes to context.py seem to fix this issue. I have proposed a change to the file and submitted it. Here is a diff of my changes. https://github.com/chrisglass/xhtml2pdf/pull/32/files
@@ -184,10 +184,10 @@ def _pisaAddFrame(self, name, data, first=False, border=None, size=(0,0)):
184 184
#if not (w and h):
185 185
# return None
186 186
if first:
187
-
187
return (name, None, data.get("-pdf-frame-border", border), x, y, w, h)
-
188 188
return (name, None, data.get("-pdf-frame-border", border), x, y, w, h, data)
189 189
return (name, data.get("-pdf-frame-content", None),
190
-
190
data.get("-pdf-frame-border", border), x, y, w, h)
-
191 191
data.get("-pdf-frame-border", border), x, y, w, h, data)
192 192
def atPage(self, name, pseudopage, declarations):
193 193
c = self.c
... ...
@@ -246,7 +246,10 @@ def atPage(self, name, pseudopage, declarations):
246 246
# Frames have to be calculated after we know the pagesize
247 247
frameList = []
248 248
staticList = []
249
-
249
for fname, static, border, x, y, w, h in c.frameList:
-
250
for fname, static, border, x, y, w, h, fdata in c.frameList:
-
251
#fix frame sizing problem.
-
252
if static:
-
250 253
x, y, w, h = getFrameDimensions(fdata, c.pageSize[0], c.pageSize[1])
x, y, w, h = getCoords(x, y, w, h, c.pageSize)
251 254
if w <= 0 or h <= 0:
252 255
log.warn(self.c.warning("Negative width or height of frame. Check @frame definitions."))
from xhtml2pdf.
Reported issue cannot be confirmed anymore.
from xhtml2pdf.
Related Issues (20)
- Problem with hindi text html encoding into pdf HOT 3
- xhtml2pdf==0.2.13 fails to build pycairo HOT 4
- Breaking changes and versioning HOT 9
- Accented UTF8 chars are not correctly show in the created PDF HOT 2
- Document does not conform to PDF/A. HOT 2
- broken reportlab import HOT 7
- Replace pypdf with pyHanko HOT 2
- when <p> inside ul and ol, ul and ol will not work
- Override default background for Canvas Tags HOT 1
- upgrade python-pillow to latest version. current version of python-pillow used by xhtml2pdf has vulnerability HOT 1
- Cannot Add Images as a Link HOT 4
- Input type radio not supported HOT 1
- reportlab 4.2 support HOT 3
- OSS-Fuzz Integration HOT 6
- Error when runing `pip install -v .[test,docs,build]` HOT 1
- Named Page templates no longer working in xhtml2pdf version 0.2.16 HOT 2
- Page overflow and next page is not done automatically
- python-bidi 0.5.0 introduces a breaking change HOT 3
- my pdf words looks like this "■■■■■ ■■■■" HOT 5
- xhtml2pdf breaks with bidi 0.5.0 (default now) HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xhtml2pdf.