This commit is contained in:
Kovid Goyal 2013-01-01 15:26:32 +05:30
parent eca40f6b51
commit 7e0acebabc
2 changed files with 2 additions and 9 deletions

View File

@ -396,8 +396,6 @@ class Graphics(object):
pen = state.stroke
self.pending_state.do_stroke = True
pdf = self.pdf
if pen.style() == Qt.NoPen:
self.pending_state.do_stroke = False
# Width
w = pen.widthF()
@ -429,6 +427,8 @@ class Graphics(object):
pen.brush(), state.brush_origin, state.opacity, pdf_system,
painter.transform())
self.pdf.apply_stroke(color, pattern, opacity)
if pen.style() == Qt.NoPen:
self.pending_state.do_stroke = False
def apply_fill(self, state, pdf_system, painter):
self.pending_state.do_fill = True

View File

@ -69,13 +69,6 @@ def full(p, xmax, ymax):
g.setColorAt(1, QColor('#fff'))
p.fillRect(x, y, w, w, QBrush(g))
pen = QPen(QBrush(Qt.blue))
pen.setWidth(xmax/3)
p.setPen(pen)
x += w + w/10
y += w
p.drawLine(x, y, x+w, y)
def run(dev, func):
p = QPainter(dev)