Draws the oval in the current context canvas. >>> e = Rect(x=0, y=20, w=500, h=3) >>> e.xy (0pt, 20pt) >>> e.size (500pt, 3pt)
(self, view, origin=ORIGIN, **kwargs)
| 44 | """ |
| 45 | |
| 46 | def build(self, view, origin=ORIGIN, **kwargs): |
| 47 | """Draws the oval in the current context canvas. |
| 48 | |
| 49 | >>> e = Rect(x=0, y=20, w=500, h=3) |
| 50 | >>> e.xy |
| 51 | (0pt, 20pt) |
| 52 | >>> e.size |
| 53 | (500pt, 3pt) |
| 54 | """ |
| 55 | p = self.getPosition(view, origin) |
| 56 | self.buildFrame(view, p) # Draw optional frame or borders. |
| 57 | view.drawElementFrame(self, p) |
| 58 | self.context.fill(self.css('fill', noColor)) |
| 59 | self.context.stroke(self.css('stroke', noColor), self.css('strokeWidth')) |
| 60 | px, py, _ = p |
| 61 | self.context.rect(px, py, self.w, self.h) |
| 62 | self.buildChildElements(view, p, **kwargs) |
| 63 | self.restore(view, p) |
| 64 | self.drawMeta(view, origin) |
| 65 | |
| 66 | def build_inds(self, view, origin): |
| 67 | """It is better to have a separate InDesignContext build tree, since we |
nothing calls this directly
no test coverage detected