@check_page<EOL><INDENT>def ellipse(self, x,y,w,h,style='<STR_LIT>'):<DEDENT>
if(style=='<STR_LIT:F>'):<EOL><INDENT>op='<STR_LIT:f>'<EOL><DEDENT>elif(style=='<STR_LIT>' or style=='<STR_LIT>'):<EOL><INDENT>op='<STR_LIT:B>'<EOL><DEDENT>else:<EOL><INDENT>op='<STR_LIT:S>'<EOL><DEDENT>cx = x + w/<NUM_LIT><EOL>cy = y + h/<NUM_LIT><EOL>rx = w/<NUM_LIT><EOL>ry = h/<NUM_LIT><EOL>lx = <NUM_LIT>/<NUM_LIT>*(math.sqrt(<NUM_LIT:2>)-<NUM_LIT:1>)*rx<EOL>ly = <NUM_LIT>/<NUM_LIT>*(math.sqrt(<NUM_LIT:2>)-<NUM_LIT:1>)*ry<EOL>self._out(sprintf('<STR_LIT>', <EOL>(cx+rx)*self.k, (self.h-cy)*self.k, <EOL>(cx+rx)*self.k, (self.h-(cy-ly))*self.k, <EOL>(cx+lx)*self.k, (self.h-(cy-ry))*self.k, <EOL>cx*self.k, (self.h-(cy-ry))*self.k))<EOL>self._out(sprintf('<STR_LIT>', <EOL>(cx-lx)*self.k, (self.h-(cy-ry))*self.k, <EOL>(cx-rx)*self.k, (self.h-(cy-ly))*self.k, <EOL>(cx-rx)*self.k, (self.h-cy)*self.k))<EOL>self._out(sprintf('<STR_LIT>', <EOL>(cx-rx)*self.k, (self.h-(cy+ly))*self.k, <EOL>(cx-lx)*self.k, (self.h-(cy+ry))*self.k, <EOL>cx*self.k, (self.h-(cy+ry))*self.k))<EOL>self._out(sprintf('<STR_LIT>', <EOL>(cx+lx)*self.k, (self.h-(cy+ry))*self.k, <EOL>(cx+rx)*self.k, (self.h-(cy+ly))*self.k, <EOL>(cx+rx)*self.k, (self.h-cy)*self.k, <EOL>op))<EOL>
Draw a ellipse