def test_MultiPolygons(): glyph = MultiPolygons() assert glyph.xs is None assert glyph.ys is None check_fill_properties(glyph) check_line_properties(glyph) check_properties_existence(glyph, [ "xs", "ys", ], FILL, LINE, GLYPH)
def test_MultiPolygons() -> None: glyph = MultiPolygons() assert glyph.xs == field("xs") assert glyph.ys == field("ys") check_fill_properties(glyph) check_hatch_properties(glyph) check_line_properties(glyph) check_properties_existence(glyph, [ "xs", "ys", ], FILL, HATCH, LINE, GLYPH)
'exterior': [1, 1.5, 1.5], 'holes': [] }]] xs = [[[p['exterior'], *p['holes']] for p in mp] for mp in xs_dict] ys = [[[p['exterior'], *p['holes']] for p in mp] for mp in ys_dict] source = ColumnDataSource(dict(xs=xs, ys=ys)) plot = Plot(title=None, plot_width=300, plot_height=300, min_border=0, toolbar_location=None) glyph = MultiPolygons(xs="xs", ys="ys", line_width=2) plot.add_glyph(source, glyph) xaxis = LinearAxis() plot.add_layout(xaxis, 'below') yaxis = LinearAxis() plot.add_layout(yaxis, 'left') plot.add_layout(Grid(dimension=0, ticker=xaxis.ticker)) plot.add_layout(Grid(dimension=1, ticker=yaxis.ticker)) curdoc().add_root(plot) show(plot)
ImageURL( x="x", y="y", w=0.4, h=0.4, url=dict( value="https://bokeh.pydata.org/en/latest/_static/images/logo.png" ), anchor="center")), ("line", Line(x="x", y="y", line_color="#F46D43")), ("multi_line", MultiLine(xs="xs", ys="ys", line_color="#8073AC", line_width=2)), ("multi_polygons", MultiPolygons(xs="xsss", ys="ysss", line_color="#8073AC", fill_color="#FB9A99", line_width=2)), ("oval", Oval(x="x", y="y", width=screen(15), height=screen(25), angle=-0.7, fill_color="#1D91C0")), ("patch", Patch(x="x", y="y", fill_color="#A6CEE3")), ("patches", Patches(xs="xs", ys="ys", fill_color="#FB9A99")), ("quad", Quad(left="x", right="xp01", top="y", bottom="ym01", fill_color="#B3DE69")), ("quadratic",