• File: path.cpython-37.pyc
  • Full Path: /home3/farmfre2/public_html/ALFA_DATA/alfasymlink/root/opt/alt/python37/lib/python3.7/site-packages/svgwrite/__pycache__/path.cpython-37.pyc
  • Date Modified: 11/23/2019 5:57 PM
  • File size: 3.02 KB
  • MIME-type: text/x-bytecode.python
  • Charset: 8 bit
B

s]@sRddlmZddlmZddlmZmZmZddlmZGdddeeeeZ	dS))BaseElement)strlist)PresentationMarkers	Transform)
to_unicodecsReZdZdZdZdfdd	ZddZedd
dZdd
dZ	fddZ
ZS)Pathz The <path> element represent the outline of a shape which can be filled,
    stroked, used as a clipping path, or any combination of the three.

    pathNcs>tt|jf|g|_|||jr:|j|j|j	dS)z
        :param `iterable` d: *coordinates*, *length* and *commands*
        :param dict attribs: additional SVG attributes
        :param extra: additional SVG attributs as keyword-arguments

        N)
superr__init__commandspushdebugZ	validatorZcheck_all_svg_attribute_valueselementnameattribs)selfdZextra)	__class__/path.pyrs

z
Path.__init__cGs|j|dS)z Push commands and coordinates onto the command stack.

        :param `iterable` elements: *coordinates*, *length* and *commands*

        N)rextend)relementsrrrr
!sz	Path.pushT+cCs"t|}ddd|}d||fS)Nr)r-z%d,%d)int)	large_arc	angle_dirZlarge_arc_flagZ
sweep_flagrrr	arc_flags)szPath.arc_flagsFcCsd|ddd|t|ttfr0|||n
|||||t||||dS)a Helper function for the elliptical-arc command.

        see SVG-Reference: http://www.w3.org/TR/SVG11/paths.html#PathData

        :param 2-tuple target: *coordinate* of the arc end point
        :param number rotation: x-axis-rotation of the ellipse in degrees
        :param number|2-tuple r: radii rx, ry when r is a *2-tuple* or rx=ry=r if r is a *number*
        :param bool large_arc: draw the arc sweep of greater than or equal to 180 degrees (**large-arc-flag**)
        :param angle_dir: ``'+|-'`` ``'+'`` means the arc will be drawn in a "positive-angle" direction (**sweep-flag**)
        :param bool absolute: indicates that target *coordinates* are absolute else they are relative to the current point

        Aa)TFN)r

isinstancefloatrrr)rtargetZrotationrrrZabsoluterrrpush_arc/s


z
Path.push_arccs$tt|jd|jd<tt|S)z Get the XML representation as `ElementTree` object.

        :return: XML `ElementTree` of this object and all its subelements

         r)rrrrr
rget_xml)r)rrrr'EszPath.get_xml)N)Tr)TrF)__name__
__module____qualname____doc__rrr
staticmethodrr%r'
__classcell__rr)rrr
s

rN)
Z
svgwrite.baserZsvgwrite.utilsrZsvgwrite.mixinsrrrrrrrrr<module>s