svg/charts/plot.py
def __draw_constant_line(self, value_label_style):
		"Draw a constant line on the y-axis with the label"
		value, label, style = value_label_style
		start = self.transform_output_coordinates((0, value))[1]
		stop = self.graph_width
		path = etree.SubElement(self.graph, 'path', {
			'd': 'M 0 %(start)s h%(stop)s' % locals(),
			'class': 'constantLine'})
		if style:
			path.set('style', style)
		text = etree.SubElement(self.graph, 'text', {
			'x': str(2),
			'y': str(start - 2),
			'class': 'constantLine'})
		text.text = label
def __draw_constant_line(self, value_label_style):
		"Draw a constant line on the y-axis with the label"
		value, label, style = value_label_style
		start = self.transform_output_coordinates((0, value))[1]
		stop = self.graph_width
		path = etree.SubElement(self.graph, 'path', {
			'd': 'M 0 %(start)s h%(stop)s' % locals(),
			'class': 'constantLine'})
		if style:
			path.set('style', style)
		text = etree.SubElement(self.graph, 'text', {
			'x': str(2),
			'y': str(start - 2),
			'class': 'constantLine'})
		text.text = label
Draw a constant line on the y-axis with the label