bokeh.models.renderers

Models (mostly base classes) for the various kinds of renderer types that Bokeh supports.

class DataRenderer(**kwargs)

Bases: bokeh.models.renderers.Renderer

An abstract base class for data renderer types (e.g. GlyphRenderer, TileRenderer).

JSON Prototype
{
  "id": "612ebf4c-cd80-4a9e-a652-7688c5bb946f",
  "level": "image",
  "name": null,
  "tags": [],
  "visible": true
}
class DynamicImageRenderer(**kwargs)

Bases: bokeh.models.renderers.DataRenderer

alpha

property type: alpha:Float

tile opacity 0.0 - 1.0

image_source

property type: image_source:Instance(ImageSource)

Image source to use when rendering on the plot.

render_parents

property type: render_parents:Bool

Flag enable/disable drawing of parent tiles while waiting for new tiles to arrive. Default value is True.

JSON Prototype
{
  "alpha": 1.0,
  "id": "b7caf607-6301-49b7-a8d4-f9e5e0cec067",
  "image_source": null,
  "level": "underlay",
  "name": null,
  "render_parents": true,
  "tags": [],
  "visible": true
}
class GlyphRenderer(**kwargs)

Bases: bokeh.models.renderers.DataRenderer

data_source

property type: data_source:Instance(DataSource)

Local data source to use when rendering glyphs on the plot.

glyph

property type: glyph:Instance(Glyph)

The glyph to render, in conjunction with the supplied data source and ranges.

hover_glyph

property type: hover_glyph:Instance(Glyph)

An optional glyph used for inspected points, e.g., those that are being hovered over by a HoverTool.

nonselection_glyph

property type: nonselection_glyph:Instance(Glyph)

An optional glyph used for explicitly non-selected points (i.e., non-selected when there are other points that are selected, but not when no points at all are selected.)

selection_glyph

property type: selection_glyph:Instance(Glyph)

An optional glyph used for selected points.

x_range_name

property type: x_range_name:String

A particular (named) x-range to use for computing screen locations when rendering glyphs on the plot. If unset, use the default x-range.

y_range_name

property type: y_range_name:String

A particular (named) y-range to use for computing screen locations when rendering glyphs on the plot. If unset, use the default -range.

JSON Prototype
{
  "data_source": null,
  "glyph": null,
  "hover_glyph": null,
  "id": "4780ee7e-5227-4de4-b10f-3153376e7f5e",
  "level": "glyph",
  "name": null,
  "nonselection_glyph": null,
  "selection_glyph": null,
  "tags": [],
  "visible": true,
  "x_range_name": "default",
  "y_range_name": "default"
}
class GuideRenderer(**kwargs)

Bases: bokeh.models.renderers.Renderer

A base class for all guide renderer types. GuideRenderer is not generally useful to instantiate on its own.

plot

property type: plot:Instance(Plot)

The plot to which this guide renderer is attached.

JSON Prototype
{
  "id": "24ac82ef-1353-47d7-a374-5b12b81767d8",
  "level": "overlay",
  "name": null,
  "plot": null,
  "tags": [],
  "visible": true
}
class Renderer(**kwargs)

Bases: bokeh.model.Model

An abstract base class for renderer types.

level

property type: level:Enum(‘image’, ‘underlay’, ‘glyph’, ‘annotation’, ‘overlay’, ‘tool’)

Specifies the level in which to paint this renderer.

visible

property type: visible:Bool

Is the renderer visible. Default: True

JSON Prototype
{
  "id": "a45e5673-2803-43f9-bc63-f5b880c7fdf8",
  "level": "image",
  "name": null,
  "tags": [],
  "visible": true
}
class TileRenderer(**kwargs)

Bases: bokeh.models.renderers.DataRenderer

alpha

property type: alpha:Float

tile opacity 0.0 - 1.0

render_parents

property type: render_parents:Bool

Flag enable/disable drawing of parent tiles while waiting for new tiles to arrive. Default value is True.

tile_source

property type: tile_source:Instance(TileSource)

Local data source to use when rendering glyphs on the plot.

x_range_name

property type: x_range_name:String

A particular (named) x-range to use for computing screen locations when rendering glyphs on the plot. If unset, use the default x-range.

y_range_name

property type: y_range_name:String

A particular (named) y-range to use for computing screen locations when rendering glyphs on the plot. If unset, use the default y-range.

JSON Prototype
{
  "alpha": 1.0,
  "id": "5383b1c1-fa2a-40c8-a3b5-020d8db30eea",
  "level": "underlay",
  "name": null,
  "render_parents": true,
  "tags": [],
  "tile_source": {
    "id": "79aeb6ed-35c5-4cd2-bb47-1ab3143d1a6d",
    "type": "WMTSTileSource"
  },
  "visible": true,
  "x_range_name": "default",
  "y_range_name": "default"
}