genome_spy.ViewSpec

class genome_spy.ViewSpec(annotate=Undefined, axes=Undefined, baseUrl=Undefined, columns=Undefined, concat=Undefined, config=Undefined, cursor=Undefined, data=Undefined, datasets=Undefined, description=Undefined, domainInert=Undefined, encoding=Undefined, facet=Undefined, hconcat=Undefined, height=Undefined, layer=Undefined, legends=Undefined, mark=Undefined, multiscale=Undefined, name=Undefined, opacity=Undefined, overhang=Undefined, padding=Undefined, params=Undefined, predicates=Undefined, resolve=Undefined, scales=Undefined, separator=Undefined, spacing=Undefined, spec=Undefined, stops=Undefined, surround=Undefined, templates=Undefined, title=Undefined, transform=Undefined, vconcat=Undefined, view=Undefined, viewportHeight=Undefined, viewportWidth=Undefined, visible=Undefined, width=Undefined, zindex=Undefined, **kwds)View on GitHub

Bases: GenomeSpySchema

Generated wrapper for ViewSpec.

Methods

annotate(value)

Return a copy with annotate updated.

axes([value, x, y])

Return a copy with axes updated.

baseUrl(value)

Return a copy with baseUrl updated.

columns(value)

Return a copy with columns updated.

concat(value)

Return a copy with concat updated.

config([value, arrow, axis, axisBottom, ...])

Return a copy with a GenomeSpyConfig config.

copy(*[, deep])

Return a copy with optional keyword updates.

cursor([value, expr])

Return a copy with a ExprRef cursor.

data([value, description, ...])

Return a copy with data updated.

datasets(value)

Return a copy with datasets updated.

description(value)

Return a copy with description updated.

domainInert(value)

Return a copy with domainInert updated.

encoding([value, angle, color, direction, ...])

Return a copy with a Encoding encoding.

facet([value, column, row])

Return a copy with a FacetMapping facet.

hconcat(value)

Return a copy with hconcat updated.

height([value, grow, maxPx, minPx, px])

Return a copy with a SizeDef height.

layer(value)

Return a copy with layer updated.

legends([value, angle, color, dx, dy, fill, ...])

Return a copy with legends updated.

mark([value, align, angle, ...])

Return a copy with mark updated.

multiscale(value)

Return a copy with multiscale updated.

name(value)

Return a copy with name updated.

opacity([value, channel, expr, ...])

Return a copy with opacity updated.

overhang([value, bottom, left, right, top])

Return a copy with a OverhangConfig overhang.

padding([value, bottom, left, right, top])

Return a copy with padding updated.

params(value)

Return a copy with params updated.

predicates(value)

Return a copy with predicates updated.

resolve([value, axis, legend, scale])

Return a copy with resolve updated.

resolve_references()

Return this class schema with referenced properties merged in.

scales([value, angle, color, direction, dx, ...])

Return a copy with scales updated.

separator([value, buildIndex, clamp, clip, ...])

Return a copy with a SeparatorProps separator.

spacing(value)

Return a copy with spacing updated.

spec([value, axes, baseUrl, config, cursor, ...])

Return a copy with spec updated.

stops([value, channel, fade, metric, ...])

Return a copy with stops updated.

surround([value, bottom, left, right, top])

Return a copy with a SurroundSides surround.

templates(value)

Return a copy with templates updated.

title([value, align, anchor, angle, ...])

Return a copy with a Title title.

to_dict(*[, validate])

Serialize this schema wrapper to a JSON-compatible dictionary.

to_json(*[, validate])

Serialize this schema wrapper to formatted JSON.

transform(value)

Return a copy with transform updated.

validate(instance)

Validate an instance against this wrapper's schema.

vconcat(value)

Return a copy with vconcat updated.

view([value, fill, fillOpacity, shadowBlur, ...])

Return a copy with a ViewBackground view.

viewportHeight([value, anchor, expr, grow, ...])

Return a copy with a ViewportSizeDef viewportHeight.

viewportWidth([value, anchor, expr, grow, ...])

Return a copy with a ViewportSizeDef viewportWidth.

visible(value)

Return a copy with visible updated.

width([value, grow, maxPx, minPx, px])

Return a copy with a SizeDef width.

zindex(value)

Return a copy with zindex updated.

annotate(value)View on GitHub

Return a copy with annotate updated.

axes(value=Undefined, /, *, x=Undefined, y=Undefined)View on GitHub

Return a copy with axes updated.

Parameters:
  • x (dict[str, Any]) – Schema-defined x property.

  • y (dict[str, Any]) – Schema-defined y property.

baseUrl(value)View on GitHub

Return a copy with baseUrl updated.

columns(value)View on GitHub

Return a copy with columns updated.

concat(value)View on GitHub

Return a copy with concat updated.

config(value=Undefined, /, *, arrow=Undefined, axis=Undefined, axisBottom=Undefined, axisIndex=Undefined, axisLeft=Undefined, axisLocus=Undefined, axisNominal=Undefined, axisOrdinal=Undefined, axisQuantitative=Undefined, axisRight=Undefined, axisTop=Undefined, axisX=Undefined, axisY=Undefined, header=Undefined, headerColumn=Undefined, headerRow=Undefined, legend=Undefined, legendTrack=Undefined, link=Undefined, mark=Undefined, point=Undefined, range=Undefined, rect=Undefined, rule=Undefined, scale=Undefined, style=Undefined, text=Undefined, tick=Undefined, title=Undefined, view=Undefined)View on GitHub

Return a copy with a GenomeSpyConfig config.

Parameters:
  • arrow (ArrowConfig | dict[str, Any]) – Defaults for arrow marks.

  • axis (AxisConfig | AxisConfigKwds) – Defaults shared by all axes.

  • axisBottom (AxisConfig | AxisConfigKwds) – Defaults for bottom-oriented axes.

  • axisIndex (AxisConfig | AxisConfigKwds) – Defaults for axes that visualize GenomeSpy index scales.

  • axisLeft (AxisConfig | AxisConfigKwds) – Defaults for left-oriented axes.

  • axisLocus (AxisConfig | AxisConfigKwds) – Defaults for axes that visualize GenomeSpy locus scales.

  • axisNominal (AxisConfig | AxisConfigKwds) – Defaults for axes that visualize nominal data.

  • axisOrdinal (AxisConfig | AxisConfigKwds) – Defaults for axes that visualize ordinal data.

  • axisQuantitative (AxisConfig | AxisConfigKwds) – Defaults for axes that visualize quantitative data.

  • axisRight (AxisConfig | AxisConfigKwds) – Defaults for right-oriented axes.

  • axisTop (AxisConfig | AxisConfigKwds) – Defaults for top-oriented axes.

  • axisX (AxisConfig | AxisConfigKwds) – Defaults for x axes.

  • axisY (AxisConfig | AxisConfigKwds) – Defaults for y axes.

  • header (FacetHeader | dict[str, Any]) – Defaults for facet category labels, using view-title property names.

  • headerColumn (FacetHeader | dict[str, Any]) – Defaults for column facet labels, overriding general header defaults.

  • headerRow (FacetHeader | dict[str, Any]) – Defaults for row facet labels, overriding general header defaults.

  • legend (LegendConfig | LegendConfigKwds) – Defaults shared by all legends. Set disable to true to suppress automatic legend creation by default.

  • legendTrack (LegendConfig | LegendConfigKwds) – Defaults for legends of track-like views that use index or locus scales on the x channel. __Default value:__ { "style": "track-bottom-legend" }

  • link (LinkConfig | LinkConfigKwds) – Defaults for link marks.

  • mark (MarkConfig | MarkConfigKwds) – Defaults shared by all mark types.

  • point (PointConfig | PointConfigKwds) – Defaults for point marks.

  • range (RangeConfig | RangeConfigKwds) – Named reusable ranges for channels such as shape, size, and color.

  • rect (RectConfig | RectConfigKwds) – Defaults for rect marks.

  • rule (RuleConfig | RuleConfigKwds) – Defaults for rule marks.

  • scale (ScaleConfig | ScaleConfigKwds) – Defaults for scale behavior and scale-type-specific buckets.

  • style (dict[str, Any]) – Named reusable style buckets that marks, axes, legends, titles, and views can reference through their style properties.

  • text (TextConfig | TextConfigKwds) – Defaults for text marks.

  • tick (TickConfig | dict[str, Any]) – Defaults for tick marks.

  • title (TitleConfig | TitleConfigKwds) – Defaults for view titles.

  • view (ViewConfig | ViewConfigKwds) – Defaults for view background styling, including fill, stroke, shadow, and z-order properties.

cursor(value=Undefined, /, *, expr=Undefined)View on GitHub

Return a copy with a ExprRef cursor.

Parameters:

expr (str) – The expression string.

data(value=Undefined, /, *, description=Undefined, dynamicCallbackSource=Undefined, format=Undefined, lazy=Undefined, name=Undefined, sequence=Undefined, url=Undefined, values=Undefined)View on GitHub

Return a copy with data updated.

Parameters:
  • description (str) – Schema-defined description property.

  • dynamicCallbackSource (bool) – The View class has getDynamicData() methods that provides the data. This is intended for internal use.

  • format (CsvDataFormat | dict[str, Any] | DsvDataFormat | JsonDataFormat | BedDataFormat | BedpeDataFormat | WigDataFormat | VcfDataFormat | OtherDataFormat) – Schema-defined format property.

  • lazy (LazyDataParams | dict[str, Any]) – Schema-defined lazy property.

  • name (str) – Schema-defined name property.

  • sequence (SequenceParams | dict[str, Any]) – Generate a sequence of numbers.

  • url (str | Sequence[str] | ExprRef | dict[str, Any] | UrlList | UrlTemplate) – An URL, a list of URLs, or a URL expansion definition from which to load the data set. A URL template can expand values from an ExprRef and attach the expanded value as a field to loaded rows. Gzip-compressed resources are decompressed transparently when the URL, MIME type, or payload indicates gzip content. Use the format.type property to ensure the loaded data is correctly parsed.

  • values (InlineDataset | dict[str, Any]) – The full data set, included inline. This can be an array of objects or primitive values, an object, or a string. Arrays of primitive values are ingested as objects with a data property. Strings are parsed according to the specified format type.

datasets(value)View on GitHub

Return a copy with datasets updated.

description(value)View on GitHub

Return a copy with description updated.

domainInert(value)View on GitHub

Return a copy with domainInert updated.

encoding(value=Undefined, /, *, angle=Undefined, color=Undefined, direction=Undefined, dx=Undefined, dy=Undefined, facetIndex=Undefined, fill=Undefined, fillOpacity=Undefined, key=Undefined, opacity=Undefined, order=Undefined, sample=Undefined, search=Undefined, semanticScore=Undefined, shape=Undefined, size=Undefined, stroke=Undefined, strokeOpacity=Undefined, strokeWidth=Undefined, text=Undefined, tooltip=Undefined, uniqueId=Undefined, x=Undefined, x2=Undefined, x2Offset=Undefined, xOffset=Undefined, y=Undefined, y2=Undefined, y2Offset=Undefined, yOffset=Undefined)View on GitHub

Return a copy with a Encoding encoding.

Parameters:
facet(value=Undefined, /, *, column=Undefined, row=Undefined)View on GitHub

Return a copy with a FacetMapping facet.

Parameters:
hconcat(value)View on GitHub

Return a copy with hconcat updated.

height(value=Undefined, /, *, grow=Undefined, maxPx=Undefined, minPx=Undefined, px=Undefined)View on GitHub

Return a copy with a SizeDef height.

Parameters:
  • grow (float) – Share of the remaining space. See child sizing for details.

  • maxPx (float) – Maximum size in pixels.

  • minPx (float) – Minimum size in pixels.

  • px (float) – Size in pixels

layer(value)View on GitHub

Return a copy with layer updated.

legends(value=Undefined, /, *, angle=Undefined, color=Undefined, dx=Undefined, dy=Undefined, fill=Undefined, fillOpacity=Undefined, opacity=Undefined, shape=Undefined, size=Undefined, stroke=Undefined, strokeOpacity=Undefined, strokeWidth=Undefined, x2Offset=Undefined, xOffset=Undefined, y2Offset=Undefined, yOffset=Undefined)View on GitHub

Return a copy with legends updated.

Parameters:
  • angle (Legend | LegendKwds) – Schema-defined angle property.

  • color (Legend | LegendKwds) – Schema-defined color property.

  • dx (Legend | LegendKwds) – Schema-defined dx property.

  • dy (Legend | LegendKwds) – Schema-defined dy property.

  • fill (Legend | LegendKwds) – Schema-defined fill property.

  • fillOpacity (Legend | LegendKwds) – Schema-defined fillOpacity property.

  • opacity (Legend | LegendKwds) – Schema-defined opacity property.

  • shape (Legend | LegendKwds) – Schema-defined shape property.

  • size (Legend | LegendKwds) – Schema-defined size property.

  • stroke (Legend | LegendKwds) – Schema-defined stroke property.

  • strokeOpacity (Legend | LegendKwds) – Schema-defined strokeOpacity property.

  • strokeWidth (Legend | LegendKwds) – Schema-defined strokeWidth property.

  • x2Offset (Legend | LegendKwds) – Schema-defined x2Offset property.

  • xOffset (Legend | LegendKwds) – Schema-defined xOffset property.

  • y2Offset (Legend | LegendKwds) – Schema-defined y2Offset property.

  • yOffset (Legend | LegendKwds) – Schema-defined yOffset property.

mark(value=Undefined, /, *, align=Undefined, angle=Undefined, arcFadingDistance=Undefined, arcHeightFactor=Undefined, baseline=Undefined, buildIndex=Undefined, clamp=Undefined, clampApex=Undefined, clip=Undefined, color=Undefined, cornerRadius=Undefined, cornerRadiusBottomLeft=Undefined, cornerRadiusBottomRight=Undefined, cornerRadiusTopLeft=Undefined, cornerRadiusTopRight=Undefined, cullByVisibleRange=Undefined, cursor=Undefined, direction=Undefined, dx=Undefined, dy=Undefined, fill=Undefined, fillGradientStrength=Undefined, fillOpacity=Undefined, filled=Undefined, fitToBand=Undefined, flushX=Undefined, flushY=Undefined, font=Undefined, fontStyle=Undefined, fontWeight=Undefined, geometricZoomBound=Undefined, hatch=Undefined, headAngle=Undefined, headNotchAngle=Undefined, headPlacement=Undefined, headShape=Undefined, headSpacing=Undefined, headWidth=Undefined, inwardStroke=Undefined, linkShape=Undefined, logoLetters=Undefined, maxChordLength=Undefined, minArcHeight=Undefined, minHeight=Undefined, minLength=Undefined, minOpacity=Undefined, minPickingSize=Undefined, minSize=Undefined, minStemLength=Undefined, minWidth=Undefined, noFadingOnPointSelection=Undefined, noFadingOnSecondPass=Undefined, opacity=Undefined, orient=Undefined, paddingX=Undefined, paddingY=Undefined, sampleFacetPadding=Undefined, segments=Undefined, semanticScore=Undefined, semanticZoomFraction=Undefined, shadowBlur=Undefined, shadowColor=Undefined, shadowOffsetX=Undefined, shadowOffsetY=Undefined, shadowOpacity=Undefined, shape=Undefined, size=Undefined, squeeze=Undefined, startNotch=Undefined, stem=Undefined, stroke=Undefined, strokeAlign=Undefined, strokeCap=Undefined, strokeDash=Undefined, strokeDashOffset=Undefined, strokeOpacity=Undefined, strokeWidth=Undefined, style=Undefined, text=Undefined, thickness=Undefined, tooltip=Undefined, type=Undefined, viewportEdgeFadeDistanceBottom=Undefined, viewportEdgeFadeDistanceLeft=Undefined, viewportEdgeFadeDistanceRight=Undefined, viewportEdgeFadeDistanceTop=Undefined, viewportEdgeFadeWidthBottom=Undefined, viewportEdgeFadeWidthLeft=Undefined, viewportEdgeFadeWidthRight=Undefined, viewportEdgeFadeWidthTop=Undefined, x=Undefined, x2=Undefined, x2Offset=Undefined, xOffset=Undefined, y=Undefined, y2=Undefined, y2Offset=Undefined, yOffset=Undefined)View on GitHub

Return a copy with mark updated.

Parameters:
  • align (Align_T) – The horizontal alignment of the text. One of "left", "center", or "right". Default value: "left"

  • angle (float | ExprRef | dict[str, Any]) – Schema-defined angle property.

  • arcFadingDistance (Sequence[float] | Literal[False] | ExprRef | dict[str, Any]) – The fading distance range for "arc" and "dome" shapes, in logical screen pixels. Opacity fades smoothly from one to zero between these perpendicular distances from the line joining the rendered endpoints. For domes, this is the baseline rather than the apex position, regardless of orientation, direction, or the scale used for height. Both false and [0, 0] disable fading. Default value: false

  • arcHeightFactor (float | ExprRef | dict[str, Any]) – Scaling factor for the "arc” shape’s height. The default value 1.0 produces roughly circular arcs. Default value: 1.0

  • baseline (Baseline_T) – The vertical alignment of the text. One of "top", "middle", "bottom". Default value: "bottom"

  • buildIndex (bool) – Schema-defined buildIndex property.

  • clamp (bool | Literal['x'] | Literal['y']) – Schema-defined clamp property.

  • clampApex (bool | ExprRef | dict[str, Any]) – Whether the apex of the "dome" shape is clamped to the viewport edge. When over a half of the dome is located outside the viewport, clamping allows for more accurate reading of the value encoded by the apex’ position. Default value: false

  • clip (bool | Literal['x'] | Literal['y'] | Literal['never']) – Schema-defined clip property.

  • color (str | ExprRef | dict[str, Any]) – Schema-defined color property.

  • cornerRadius (float | ExprRef | dict[str, Any]) – Radius of the rounded corners. Default value: 0

  • cornerRadiusBottomLeft (float | ExprRef | dict[str, Any]) – Radius of the bottom left rounded corner. Has higher precedence than cornerRadius. Default value: (None)

  • cornerRadiusBottomRight (float | ExprRef | dict[str, Any]) – Radius of the bottom right rounded corner. Has higher precedence than cornerRadius. Default value: (None)

  • cornerRadiusTopLeft (float | ExprRef | dict[str, Any]) – Radius of the top left rounded corner. Has higher precedence than cornerRadius. Default value: (None)

  • cornerRadiusTopRight (float | ExprRef | dict[str, Any]) – Radius of the top right rounded corner. Has higher precedence than cornerRadius. Default value: (None)

  • cullByVisibleRange (bool | Literal['x'] | Literal['y']) – Schema-defined cullByVisibleRange property.

  • cursor (str | ExprRef | dict[str, Any]) – Schema-defined cursor property.

  • direction (ArrowDirection_T | ExprRef | dict[str, Any]) – Direction of the arrowhead. "forward" places the arrowhead at the secondary endpoint (x2, y2). "reverse" places it at the primary endpoint (x, y). "both" places equivalent heads at both endpoints and suppresses headSpacing and startNotch for that arrow. For data-driven direction, use the direction encoding channel. __Default value:__ "forward"

  • dx (float | ExprRef | dict[str, Any]) – Schema-defined dx property.

  • dy (float | ExprRef | dict[str, Any]) – Schema-defined dy property.

  • fill (str | ExprRef | dict[str, Any]) – Schema-defined fill property.

  • fillGradientStrength (float | ExprRef | dict[str, Any]) – Gradient strength controls the amount of the gradient eye-candy effect in the fill color. Valid values are between 0 and 1. Default value: 0

  • fillOpacity (float | ExprRef | dict[str, Any]) – Schema-defined fillOpacity property.

  • filled (bool) – Schema-defined filled property.

  • fitToBand (bool | ExprRef | dict[str, Any]) – If true, sets the secondary positional channel that allows the text to be squeezed (see the squeeze property). Can be used when: 1) "band", "index", or "locus" scale is being used and 2) only the primary positional channel is specified. Expressions are evaluated when the mark is initialized and cannot change reactively. Default value: false

  • flushX (bool | ExprRef | dict[str, Any]) – If true, the text is kept inside the viewport when the range of x and x2 intersect the viewport.

  • flushY (bool | ExprRef | dict[str, Any]) – If true, the text is kept inside the viewport when the range of y and y2 intersect the viewport.

  • font (str) – The font typeface. GenomeSpy uses SDF versions of Google Fonts. Check their availability at the A-Frame Fonts repository. System fonts are not supported. Default value: "Lato"

  • fontStyle (FontStyle_T) – The font style. Valid values: "normal" and "italic". Default value: "normal"

  • fontWeight (FontWeight_T) – The font weight. The following strings and numbers are valid values: "thin" (100), "light" (300), "regular" (400), "normal" (400), "medium" (500), "bold" (700), "black" (900) Default value: "regular"

  • geometricZoomBound (float) – Enables geometric zooming. The value is the base two logarithmic zoom level where the maximum point size is reached. Default value: 0

  • hatch (Literal['none'] | Literal['diagonal'] | Literal['antiDiagonal'] | Literal['cross'] | Literal['vertical'] | Literal['horizontal'] | Literal['grid'] | Literal['dots'] | Literal['rings'] | Literal['ringsLarge'] | ExprRef | dict[str, Any]) – A hatch pattern drawn inside the mark using the stroke width, color, and opacity. The pattern is aligned in screen space and scaled by the stroke width. Default value: "none"

  • headAngle (float | ExprRef | dict[str, Any]) – Angle in degrees between the arrow axis and an outer edge of the arrowhead. Smaller values produce longer, narrower heads. Larger values produce shorter, blunter heads. Values are clamped to [1, 90]. __Default value:__ 45

  • headNotchAngle (float | ExprRef | dict[str, Any]) – Angle in degrees between the arrow axis and the arrowhead notch edge. 90 places the notch point at the tip, producing a triangular head when headAngle is less than 90. Applies to "triangle" heads. "open" heads use headAngle for the notch edge as well. Values are clamped to [1, 90]. __Default value:__ 90

  • headPlacement (Literal['inside'] | Literal['outside'] | ExprRef | dict[str, Any]) – Placement of the arrowhead relative to the encoded segment. "inside" keeps the whole arrowhead within the encoded segment. "outside" places the arrowhead beyond the encoded segment so that the head starts at the segment endpoint. __Default value:__ "inside"

  • headShape (Literal['triangle'] | Literal['open'] | ExprRef | dict[str, Any]) – Shape of the arrowhead. "triangle" draws a filled head. "open" draws an open head whose thickness matches the resolved size, even when stem is false. __Default value:__ "triangle"

  • headSpacing (float | None | ExprRef | dict[str, Any]) – Spacing between repeated arrowheads as a multiplier of resolved size. The effective spacing is at least the rendered arrowhead footprint, including stroke. If null, arrowheads are not repeated. Repetition is suppressed when direction resolves to "both". __Default value:__ null

  • headWidth (float | ExprRef | dict[str, Any]) – Width of the arrowhead as a multiplier of resolved size. Values above 1 make the arrowhead wider than the stem. __Default value:__ 3

  • inwardStroke (bool | ExprRef | dict[str, Any]) – Should the stroke only grow inwards, e.g, the diameter/outline is not affected by the stroke width. Thus, a point that has a zero size has no visible stroke. This allows strokes to be used with geometric zoom, etc. Default value: false

  • linkShape (Literal['arc'] | Literal['diagonal'] | Literal['line'] | Literal['dome'] | Literal['orthogonal'] | ExprRef | dict[str, Any]) – The shape of the link path. The "arc" shape draws a circular arc between the two points. The apex of the arc resides on the left side of the line that connects the two points. The "dome" shape draws a vertical or horizontal arc with a specific height. The primary positional channel determines the apex of the arc and the secondary determines the endpoint placement. The "diagonal" shape draws an “S”-shaped curve between the two points. The "orthogonal" shape draws two straight legs joined at a right angle, with butt caps and a miter join. Coincident endpoints draw nothing. The "line" shape draws a straight line between the two points. See an example of the different shapes below. Default value: "arc"

  • logoLetters (bool | ExprRef | dict[str, Any]) – Stretch letters so that they can be used with sequence logos, etc…

  • maxChordLength (float | ExprRef | dict[str, Any]) – The maximum length of "arc" shape’s chord in pixels. The chord is the line segment between the two points that define the arc. Limiting the chord length serves two purposes when zooming in close enough: 1) it prevents the arc from becoming a straight line and 2) it mitigates the limited precision of floating point numbers in arc rendering. Default value: 50000

  • minArcHeight (float | ExprRef | dict[str, Any]) – The minimum height of an "arc" shape. Makes very short links more clearly visible. Default value: 1.5

  • minHeight (float | ExprRef | dict[str, Any]) – The minimum height of a rectangle in pixels. The property clamps rectangles’ heights. Default value: 0

  • minLength (float | ExprRef | dict[str, Any]) – Schema-defined minLength property.

  • minOpacity (float | ExprRef | dict[str, Any]) – Clamps the minimum size-dependent opacity. The property does not affect the opacity channel. Valid values are between 0 and 1. When a rectangle would be smaller than what is specified in minHeight and minWidth, it is faded out proportionally. Example: a rectangle would be rendered as one pixel wide, but minWidth clamps it to five pixels. The rectangle is actually rendered as five pixels wide, but its opacity is multiplied by 0.2. With this setting, you can limit the factor to, for example, 0.5 to keep the rectangles more clearly visible. Default value: 0

  • minPickingSize (float | ExprRef | dict[str, Any]) – Schema-defined minPickingSize property.

  • minSize (float | ExprRef | dict[str, Any]) – Minimum resolved arrow stem thickness in pixels. Applies to numeric, band-relative, and encoded size values. __Default value:__ 1

  • minStemLength (float | ExprRef | dict[str, Any]) – Minimum visible length of the arrow stem in pixels. When a non-repeated arrow is too short for the configured shape and minimum stem length, the affected notch or head angle is made blunter toward 90 degrees. For "inside" placement, this applies to "triangle" heads and is measured from the start of the stem to where the stem meets the head notch edge. For "outside" placement, this applies when startNotch is true and is measured from the start notch to the head start. Has no effect when stem is false. __Default value:__ 0

  • minWidth (float | ExprRef | dict[str, Any]) – The minimum width of a rectangle in pixels. The property clamps rectangles’ widths when the viewport is zoomed out. This property also reduces flickering of very narrow rectangles when zooming. The value should generally be at least one. Default value: 1

  • noFadingOnPointSelection (bool | ExprRef | dict[str, Any]) – Alias for noFadingOnSecondPass, used only when that property is unspecified. Requires active conditional ordering; selections in color or size encodings alone no longer suppress fading.

  • noFadingOnSecondPass (bool | ExprRef | dict[str, Any]) – Shows foreground arcs in full by disabling distance fading during the second visual pass of an active conditional order encoding. Configure selected links with the higher order value to draw them unfaded above other links. Reversing the order values instead exempts the unselected links. Has no effect without active conditional ordering, including when all selections are empty. Picking always uses normal fading. __Default value:__ false

  • opacity (float | ExprRef | dict[str, Any]) – Schema-defined opacity property.

  • orient (Literal['vertical', 'horizontal'] | Literal['vertical'] | Literal['horizontal'] | ExprRef | dict[str, Any]) – Schema-defined orient property.

  • paddingX (float | ExprRef | dict[str, Any]) – The horizontal padding, in pixels, when the x2 channel is used for ranged text. Default value: 0

  • paddingY (float | ExprRef | dict[str, Any]) – The vertical padding, in pixels, when the y2 channel is used for ranged text. Default value: 0

  • sampleFacetPadding (float) – Additional padding used by sample facets. Default value: 0.1

  • segments (float | ExprRef | dict[str, Any]) – The number of segments in the bézier curve. Affects the rendering quality and performance. Use a higher value for a smoother curve. Default value: 101

  • semanticScore (float | ExprRef | dict[str, Any]) – The semantic score used by semantic zooming in the point mark. This is primarily intended for internal use. Default value: 0

  • semanticZoomFraction (float | ExprRef | dict[str, Any]) – TODO Default value: 0.02

  • shadowBlur (float | ExprRef | dict[str, Any]) – The blur radius of the drop shadow in pixels. Higher values produce a more diffuse shadow. Default value: 0

  • shadowColor (str | ExprRef | dict[str, Any]) – The color of the drop shadow. Any valid CSS color string is allowed. Default value: "black"

  • shadowOffsetX (float | ExprRef | dict[str, Any]) – The horizontal offset of the drop shadow in pixels. Positive values move the shadow to the right. Default value: 0

  • shadowOffsetY (float | ExprRef | dict[str, Any]) – The vertical offset of the drop shadow in pixels. Positive values move the shadow downward. Default value: 0

  • shadowOpacity (float | ExprRef | dict[str, Any]) – The opacity of the drop shadow. Value between 0 (fully transparent) and 1 (fully opaque). Default value: 0 (disabled)

  • shape (str | ExprRef | dict[str, Any]) – One of "circle", "square", "cross", "x", "+", "diamond", "triangle-up", "triangle-down", "triangle-right", "triangle-left", "tick-up", "tick-down", "tick-right", or "tick-left". The "x" and "+" shapes are stroke-only and use strokeWidth for their line thickness. Default value: "circle"

  • size (float | ArrowRelativeSize | dict[str, Any] | ExprRef) – Schema-defined size property.

  • squeeze (bool | ExprRef | dict[str, Any]) – If the squeeze property is true and secondary positional channels (x2 and/or y2) are used, the text is scaled to fit mark’s width and/or height. Default value: true

  • startNotch (bool | ExprRef | dict[str, Any]) – Whether to draw a notch at the start of the arrow. The start notch uses the same slope as the arrowhead edge. It is suppressed when direction resolves to "both" because a bidirectional arrow has no unique start. __Default value:__ false

  • stem (bool | ExprRef | dict[str, Any]) – Whether to draw the arrow stem. When false, the resolved size still controls open-head thickness. minStemLength has no effect when the stem is hidden. __Default value:__ true

  • stroke (str | ExprRef | dict[str, Any]) – Schema-defined stroke property.

  • strokeAlign (StrokeAlign_T | ExprRef | dict[str, Any]) – Position of the full-width stroke band relative to the nominal body. Inside strokes extend inward by strokeWidth, centered strokes extend half inward and half outward, and outside strokes extend entirely outward. The nominal body is unchanged. Canvas uses an outside-style approximation for all alignments. __Default value:__ "outside"

  • strokeCap (Literal['butt'] | Literal['square'] | Literal['round'] | ExprRef | dict[str, Any]) – Schema-defined strokeCap property.

  • strokeDash (Sequence[float]) – Schema-defined strokeDash property.

  • strokeDashOffset (float) – Schema-defined strokeDashOffset property.

  • strokeOpacity (float | ExprRef | dict[str, Any]) – Schema-defined strokeOpacity property.

  • strokeWidth (float | ExprRef | dict[str, Any]) – Schema-defined strokeWidth property.

  • style (str | Sequence[str]) – Schema-defined style property.

  • text (Scalar_T | ExprRef | dict[str, Any]) – The text to display. The format of numeric data can be customized by setting a format specifier to channel definition’s format property. Default value: ""

  • thickness (float) – The thickness of the tick mark in pixels. Equivalent to the size of the underlying rule mark. Default value: 1

  • tooltip (HandledTooltip | HandledTooltipKwds | None | Literal[False]) – Schema-defined tooltip property.

  • type (Literal['rect'] | Literal['arrow'] | Literal['text'] | Literal['rule'] | Literal['tick'] | Literal['link'] | Literal['point']) – Schema-defined type property.

  • viewportEdgeFadeDistanceBottom (float | ExprRef | dict[str, Any]) – Schema-defined viewportEdgeFadeDistanceBottom property.

  • viewportEdgeFadeDistanceLeft (float | ExprRef | dict[str, Any]) – Schema-defined viewportEdgeFadeDistanceLeft property.

  • viewportEdgeFadeDistanceRight (float | ExprRef | dict[str, Any]) – Schema-defined viewportEdgeFadeDistanceRight property.

  • viewportEdgeFadeDistanceTop (float | ExprRef | dict[str, Any]) – Schema-defined viewportEdgeFadeDistanceTop property.

  • viewportEdgeFadeWidthBottom (float | ExprRef | dict[str, Any]) – Schema-defined viewportEdgeFadeWidthBottom property.

  • viewportEdgeFadeWidthLeft (float | ExprRef | dict[str, Any]) – Schema-defined viewportEdgeFadeWidthLeft property.

  • viewportEdgeFadeWidthRight (float | ExprRef | dict[str, Any]) – Schema-defined viewportEdgeFadeWidthRight property.

  • viewportEdgeFadeWidthTop (float | ExprRef | dict[str, Any]) – Schema-defined viewportEdgeFadeWidthTop property.

  • x (float | ExprRef | dict[str, Any]) – Schema-defined x property.

  • x2 (float | ExprRef | dict[str, Any]) – Schema-defined x2 property.

  • x2Offset (float | ExprRef | dict[str, Any]) – Schema-defined x2Offset property.

  • xOffset (float | ExprRef | dict[str, Any]) – Schema-defined xOffset property.

  • y (float | ExprRef | dict[str, Any]) – Schema-defined y property.

  • y2 (float | ExprRef | dict[str, Any]) – Schema-defined y2 property.

  • y2Offset (float | ExprRef | dict[str, Any]) – Schema-defined y2Offset property.

  • yOffset (float | ExprRef | dict[str, Any]) – Schema-defined yOffset property.

multiscale(value)View on GitHub

Return a copy with multiscale updated.

name(value)View on GitHub

Return a copy with name updated.

opacity(value=Undefined, /, *, channel=Undefined, expr=Undefined, unitsPerPixel=Undefined, values=Undefined)View on GitHub

Return a copy with opacity updated.

Parameters:
  • channel (PrimaryPositionalChannel_T | Literal['auto']) – The positional channel whose scale domain controls the opacity. If set to "auto", both x and y scales may contribute. If omitted, x is used when available and y is used as a fallback.

  • expr (str) – The expression string.

  • unitsPerPixel (Sequence[float | ExprRef | dict[str, Any]]) – Opacity stops expressed as units (base pairs, for example) per pixel. The values must be positive. Each stop is paired with an opacity in values at the same index. Stops can be constants or expression references.

  • values (Sequence[float]) – Opacity values that match the given unitsPerPixel stops. Values outside the stop range are clamped to the nearest stop.

overhang(value=Undefined, /, *, bottom=Undefined, left=Undefined, right=Undefined, top=Undefined)View on GitHub

Return a copy with a OverhangConfig overhang.

Parameters:
  • bottom (bool) – Schema-defined bottom property.

  • left (bool) – Schema-defined left property.

  • right (bool) – Schema-defined right property.

  • top (bool) – Schema-defined top property.

padding(value=Undefined, /, *, bottom=Undefined, left=Undefined, right=Undefined, top=Undefined)View on GitHub

Return a copy with padding updated.

Parameters:
  • bottom (float) – Schema-defined bottom property.

  • left (float) – Schema-defined left property.

  • right (float) – Schema-defined right property.

  • top (float) – Schema-defined top property.

params(value)View on GitHub

Return a copy with params updated.

predicates(value)View on GitHub

Return a copy with predicates updated.

resolve(value=Undefined, /, *, axis=Undefined, legend=Undefined, scale=Undefined)View on GitHub

Return a copy with resolve updated.

Parameters:
scales(value=Undefined, /, *, angle=Undefined, color=Undefined, direction=Undefined, dx=Undefined, dy=Undefined, fill=Undefined, fillOpacity=Undefined, opacity=Undefined, shape=Undefined, size=Undefined, stroke=Undefined, strokeOpacity=Undefined, strokeWidth=Undefined, x=Undefined, x2=Undefined, x2Offset=Undefined, xOffset=Undefined, y=Undefined, y2=Undefined, y2Offset=Undefined, yOffset=Undefined)View on GitHub

Return a copy with scales updated.

Parameters:
  • angle (Scale | ScaleKwds) – Schema-defined angle property.

  • color (Scale | ScaleKwds) – Schema-defined color property.

  • direction (Scale | ScaleKwds) – Schema-defined direction property.

  • dx (Scale | ScaleKwds) – Schema-defined dx property.

  • dy (Scale | ScaleKwds) – Schema-defined dy property.

  • fill (Scale | ScaleKwds) – Schema-defined fill property.

  • fillOpacity (Scale | ScaleKwds) – Schema-defined fillOpacity property.

  • opacity (Scale | ScaleKwds) – Schema-defined opacity property.

  • shape (Scale | ScaleKwds) – Schema-defined shape property.

  • size (Scale | ScaleKwds) – Schema-defined size property.

  • stroke (Scale | ScaleKwds) – Schema-defined stroke property.

  • strokeOpacity (Scale | ScaleKwds) – Schema-defined strokeOpacity property.

  • strokeWidth (Scale | ScaleKwds) – Schema-defined strokeWidth property.

  • x (Scale | ScaleKwds) – Schema-defined x property.

  • x2 (Scale | ScaleKwds) – Schema-defined x2 property.

  • x2Offset (Scale | ScaleKwds) – Schema-defined x2Offset property.

  • xOffset (Scale | ScaleKwds) – Schema-defined xOffset property.

  • y (Scale | ScaleKwds) – Schema-defined y property.

  • y2 (Scale | ScaleKwds) – Schema-defined y2 property.

  • y2Offset (Scale | ScaleKwds) – Schema-defined y2Offset property.

  • yOffset (Scale | ScaleKwds) – Schema-defined yOffset property.

separator(value=Undefined, /, *, buildIndex=Undefined, clamp=Undefined, clip=Undefined, color=Undefined, cullByVisibleRange=Undefined, cursor=Undefined, fill=Undefined, fillOpacity=Undefined, filled=Undefined, includePlotMargin=Undefined, minLength=Undefined, opacity=Undefined, size=Undefined, stroke=Undefined, strokeAlign=Undefined, strokeCap=Undefined, strokeDash=Undefined, strokeDashOffset=Undefined, strokeOpacity=Undefined, strokeWidth=Undefined, style=Undefined, tooltip=Undefined, type=Undefined, x=Undefined, x2=Undefined, x2Offset=Undefined, xOffset=Undefined, y=Undefined, y2=Undefined, y2Offset=Undefined, yOffset=Undefined, zindex=Undefined)View on GitHub

Return a copy with a SeparatorProps separator.

Parameters:
  • buildIndex (bool) – Whether the x channel should build an index for efficient subset rendering. If omitted, GenomeSpy enables indexing automatically for positional x encodings.

  • clamp (bool | Literal['x'] | Literal['y']) – Clamps projected anchors or range endpoints to the view before constructing mark geometry. true clamps both axes; "x" or "y" selects one axis. Position offsets are included. For rectangles, clamping keeps outlines around the visible part of a group during zooming. With clip: false, full strokes remain visible at the boundary; symbols, arrowheads, and text glyphs can extend beyond it. Rectangles and explicit text ranges collapsed on a clamped axis are hidden. Rules and ticks intersect the selected bounds without changing direction; excluded or collapsed segments are hidden. Zero-length rules are hidden even when clamp is false. Links and arrows with coincident endpoints are hidden. Shared scales and their inversion are unchanged. __Default value:__ false

  • clip (bool | Literal['x'] | Literal['y'] | Literal['never']) – Controls whether the mark is clipped to the UnitView’s rectangle. The values "x" and "y" clip only in the corresponding screen-space direction. Inherited clipping from parent containers still applies unless "never" is used. __Default value:__ true when either positional scale is zoomable; otherwise false

  • color (str | ExprRef | dict[str, Any]) – Color of the mark. Affects either fill or stroke, depending on the filled property.

  • cullByVisibleRange (bool | Literal['x'] | Literal['y']) – Hide point-like mark instances whose anchor falls outside the inherited visible range in the given screen-space direction.

  • cursor (str | ExprRef | dict[str, Any]) – Mouse cursor shown while the pointer is over the mark. Mark cursor takes precedence over enclosing view cursors. __Default value:__ browser default

  • fill (str | ExprRef | dict[str, Any]) – The fill color.

  • fillOpacity (float | ExprRef | dict[str, Any]) – The fill opacity. Value between 0 and 1.

  • filled (bool) – Whether the color represents the fill color (true) or the stroke color (false).

  • includePlotMargin (bool) – Whether separators extend into the plot margin (axes/padding) around the grid. __Default value:__ true

  • minLength (float | ExprRef | dict[str, Any]) – The minimum stroke length in pixels. Use this property to ensure that very short strokes remain visible even when the user zooms out. Default value: 0

  • opacity (float | ExprRef | dict[str, Any]) – Opacity of the mark. Affects fillOpacity or strokeOpacity, depending on the filled property.

  • size (float | ExprRef | dict[str, Any]) – Stroke width of "link" and "rule" marks in pixels, the area of the bounding square of "point" mark, or the font size of "text" mark.

  • stroke (str | ExprRef | dict[str, Any]) – The stroke color

  • strokeAlign (StrokeAlign_T | ExprRef | dict[str, Any]) – Position of the full-width stroke band relative to the nominal body. Inside strokes extend inward by strokeWidth, centered strokes extend half inward and half outward, and outside strokes extend entirely outward. The nominal body is unchanged. Canvas uses an outside-style approximation for all alignments. __Default value:__ "outside"

  • strokeCap (Literal['butt'] | Literal['square'] | Literal['round'] | ExprRef | dict[str, Any]) – The style of stroke ends. Available choices: "butt", "round”, and "square". Default value: "butt"

  • strokeDash (Sequence[float]) – An array of of alternating stroke and gap lengths or null for solid strokes. Default value: null

  • strokeDashOffset (float) – An offset for the stroke dash pattern. Default value: 0

  • strokeOpacity (float | ExprRef | dict[str, Any]) – The stroke opacity. Value between 0 and 1.

  • strokeWidth (float | ExprRef | dict[str, Any]) – The stroke width in pixels.

  • style (str | Sequence[str]) – Named style reference(s) resolved from config.style. If an array is provided, later styles override earlier ones.

  • tooltip (HandledTooltip | HandledTooltipKwds | None | Literal[False]) – Tooltip handler. If false, no tooltip is shown but the mark remains available for renderer picking and mark interactions. If null, no tooltip is shown and the mark is excluded from picking unless its view declares a point selection; a point selection overrides this picking opt-out. If string, specifies the tooltip handler to use.

  • type (Literal['rule']) – Schema-defined type property.

  • x (float | ExprRef | dict[str, Any]) – Position on the x axis.

  • x2 (float | ExprRef | dict[str, Any]) – The secondary position on the x axis.

  • x2Offset (float | ExprRef | dict[str, Any]) – Offset of the x2 coordinate in logical pixels. When x2 is implicit, it inherits xOffset unless this property is specified. Default value: inherited from xOffset for an implicit x2, otherwise 0

  • xOffset (float | ExprRef | dict[str, Any]) – Offset of the x coordinate in logical pixels. Default value: 0

  • y (float | ExprRef | dict[str, Any]) – Position on the y axis.

  • y2 (float | ExprRef | dict[str, Any]) – The secondary position on the y axis.

  • y2Offset (float | ExprRef | dict[str, Any]) – Offset of the y2 coordinate in logical pixels. When y2 is implicit, it inherits yOffset unless this property is specified. Default value: inherited from yOffset for an implicit y2, otherwise 0

  • yOffset (float | ExprRef | dict[str, Any]) – Offset of the y coordinate in logical pixels. Default value: 0

  • zindex (float) – Z-order of the separator relative to the view content. Values greater than 0 render after the view marks. Values less than or equal to 0 render before the marks. __Default value:__ 0

spacing(value)View on GitHub

Return a copy with spacing updated.

spec(value=Undefined, /, *, axes=Undefined, baseUrl=Undefined, config=Undefined, cursor=Undefined, data=Undefined, datasets=Undefined, description=Undefined, domainInert=Undefined, encoding=Undefined, height=Undefined, import_=Undefined, layer=Undefined, legends=Undefined, mark=Undefined, multiscale=Undefined, name=Undefined, opacity=Undefined, overhang=Undefined, padding=Undefined, params=Undefined, predicates=Undefined, resolve=Undefined, scales=Undefined, stops=Undefined, templates=Undefined, title=Undefined, transform=Undefined, view=Undefined, viewportHeight=Undefined, viewportWidth=Undefined, visible=Undefined, width=Undefined, zindex=Undefined)View on GitHub

Return a copy with spec updated.

Parameters:
stops(value=Undefined, /, *, channel=Undefined, fade=Undefined, metric=Undefined, transition=Undefined, values=Undefined)View on GitHub

Return a copy with stops updated.

Parameters:
  • channel (PrimaryPositionalChannel_T | Literal['auto']) – Schema-defined channel property.

  • fade (float) – Relative transition width around each stop. For each stop value s, the fade transition is evaluated in the range: - upper edge: s * (1 + fade) - lower edge: s * (1 - fade) __Default value:__ 0.5

  • metric (Literal['unitsPerPixel']) – Schema-defined metric property.

  • transition (LerpTransition | dict[str, Any]) – Cross-fades stages in time after a stop selects a new detail level. The selected stage settles fully visible and all other stages settle hidden. This differs from fade, which keeps adjacent stages partly visible within a zoom range. Transitioned stops require channel to be either "x" or "y" and cannot be combined with fade.

  • values (Sequence[float | ExprRef | dict[str, Any]]) – Schema-defined values property.

surround(value=Undefined, /, *, bottom=Undefined, left=Undefined, right=Undefined, top=Undefined)View on GitHub

Return a copy with a SurroundSides surround.

Parameters:
templates(value)View on GitHub

Return a copy with templates updated.

title(value=Undefined, /, *, align=Undefined, anchor=Undefined, angle=Undefined, baseline=Undefined, color=Undefined, dx=Undefined, dy=Undefined, font=Undefined, fontSize=Undefined, fontStyle=Undefined, fontWeight=Undefined, frame=Undefined, offset=Undefined, orient=Undefined, reserve=Undefined, style=Undefined, subtitle=Undefined, subtitleColor=Undefined, subtitleFont=Undefined, subtitleFontSize=Undefined, subtitleFontStyle=Undefined, subtitleFontWeight=Undefined, subtitlePadding=Undefined, text=Undefined, zindex=Undefined)View on GitHub

Return a copy with a Title title.

Parameters:
  • align (Align_T) – Horizontal text alignment for title text. One of "left", "center", or "right".

  • anchor (TitleAnchor_T) – 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.

  • angle (float | ExprRef | dict[str, Any]) – Angle in degrees of title and subtitle text.

  • baseline (Baseline_T) – Vertical text baseline for title and subtitle text. One of "alphabetic" (default), "top", "middle", or "bottom".

  • color (str | ExprRef | dict[str, Any]) – Text color for title text.

  • dx (float) – Delta offset for title and subtitle text x-coordinate.

  • dy (float) – Delta offset for title and subtitle text y-coordinate.

  • font (str) – Font name for title text.

  • fontSize (float | ExprRef | dict[str, Any]) – Font size in pixels for title text.

  • fontStyle (FontStyle_T) – Font style for title text.

  • fontWeight (FontWeight_T) – 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).

  • frame (TitleFrame_T) – The reference frame for the title anchor. "group" anchors the title along the plot area. "bounds" anchors the title along the full bounds, including axes, legends, and other reserved space. __Default value:__ "group"

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

  • orient (TitleOrient_T) – Default title orientation ("none", "top", "bottom", "left", or "right")

  • reserve (bool) – Whether the title reserves layout space outside the plot area. Reserved titles are placed outside axes, legends, and other guide space on the same side. Setting this to false lets the title render without affecting layout, enabling wilder layouts where titles may overlap nearby content. __Default value:__ true

  • style (str | Sequence[str]) – A mark style property to apply to the title text mark. If not specified, a default style of "group-title" is applied.

  • subtitle (str | ExprRef | dict[str, Any]) – The subtitle text.

  • subtitleColor (str | ExprRef | dict[str, Any]) – Text color for subtitle text.

  • subtitleFont (str) – Font name for subtitle text.

  • subtitleFontSize (float | ExprRef | dict[str, Any]) – Font size in pixels for subtitle text.

  • subtitleFontStyle (FontStyle_T) – Font style for subtitle text.

  • subtitleFontWeight (FontWeight_T) – 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).

  • subtitlePadding (float) – Padding in pixels between title and subtitle text. __Default value:__ 3

  • text (str | ExprRef | dict[str, Any]) – The title text.

  • zindex (float) – Z-order of the title relative to the view content. Values greater than 0 render after the view marks. Values less than or equal to 0 render before the marks. __Default value:__ 1

transform(value)View on GitHub

Return a copy with transform updated.

vconcat(value)View on GitHub

Return a copy with vconcat updated.

view(value=Undefined, /, *, fill=Undefined, fillOpacity=Undefined, shadowBlur=Undefined, shadowColor=Undefined, shadowOffsetX=Undefined, shadowOffsetY=Undefined, shadowOpacity=Undefined, stroke=Undefined, strokeOpacity=Undefined, strokeWidth=Undefined, strokeZindex=Undefined, style=Undefined, zindex=Undefined)View on GitHub

Return a copy with a ViewBackground view.

Parameters:
  • fill (str | ExprRef | dict[str, Any]) – Fill color of the view background.

  • fillOpacity (float) – Opacity of the view background fill.

  • shadowBlur (float | ExprRef | dict[str, Any]) – The blur radius of the drop shadow in pixels. Higher values produce a more diffuse shadow. Default value: 0

  • shadowColor (str | ExprRef | dict[str, Any]) – The color of the drop shadow. Any valid CSS color string is allowed. Default value: "black"

  • shadowOffsetX (float | ExprRef | dict[str, Any]) – The horizontal offset of the drop shadow in pixels. Positive values move the shadow to the right. Default value: 0

  • shadowOffsetY (float | ExprRef | dict[str, Any]) – The vertical offset of the drop shadow in pixels. Positive values move the shadow downward. Default value: 0

  • shadowOpacity (float | ExprRef | dict[str, Any]) – The opacity of the drop shadow. Value between 0 (fully transparent) and 1 (fully opaque). Default value: 0 (disabled)

  • stroke (str | ExprRef | dict[str, Any]) – Stroke color of the view background.

  • strokeOpacity (float) – Opacity of the view background stroke.

  • strokeWidth (float) – Stroke width of the view background border.

  • strokeZindex (float) – Z-order of the background stroke relative to the view content. Values greater than 0 render after the view marks. Values less than or equal to 0 render before the marks. __Default value:__ 0, or 10 when the view content is clipped or scrollable.

  • style (str | Sequence[str]) – Named style reference(s) resolved from config.style. If an array is provided, later styles override earlier ones. __Default value:__ "cell"

  • zindex (float) – Z-order of the background fill relative to the view content. Values greater than 0 render after the view marks. Values less than or equal to 0 render before the marks. __Default value:__ 0

viewportHeight(value=Undefined, /, *, anchor=Undefined, expr=Undefined, grow=Undefined, maxPx=Undefined, minPx=Undefined, px=Undefined)View on GitHub

Return a copy with a ViewportSizeDef viewportHeight.

Parameters:
  • anchor (Literal['start', 'end']) – Edge used for initial placement and preserved when content or viewport dimensions change. "start" means left for width and top for height; "end" means right or bottom. Content smaller than the viewport aligns to that edge too. Manual scrolling changes the pixel distance from it. __Default value:__ "start"

  • expr (str) – The expression string.

  • grow (float) – Share of the remaining space. See child sizing for details.

  • maxPx (float) – Maximum size in pixels.

  • minPx (float) – Minimum size in pixels.

  • px (float) – Size in pixels

viewportWidth(value=Undefined, /, *, anchor=Undefined, expr=Undefined, grow=Undefined, maxPx=Undefined, minPx=Undefined, px=Undefined)View on GitHub

Return a copy with a ViewportSizeDef viewportWidth.

Parameters:
  • anchor (Literal['start', 'end']) – Edge used for initial placement and preserved when content or viewport dimensions change. "start" means left for width and top for height; "end" means right or bottom. Content smaller than the viewport aligns to that edge too. Manual scrolling changes the pixel distance from it. __Default value:__ "start"

  • expr (str) – The expression string.

  • grow (float) – Share of the remaining space. See child sizing for details.

  • maxPx (float) – Maximum size in pixels.

  • minPx (float) – Minimum size in pixels.

  • px (float) – Size in pixels

visible(value)View on GitHub

Return a copy with visible updated.

width(value=Undefined, /, *, grow=Undefined, maxPx=Undefined, minPx=Undefined, px=Undefined)View on GitHub

Return a copy with a SizeDef width.

Parameters:
  • grow (float) – Share of the remaining space. See child sizing for details.

  • maxPx (float) – Maximum size in pixels.

  • minPx (float) – Minimum size in pixels.

  • px (float) – Size in pixels

zindex(value)View on GitHub

Return a copy with zindex updated.

copy(*, deep=True, **kwds)View on GitHub

Return a copy with optional keyword updates.

classmethod resolve_references()View on GitHub

Return this class schema with referenced properties merged in.

to_dict(*, validate=True)View on GitHub

Serialize this schema wrapper to a JSON-compatible dictionary.

to_json(*, validate=True)View on GitHub

Serialize this schema wrapper to formatted JSON.

classmethod validate(instance)View on GitHub

Validate an instance against this wrapper’s schema.