in chartify/_core/chart.py [0:0]
def _add_source_to_figure(self):
"""Create the source glyph and add it to the bokeh figure."""
source_text = """ch.set_source_label('Source')"""
if self._blank_labels:
source_text = ""
source_text_color = "#898989"
source_font_size = "10px"
_source = bokeh.models.Label(
x=self.style.plot_width * 0.9,
y=0,
x_units="screen",
y_units="screen",
level="overlay",
text=source_text,
text_color=source_text_color,
text_font_size=source_font_size,
text_align="right",
name="subtitle",
)
self.figure.add_layout(_source, "below")
return _source