def testCalls(self): """ Simple calls """ for family in ("graphic", "presentation"): boldstyle = style.Style(name='Bold', family=family) dr3d.Cube(stylename=boldstyle) dr3d.Extrude(stylename=boldstyle, d="x", viewbox="0 0 1000 1000") dr3d.Rotate(stylename=boldstyle, d="x", viewbox="0 0 1000 1000") dr3d.Scene(stylename=boldstyle) dr3d.Sphere(stylename=boldstyle) draw.Caption(stylename=boldstyle) draw.Circle(stylename=boldstyle) draw.Connector(stylename=boldstyle) draw.Control(stylename=boldstyle, control="x") draw.CustomShape(stylename=boldstyle) draw.Ellipse(stylename=boldstyle) draw.Frame(stylename=boldstyle) draw.G(stylename=boldstyle) draw.Line(stylename=boldstyle, x1="0%", y1="0%", x2="100%", y2="100%") draw.Measure(stylename=boldstyle, x1="0cm", y1="0cm", x2="100%", y2="100%") draw.PageThumbnail(stylename=boldstyle) draw.Path(stylename=boldstyle, d="x", viewbox="0 0 1000 1000") draw.Polygon(stylename=boldstyle, points=((0, 0), (1, 1)), viewbox="0 0 1000 1000") draw.Polygon(stylename=boldstyle, points="0,0 1,1", viewbox="0 0 1000 1000") draw.Polyline(stylename=boldstyle, points="0,0 1,1", viewbox="0 0 1000 1000") draw.Rect(stylename=boldstyle) draw.RegularPolygon(stylename=boldstyle, corners="x") office.Annotation(stylename=boldstyle)
def testIntPoints(self): """ Points can only be integers """ draw.Polygon(points='0,0 -31,95', viewbox="-1000 -1000 1000 1000")
def test_calls(self): """ Simple calls """ chart.Chart(attributes={'class': 'chart:bar'}, height="0cm") chart.Chart(attributes={'class': 'chart:bar'}, width="0cm") draw.AreaCircle(cy="1cm", cx="1cm", r="0cm") draw.AreaPolygon(height="1cm", points="0,0 1,1", y="1cm", x="1cm", viewbox="0 0 1000 1000", width="0cm") draw.AreaPolygon(height="1cm", width="1cm", points="0,0 1,1", x="1cm", viewbox="0 0 1000 1000", y="0cm") draw.AreaPolygon(height="1cm", width="1cm", points="0,0 1,1", y="1cm", viewbox="0 0 1000 1000", x="0cm") draw.AreaPolygon(width="1cm", points="0,0 1,1", y="1cm", x="1cm", viewbox="0 0 1000 1000", height="0cm") draw.AreaRectangle(x="1cm", height="1cm", width="1cm", y="0cm") draw.AreaRectangle(y="1cm", height="1cm", width="1cm", x="0cm") draw.AreaRectangle(y="1cm", x="1cm", height="1cm", width="0cm") draw.AreaRectangle(y="1cm", x="1cm", width="1cm", height="0cm") draw.ContourPath(recreateonedit="1cm", viewbox="0 0 1000 1000", d="1cm", height="0cm") draw.ContourPath(recreateonedit="1cm", viewbox="0 0 1000 1000", d="1cm", width="0cm") draw.ContourPolygon(points="0,0 1,1", recreateonedit="1cm", viewbox="0 0 1000 1000", height="0cm") draw.ContourPolygon(points="0,0 1,1", recreateonedit="1cm", viewbox="0 0 1000 1000", width="0cm") draw.Control(control="1cm", endx="0cm") draw.Control(control="1cm", endy="0cm") draw.Control(control="1cm", height="0cm") draw.Control(control="1cm", width="0cm") draw.Control(control="1cm", x="0cm") draw.Control(control="1cm", y="0cm") draw.FillImage(href="1cm", name="1cm", height="0cm") draw.FillImage(href="1cm", name="1cm", width="0cm") draw.GluePoint(x="1cm", align="1cm", id="1cm", y="0cm", escapedirection="right") draw.GluePoint(y="1cm", align="1cm", id="1cm", x="0cm", escapedirection="right") draw.Line(x2="1cm", x1="1cm", y2="1cm", y1="0cm") draw.Line(y1="1cm", x1="1cm", y2="1cm", x2="0cm") draw.Line(y1="1cm", x2="1cm", x1="1cm", y2="0cm") draw.Line(y1="1cm", x2="1cm", x1="1cm", y2="1cm", endx="0cm") draw.Line(y1="1cm", x2="1cm", x1="1cm", y2="1cm", endy="0cm") draw.Line(y1="1cm", x2="1cm", y2="1cm", x1="0cm") draw.Measure(x2="1cm", x1="1cm", y2="1cm", y1="0cm") draw.Measure(y1="1cm", x1="1cm", y2="1cm", x2="0cm") draw.Measure(y1="1cm", x2="1cm", x1="1cm", y2="0cm") draw.Measure(y1="1cm", x2="1cm", x1="1cm", y2="1cm", endx="0cm") draw.Measure(y1="1cm", x2="1cm", x1="1cm", y2="1cm", endy="0cm") draw.Measure(y1="1cm", x2="1cm", y2="1cm", x1="0cm") draw.Path(d="1cm", viewbox="0 0 1000 1000", endx="0cm") draw.Path(d="1cm", viewbox="0 0 1000 1000", endy="0cm") draw.Path(d="1cm", viewbox="0 0 1000 1000", height="0cm") draw.Path(d="1cm", viewbox="0 0 1000 1000", width="0cm") draw.Path(d="1cm", viewbox="0 0 1000 1000", x="0cm") draw.Path(d="1cm", viewbox="0 0 1000 1000", y="0cm") draw.Polygon(points="0,0 1,1", viewbox="0 0 1000 1000", endx="0cm") draw.Polygon(points="0,0 1,1", viewbox="0 0 1000 1000", endy="0cm") draw.Polygon(points="0,0 1,1", viewbox="0 0 1000 1000", height="0cm") draw.Polygon(points="0,0 1,1", viewbox="0 0 1000 1000", width="0cm") draw.Polygon(points="0,0 1,1", viewbox="0 0 1000 1000", x="0cm") draw.Polygon(points="0,0 1,1", viewbox="0 0 1000 1000", y="0cm") draw.Polyline(points="0,0 1,1", viewbox="0 0 1000 1000", endx="0cm") draw.Polyline(points="0,0 1,1", viewbox="0 0 1000 1000", endy="0cm") draw.Polyline(points="0,0 1,1", viewbox="0 0 1000 1000", height="0cm") draw.Polyline(points="0,0 1,1", viewbox="0 0 1000 1000", width="0cm") draw.Polyline(points="0,0 1,1", viewbox="0 0 1000 1000", x="0cm") draw.Polyline(points="0,0 1,1", viewbox="0 0 1000 1000", y="0cm") draw.RegularPolygon(corners="1cm", endx="0cm") draw.RegularPolygon(corners="1cm", endy="0cm") draw.RegularPolygon(corners="1cm", height="0cm") draw.RegularPolygon(corners="1cm", width="0cm") draw.RegularPolygon(corners="1cm", x="0cm") draw.RegularPolygon(corners="1cm", y="0cm") draw.StrokeDash(name="1cm", dots1length="0cm") draw.StrokeDash(name="1cm", dots2length="0cm") presentation.Placeholder(x="1cm", height="1cm", object="1cm", width="1cm", y="0cm") presentation.Placeholder(y="1cm", height="1cm", object="1cm", width="1cm", x="0cm") presentation.Placeholder(y="1cm", x="1cm", height="1cm", object="1cm", width="0cm") presentation.Placeholder(y="1cm", x="1cm", object="1cm", width="1cm", height="0cm") style.Column(relwidth="1cm", endindent="0cm") style.Column(relwidth="1cm", spaceafter="0cm") style.Column(relwidth="1cm", spacebefore="0cm") style.Column(relwidth="1cm", startindent="0cm") style.Columns(columncount="1cm", columngap="0cm") style.TabStop(position="0cm") svg.Lineargradient(name="1cm", x1="0cm") svg.Lineargradient(name="1cm", x2="0cm") svg.Lineargradient(name="1cm", y1="0cm") svg.Lineargradient(name="1cm", y2="0cm") svg.Radialgradient(name="1cm", r="0cm")