Use Context.save(), Context.restore() stack
This commit is contained in:
parent
9e3c30f487
commit
a5879df512
1 changed files with 3 additions and 0 deletions
|
@ -104,6 +104,8 @@ class SkewTGraph():
|
|||
y: float,
|
||||
samples: Iterable[SoundingSample],
|
||||
fn: Callable):
|
||||
cr.save()
|
||||
|
||||
first = True
|
||||
|
||||
for sample in samples:
|
||||
|
@ -129,6 +131,7 @@ class SkewTGraph():
|
|||
cr.line_to(x + sx, y + sy)
|
||||
|
||||
cr.stroke()
|
||||
cr.restore()
|
||||
|
||||
def draw(self,
|
||||
cr: cairo.Context,
|
||||
|
|
Loading…
Add table
Reference in a new issue