Releases: patrykandpatrick/vico
v2.1.0-alpha.5
Overview
- breaking changes: none
- #353, #805 comment
Common
- Various performance-related optimizations have been made.
compose
- An issue where charts were blank in Compose Preview Screenshot Testing screenshots—even when
CartesianChartModelProducer.runTransaction
was invoked in a blocking fashion, as required for Jetpack Compose previews—has been addressed.
multiplatform
- Desktop support has been introduced.
multiplatform-m2
andmultiplatform-m3
modules have been added. These are equivalent tocompose-m2
andcompose-m3
.
v2.1.0-alpha.4
Overview
- breaking changes: none
- addressed: #1011
multiplatform
- An issue where
CartesianChart
mispositionedLegend
s has been resolved.
v2.1.0-alpha.3
Overview
compose
- In noninteractive Compose previews—which don’t support asynchronous execution—
CartesianChartHost
now handlesCartesianChartModelProducer
communication synchronously, enabling charts to display as expected. For this to work, the consumer must also move processing to the main thread—for example, by callingrunTransaction
fromrunBlocking
rather thanLaunchedEffect
. This should be done only for previews.
multiplatform
- In noninteractive Compose previews—which don’t support asynchronous execution—
CartesianChartHost
now handlesCartesianChartModelProducer
communication synchronously, enabling charts to display as expected. For this to work, the consumer must also move processing to the main thread—for example, by callingrunTransaction
fromrunBlocking
rather thanLaunchedEffect
. This should be done only for previews. - An incorrect package declaration has been amended;
CartesianLayerRangeProvider
is now incom.patrykandpatrick.vico.multiplatform.cartesian.data
. - The sample app has been made multiplatform. In this initial version, there are three multiplatform sample charts. However, multiplatform versions of all remaining sample charts will be introduced in upcoming updates. This process will be complete by the time Vico
2.1.0
is published.
-
Excluding
multiplatform
, which is experimental. (It will remain available, but breaking changes are more likely.) ↩
v2.1.0-alpha.2
Overview
- breaking changes: none
- addressed: #353
multiplatform
This new module provides Compose Multiplatform support. The currently supported platforms are Android and iOS, but this will be expanded. multiplatform
is standalone; to use it, add only the following Vico dependency:
[versions]
vico = "2.1.0-alpha.2"
# ...
[libraries]
vico = { group = "com.patrykandpatrick.vico", name = "multiplatform", version.ref = "vico" }
# ...
The multiplatform
API closely resembles that of compose
. There are some minor differences in feature set:
compose-m3
andcompose-m2
equivalents aren’t available yet. You can replicate their functionality by creating your ownMaterialTheme
-basedVicoTheme
.- A
ComponentShader
equivalent isn’t available yet. You can useShaderBrush
instead. ShapeComponent
doesn’t support shadows yet. This is due to Compose Multiplatform’sPaint
lacking shadow functionality.
A Compose Multiplatform sample app and multiplatform
coverage in the guide are being worked on and will be available by the time Vico 2.1.0
is published. However, with the similarity of compose
and multiplatform
, most of the compose
documentation applies, and you can fill in the gaps by referring to the multiplatform
API reference.
multiplatform
is experimental; it will remain available, but breaking changes are more likely. While multiplatform
is Jetpack Compose–compatible, compose
support continues. In the distant future, compose
will be removed in favor of multiplatform
, which will then be renamed to compose
.
v2.1.0-alpha.1
Warning
The old, pre-1.6.2
Maven Central coordinates are being discontinued. Those using them will receive deprecation warnings.
Overview
- breaking changes: none
- external contributors: @L-Andrade
core
DefaultCartesianMarker.LabelPosition.BelowPoint
has been introduced. This positions the label below the bottommost marked point.- The default dash and gap lengths for
LineCartesianLayer.LineStroke.Dashed
have been updated.
v1.16.1
v2.0.1
Overview
- breaking changes: none
- addressed: #993
compose
- An issue where the logical display density was obtained from
Context
instead ofLocalDensity
for sp-to-px conversion has been addressed. This problem causedLocalDensity
-based overrides to have no effect on text scaling inCartesianChart
s.
v2.0.0
This release is effectively identical to version 2.0.0-beta.7
. The following compares versions 2.0.0
and 1.16.0
.
Overview
- breaking changes: major
- addressed: #259, #265, #295, #296, #317, #349, #352, #384, #405, #413, #427, #430, #450, #469, #471, #481, #482, #483, #489, #496, #499, #535, #553, #563, #574, #585, #589, #602, #620, #623, #636, #652, #701, #713, #722, #736, #776, #785, #794, #824, #939
- external contributors: @anshu7vyas, @cristianboicu01, @L-Andrade, @MessiasLima, @Tyler-Lopez
Highlights
Vico 2.0.0 is the result of a sweeping redesign of the library. The key changes are highlighted below.
-
The overhauled API has a streamlined, consolidated structure—offering greater flexibility in a smaller footprint. Most notably, there’s now a single pair of chart-drawing and model-producing classes for both single- and multi-layer charts.
-
Candlestick charts have been introduced, with comprehensive candle customization and presets for filled and hollow candles.
-
Line charts now support dashed lines.
-
The new line-styling framework for line charts facilitates the creation of data-aware line and area fills, including color scales. It offers presets for single and double fills. In the latter, two separate styles are used—one above a given y value and one below it. A common use case is applying different colors for positive and negative y-values.
-
The reworked scroll and zoom systems offer precise control—with features that facilitate scrolling by a given number of x units, scrolling to a given x coordinate, setting the viewport width in x units, and more.
-
The new provider interfaces enable granular customization of chart layers. Key use cases include styling columns based on their y-values and displaying points only for selected entries in line charts.
-
With intelligent default y-ranges and y-axis label positioning, y-axes are more legible by default. First, a suitable power of 10 is inferred. Then, the y-range bounds are rounded outward to a multiple thereof, and labels are positioned at multiples of this power of 10.
-
With the new and improved built-in axis-item placers, x-axes can dynamically adjust their item spacing based on the zoom factor, preventing label truncation. There’s also a built-in step-based item placer for y-axes.
-
The redesigned marker framework provides more detailed information on the marked points, simplifying value formatting and facilitating the implementation of context-aware behavior. Thanks to these improvements, the built-in marker’s default formatter now intelligently determines when to sum values and when to only list them individually.
-
The expanded extra framework enables model-synchronized updates in multiple new areas.
-
Series values are now stored using
Double
instead ofFloat
, eliminating the need for most range- and precision-reducing transformations, especially for Unix timestamps. -
The new, more powerful cache mechanism boosts drawing performance. It retains far more reusable data between frames and, in addition, can share it between multiple instances of the same component.
-
For Jetpack Compose, stability-related enhancements have been made, facilitating composable skipping and thus improving performance.
-
The new defaults offer a refreshed, more versatile appearance out of the box.
-
The expanded, reorganized documentation provides more comprehensive guidance. The sample app has been restructured for clarity, and the all-new sample charts visualize real-world data, making them a more practical reference. Enhancements will continue to be made in these areas.
Thank you for your valuable feedback, which helped shape Vico 2.0.0.
Next steps
- Read the guide.
- Explore the sample app.
- Consult the API reference.
- Ask a question to get migration help.
Vico 1 support
Bug reports for Vico 1 will be accepted until January 31, 2026. Bug fixes will be provided until February 28, 2026.
v2.0.0-beta.7
Overview
- breaking changes: minor
core
- In
CacheStore
, the constructor andpurge
have been hidden. These aren’t intended for consumer access; useMeasuringContext.cacheStore
.
compose
- An issue where the
CacheStore
was recreated onCartesianChartModel
updates—impeding performance, particularly forLineCartesianLayer
—has been resolved.
v2.0.0-beta.6
Overview
- breaking changes: minor
core
LineCartesianLayer.PointConnector.Sharp
, which uses line segments, has been introduced.LineCartesianLayer.PointConnector.cubic
thus no longer permits settingcurvature
to zero.- Some defaults have been updated:
- The default color palette has been refreshed.
- In
ColumnCartesianLayer
, columns now have sharp corners by default. - In
LineCartesianLayer
, lines are now sharp by default. Also,Line.areaFill
is set tonull
. To recreate the previous defaultLineCartesianLayer.AreaFill
, useLineCartesianLayer.AreaFill.single
orLineCartesianLayer.AreaFill.double
andShaderProvider.verticalGradient
.
compose
- The defaults have been updated in accordance with
core
change 2. The color palettes produced byrememberM2MaterialTheme
andrememberM3MaterialTheme
remain unchanged. rememberLayeredComponent
has been removed; use theLayeredComponent
constructor.
views
- An issue where the
verticalAxisVerticalLabelPosition
XML attribute of theAxisStyle
attribute set was misinterpreted has been resolved. - The defaults have been updated in accordance with change 2. In connection with this, the
gradientTopColor
,gradientBottomColor
,positiveGradientTopColor
,positiveGradientBottomColor
,negativeGradientTopColor
, andnegativeGradientBottomColor
XML attributes of theLineStyle
attribute set have been removed. For a gradientLineCartesianLayer.AreaFill
, useAreaFill.single
orAreaFill.double
andShaderProvider.verticalGradient
.