altair.TitleConfig#

class altair.TitleConfig(align=Undefined, anchor=Undefined, angle=Undefined, aria=Undefined, baseline=Undefined, color=Undefined, dx=Undefined, dy=Undefined, font=Undefined, fontSize=Undefined, fontStyle=Undefined, fontWeight=Undefined, frame=Undefined, limit=Undefined, lineHeight=Undefined, offset=Undefined, orient=Undefined, subtitleColor=Undefined, subtitleFont=Undefined, subtitleFontSize=Undefined, subtitleFontStyle=Undefined, subtitleFontWeight=Undefined, subtitleLineHeight=Undefined, subtitlePadding=Undefined, zindex=Undefined, **kwds)#

TitleConfig schema wrapper

Mapping(required=[])

Parameters:
alignAlign

Horizontal text alignment for title text. One of "left", "center", or "right".

anchoranyOf(TitleAnchor, ExprRef)

The anchor position for placing the title and subtitle text. One of "start", "middle", or "end". For example, with an orientation of top these anchor positions map to a left-, center-, or right-aligned title.

angleanyOf(float, ExprRef)

Angle in degrees of title and subtitle text.

ariaanyOf(boolean, ExprRef)

A boolean flag indicating if ARIA attributes should be included (SVG output only). If false, the “aria-hidden” attribute will be set on the output SVG group, removing the title from the ARIA accessibility tree.

Default value: true

baselineTextBaseline

Vertical text baseline for title and subtitle text. One of "alphabetic" (default), "top", "middle", "bottom", "line-top", or "line-bottom". The "line-top" and "line-bottom" values operate similarly to "top" and "bottom", but are calculated relative to the lineHeight rather than fontSize alone.

coloranyOf(anyOf(None, Color), ExprRef)

Text color for title text.

dxanyOf(float, ExprRef)

Delta offset for title and subtitle text x-coordinate.

dyanyOf(float, ExprRef)

Delta offset for title and subtitle text y-coordinate.

fontanyOf(string, ExprRef)

Font name for title text.

fontSizeanyOf(float, ExprRef)

Font size in pixels for title text.

fontStyleanyOf(FontStyle, ExprRef)

Font style for title text.

fontWeightanyOf(FontWeight, ExprRef)

Font weight for title text. This can be either a string (e.g "bold", "normal" ) or a number ( 100, 200, 300, …, 900 where "normal" = 400 and "bold" = 700 ).

frameanyOf(anyOf(TitleFrame, string), ExprRef)

The reference frame for the anchor position, one of "bounds" (to anchor relative to the full bounding box) or "group" (to anchor relative to the group width or height).

limitanyOf(float, ExprRef)

The maximum allowed length in pixels of title and subtitle text.

lineHeightanyOf(float, ExprRef)

Line height in pixels for multi-line title text or title text with "line-top" or "line-bottom" baseline.

offsetanyOf(float, ExprRef)

The orthogonal offset in pixels by which to displace the title group from its position along the edge of the chart.

orientanyOf(TitleOrient, ExprRef)

Default title orientation ( "top", "bottom", "left", or "right" )

subtitleColoranyOf(anyOf(None, Color), ExprRef)

Text color for subtitle text.

subtitleFontanyOf(string, ExprRef)

Font name for subtitle text.

subtitleFontSizeanyOf(float, ExprRef)

Font size in pixels for subtitle text.

subtitleFontStyleanyOf(FontStyle, ExprRef)

Font style for subtitle text.

subtitleFontWeightanyOf(FontWeight, ExprRef)

Font weight for subtitle text. This can be either a string (e.g "bold", "normal" ) or a number ( 100, 200, 300, …, 900 where "normal" = 400 and "bold" = 700 ).

subtitleLineHeightanyOf(float, ExprRef)

Line height in pixels for multi-line subtitle text.

subtitlePaddinganyOf(float, ExprRef)

The padding in pixels between title and subtitle text.

zindexanyOf(float, ExprRef)

The integer z-index indicating the layering of the title group relative to other axis, mark, and legend groups.

Default value: 0.

__init__(align=Undefined, anchor=Undefined, angle=Undefined, aria=Undefined, baseline=Undefined, color=Undefined, dx=Undefined, dy=Undefined, font=Undefined, fontSize=Undefined, fontStyle=Undefined, fontWeight=Undefined, frame=Undefined, limit=Undefined, lineHeight=Undefined, offset=Undefined, orient=Undefined, subtitleColor=Undefined, subtitleFont=Undefined, subtitleFontSize=Undefined, subtitleFontStyle=Undefined, subtitleFontWeight=Undefined, subtitleLineHeight=Undefined, subtitlePadding=Undefined, zindex=Undefined, **kwds)#

Methods

__init__([align, anchor, angle, aria, ...])

copy([deep, ignore])

Return a copy of the object

from_dict(dct[, validate, _wrapper_classes])

Construct class from a dictionary representation

from_json(json_string[, validate])

Instantiate the object from a valid JSON string

resolve_references([schema])

Resolve references in the context of this object's schema or root schema.

to_dict([validate, ignore, context])

Return a dictionary representation of the object

to_json([validate, ignore, context, indent, ...])

Emit the JSON representation for this object as a string.

validate(instance[, schema])

Validate the instance against the class schema in the context of the rootschema.

validate_property(name, value[, schema])

Validate a property against property schema in the context of the rootschema