mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-31 14:33:54 -04:00
...
This commit is contained in:
parent
eca40f6b51
commit
7e0acebabc
@ -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
|
||||
|
@ -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)
|
||||
|
Loading…
x
Reference in New Issue
Block a user