[−][src]Struct vega_lite_3::LayerEncodingBuilder
Builder for LayerEncoding
.
Methods
impl LayerEncodingBuilder
[src]
pub fn color<VALUE: Into<DefWithConditionMarkPropFieldDefStringNull>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Color of the marks – either fill or stroke color based on the filled
property of mark
definition.
By default, color
represents fill color for "area"
, "bar"
, "tick"
,
"text"
, "trail"
, "circle"
, and "square"
/ stroke color for "line"
and
"point"
.
Default value: If undefined, the default color depends on mark
config's color
property.
Note:
- For fine-grained control over both fill and stroke colors of the marks, please use the
fill
andstroke
channels. If eitherfill
orstroke
channel is specified,color
channel will be ignored. - See the scale documentation for more information about customizing color scheme.
pub fn detail<VALUE: Into<Detail>>(&mut self, value: VALUE) -> &mut Self
[src]
Additional levels of detail for grouping data in aggregate views and in line, trail, and area marks without mapping data to a specific visual channel.
pub fn fill<VALUE: Into<DefWithConditionMarkPropFieldDefStringNull>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Fill color of the marks.
Default value: If undefined, the default color depends on mark
config's color
property.
Note: When using fill
channel, color
channel will be ignored. To customize both
fill and stroke, please use fill
and stroke
channels (not fill
and color
).
pub fn fill_opacity<VALUE: Into<DefWithConditionMarkPropFieldDefNumber>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Fill opacity of the marks.
Default value: If undefined, the default opacity depends on mark
config's fillOpacity
property.
pub fn href<VALUE: Into<HrefClass>>(&mut self, value: VALUE) -> &mut Self
[src]
A URL to load upon mouse click.
pub fn key<VALUE: Into<TypedFieldDef>>(&mut self, value: VALUE) -> &mut Self
[src]
A data field to use as a unique key for data binding. When a visualization’s data is updated, the key value will be used to match data elements to existing mark instances. Use a key channel to enable object constancy for transitions over dynamic data.
pub fn latitude<VALUE: Into<LatitudeClass>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Latitude position of geographically projected marks.
pub fn latitude2<VALUE: Into<Latitude2Class>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Latitude-2 position for geographically projected ranged "area"
, "bar"
, "rect"
, and
"rule"
.
pub fn longitude<VALUE: Into<LatitudeClass>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Longitude position of geographically projected marks.
pub fn longitude2<VALUE: Into<Latitude2Class>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Longitude-2 position for geographically projected ranged "area"
, "bar"
, "rect"
,
and "rule"
.
pub fn opacity<VALUE: Into<DefWithConditionMarkPropFieldDefNumber>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Opacity of the marks.
Default value: If undefined, the default opacity depends on mark
config's opacity
property.
pub fn order<VALUE: Into<Order>>(&mut self, value: VALUE) -> &mut Self
[src]
Order of the marks.
- For stacked marks, this
order
channel encodes stack order. - For line and trail marks, this
order
channel encodes order of data points in the lines. This can be useful for creating a connected scatterplot. Settingorder
to{"value": null}
makes the line marks use the original order in the data sources. - Otherwise, this
order
channel encodes layer order of the marks.
Note: In aggregate plots, order
field should be aggregate
d to avoid creating
additional aggregation grouping.
pub fn shape<VALUE: Into<DefWithConditionMarkPropFieldDefTypeForShapeStringNull>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Shape of the mark.
- For
point
marks the supported values include:
- plotting shapes:
"circle"
,"square"
,"cross"
,"diamond"
,"triangle-up"
,"triangle-down"
,"triangle-right"
, or"triangle-left"
. - the line symbol
"stroke"
- centered directional shapes
"arrow"
,"wedge"
, or"triangle"
- a custom SVG path string (For correct sizing, custom shape paths should be defined within a square bounding box with coordinates ranging from -1 to 1 along both the x and y dimensions.)
- For
geoshape
marks it should be a field definition of the geojson data
Default value: If undefined, the default shape depends on mark
config's shape
property. ("circle"
if unset.)
pub fn size<VALUE: Into<DefWithConditionMarkPropFieldDefNumber>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Size of the mark.
- For
"point"
,"square"
and"circle"
, – the symbol size, or pixel area of the mark. - For
"bar"
and"tick"
– the bar and tick's size. - For
"text"
– the text's font size. - Size is unsupported for
"line"
,"area"
, and"rect"
. (Use"trail"
instead of line with varying size)
pub fn stroke<VALUE: Into<DefWithConditionMarkPropFieldDefStringNull>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Stroke color of the marks.
Default value: If undefined, the default color depends on mark
config's color
property.
Note: When using stroke
channel, color
channel will be ignored. To customize both
stroke and fill, please use stroke
and fill
channels (not stroke
and color
).
pub fn stroke_opacity<VALUE: Into<DefWithConditionMarkPropFieldDefNumber>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Stroke opacity of the marks.
Default value: If undefined, the default opacity depends on mark
config's strokeOpacity
property.
pub fn stroke_width<VALUE: Into<DefWithConditionMarkPropFieldDefNumber>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Stroke width of the marks.
Default value: If undefined, the default stroke width depends on mark
config's strokeWidth
property.
pub fn text<VALUE: Into<HrefClass>>(&mut self, value: VALUE) -> &mut Self
[src]
Text of the text
mark.
pub fn tooltip<VALUE: Into<RemovableValue<Tooltip>>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
The tooltip text to show upon mouse hover.
pub fn x<VALUE: Into<XClass>>(&mut self, value: VALUE) -> &mut Self
[src]
X coordinates of the marks, or width of horizontal "bar"
and "area"
without specified
x2
or width
.
The value
of this channel can be a number or a string "width"
for the width of the
plot.
pub fn x2<VALUE: Into<X2Class>>(&mut self, value: VALUE) -> &mut Self
[src]
X2 coordinates for ranged "area"
, "bar"
, "rect"
, and "rule"
.
The value
of this channel can be a number or a string "width"
for the width of the
plot.
pub fn x_error<VALUE: Into<Latitude2Class>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Error value of x coordinates for error specified "errorbar"
and "errorband"
.
pub fn x_error2<VALUE: Into<Latitude2Class>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Secondary error value of x coordinates for error specified "errorbar"
and "errorband"
.
pub fn y<VALUE: Into<YClass>>(&mut self, value: VALUE) -> &mut Self
[src]
Y coordinates of the marks, or height of vertical "bar"
and "area"
without specified
y2
or height
.
The value
of this channel can be a number or a string "height"
for the height of the
plot.
pub fn y2<VALUE: Into<Y2Class>>(&mut self, value: VALUE) -> &mut Self
[src]
Y2 coordinates for ranged "area"
, "bar"
, "rect"
, and "rule"
.
The value
of this channel can be a number or a string "height"
for the height of the
plot.
pub fn y_error<VALUE: Into<Latitude2Class>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Error value of y coordinates for error specified "errorbar"
and "errorband"
.
pub fn y_error2<VALUE: Into<Latitude2Class>>(
&mut self,
value: VALUE
) -> &mut Self
[src]
&mut self,
value: VALUE
) -> &mut Self
Secondary error value of y coordinates for error specified "errorbar"
and "errorband"
.
pub fn build(&self) -> Result<LayerEncoding, String>
[src]
Trait Implementations
impl Clone for LayerEncodingBuilder
[src]
fn clone(&self) -> LayerEncodingBuilder
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Default for LayerEncodingBuilder
[src]
fn default() -> LayerEncodingBuilder
[src]
Auto Trait Implementations
impl RefUnwindSafe for LayerEncodingBuilder
impl Send for LayerEncodingBuilder
impl Sync for LayerEncodingBuilder
impl Unpin for LayerEncodingBuilder
impl UnwindSafe for LayerEncodingBuilder
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,