v2.0.0-beta.5
Pre-release
Pre-release
·
114 commits
to master
since this release
Overview
- breaking changes: moderate
- addressed: #933
core
- Concurrency-related fixes have been made to
CartesianChartModelProducer
, resolving an issue where running twoTransaction
s in very short succession could cause a lock-up. Also,createTransaction
, theTransaction
constructor, andTransaction.commit
have been hidden or removed—userunTransaction
. Dimensions
has been renamed toInsets
. TheEmpty
singleton is now calledZero
.- In
AutoScrollCondition
,shouldPerformAutoScroll
is nowshouldScroll
, the function parameters have been flipped, andOnModelSizeIncreased
is nowOnModelGrowth
. - In
FadingEdges
,startEdgeWidthDp
is nowstartWidthDp
,endEdgeWidthDp
isendWidthDp
, andedgeWidthDp
iswidthDp
. Zoom.static
has been renamed toZoom.fixed
.- In
Shadow
,dxDp
anddyDp
are nowxDp
andyDp
. - In
CandlestickCartesianLayerModel
,Entry.Change
is nowChange
. - In
CandlestickCartesianLayer
, the name ofcandles
has been corrected tocandleProvider
. - In
BaseAxis.Size.Auto
,minSizeDp
andmaxSizeDp
are nowminDp
andmaxDp
.BaseAxis.Size.Exact
has been renamed toBaseAxis.Size.Fixed
, and itssizeDp
constructor parameter is now calledvalueDp
. - In
LayeredComponent
,rear
is nowback
. HorizontalPosition
andVerticalPosition
are nowPosition.Horizontal
andPosition.Vertical
.CartesianMarkerValueFormatter
is nowDefaultCartesianMarker.ValueFormatter
.DefaultCartesianMarker.ValueFormatter.default
replacesDefaultCartesianMarkerValueFormatter
. If subclassingDefaultCartesianMarkerValueFormatter
, switch to a delegation-based solution, or make the custom implementation standalone.DynamicShader
is nowShaderProvider
. InShaderProvider.component
,tileXMode
andtileYMode
are nowxTileMode
andyTileMode
.Shader.toDynamicShader
is nowShader.toShaderProvider
. TheRectF
-basedgetShader
overload has been removed in favor of the four-parameter one. InFill
,shader
is nowshaderProvider
.- In
VerticalAxis
,verticalLabelPosition
is now of typePosition.Vertical
. The same applies to theverticalLabelPosition
parameters ofstart
andend
.VerticalAxis.VerticalLabelPosition
has been removed. - In
ColumnCartesianLayer
andLineCartesianLayer.Line
,dataLabelVerticalPosition
is nowdataLabelPosition
. - The
CorneredShape
API has been consolidated:Corner
is nowCorneredShape.Corner
. InRelative
,percentage
is nowsizePercent
. In both subclasses,cornerTreatment
is nowtreatment
.FullyRounded
is nowRounded
.CornerLocation
is nowCorneredShape.CornerPosition
.CornerTreatment
is nowCorneredShape.CornerTreatment
. IncreateCorner
, the parameters have been reordered, andcornerLocation
is nowposition
.SharpCornerTreatment
,RoundedCornerTreatment
, andCutCornerTreatment
have been hidden or removed in favor ofCorneredShape.CornerTreatment.Sharp
,CorneredShape.CornerTreatment.Rounded
, andCorneredShape.CornerTreatment.Cut
.
- In the
CorneredShape
-basedMarkerCorneredShape
constructor,corneredShape
has been renamed tobase
. - A public
Point
constructor has been introduced, replacing thepoint
factory functions. HorizontalDimensions
is nowCartesianLayerDimensions
, andMutableHorizontalDimensions
isMutableCartesianLayerDimensions
. InAxis
,updateHorizontalDimensions
is now calledupdateLayerDimensions
, and thehorizontalDimensions
parameter has been renamed tolayerDimensions
. InCartesianLayer
,updateHorizontalDimensions
has been renamed toupdateDimensions
, and thehorizontalDimensions
parameter has been renamed todimensions
. Beyond this, thehorizontalDimensions
properties and parameters have been renamed tolayerDimensions
.Insets
-related changes have been made:Insets
is nowCartesianLayerMargins
, andHorizontalInsets
isHorizontalCartesianLayerMargins
.CartesianLayerInsetter
is now calledCartesianLayerMarginUpdater
. TheupdateInsets
function is nowupdateLayerMargins
, and itsinsets
parameter is nowlayerMargins
. TheupdateHorizontalInsets
function is nowupdateHorizontalLayerMargins
, and itsinsets
parameter is nowhorizontalLayerMargins
. In both functions,horizontalDimensions
is nowlayerDimensions
, and the parameters have been reordered.- In
HorizontalAxis.ItemPlacer
,getStartHorizontalAxisInset
is nowgetStartLayerMargin
, andgetEndHorizontalAxisInset
isgetEndLayerMargin
. InVerticalAxis.ItemPlacer
,getTopVerticalAxisInset
is nowgetTopLayerMargin
, andgetBottomVerticalAxisInset
isgetBottomLayerMargin
.
- In the
LegendItem
functions, the parameters have been reordered, andiconPaddingDp
is nowiconLabelSpacingDp
. - In
Bounded
, theRectF
-basedsetBounds
overload has been removed in favor of the four-parameter one. - In
DrawingContext
,withOtherCanvas
is nowwithCanvas
. - In
MeasuringContext
,layoutDirectionMultiplier
is now of typeInt
. - In
CartesianLayer
,updateRanges
is nowupdateChartRanges
, and theranges
parameter has been renamed tochartRanges
. - In the
drawHorizontal
function ofLineComponent
,centerY
is nowy
. IndrawVertical
,centerX
isx
, and the parameters have been reordered. In both functions,thicknessScale
is nowthicknessFactor
. - The properties of
CartesianLayerPadding
are now public. - Some nonessential API elements have been hidden or removed.
compose
- In conneciton with
core
change 2, thedimensions
factory function is nowinsets
, and allDimensions
parameters are now of typeInsets
. - In connection with
core
change 4, thestartEdgeWidth
,endEdgeWidth
, andwidth
parameters of therememberFadingEdges
overloads are nowstartWidth
,endWidth
, andwidth
. - In connection with
core
change 6, thedx
anddy
parameters ofshadow
have been renamed tox
andy
. - In connection with
core
change 8, thecandles
parameter ofrememberCandlestickCartesianLayer
has been renamed tocandleProvider
. - In connection with
core
change 9, theminSize
andmaxSize
parameters ofBaseAxis.Size.auto
are now calledmin
andmax
,BaseAxis.Size.exact
has been renamed toBaseAxis.Size.fixed
, and itssize
parameter is now calledvalue
. - In connection with
core
change 10, therear
parameter ofrememberLayeredComponent
has been renamed toback
. - In connection with
core
change 14, inVerticalAxis.rememberStart
andVerticalAxis.rememberEnd
,verticalLabelPosition
is now of typePosition.Vertical
. - In connection with
core
change 15, inrememberColumnCartesianLayer
andLineCartesianLayer.rememberLine
,dataLabelVerticalPosition
is nowdataLabelPosition
. - In connection with
core
change 17, in theCorneredShape
-basedmarkerCorneredShape
overload,corneredShape
has been renamed tobase
. - In
markerCorneredShape
, the name oftickSizeDp
has been corrected totickSize
. rememberExtraLambda
has been removed, as with Jetpack Compose’s strong skipping mode, it’s no longer needed. Use normal lambdas instead.- In
CartesianChartHost
,runInitialAnimation
is nowanimateIn
.
views
- In connection with
core
change 15, thedataLabelVerticalPosition
XML attributes have been renamed todataLabelPosition
. - In
ScrollHandler
, theanimateScroll
parameters have been reordered, theoldValue
andnewValue
parameters ofListener.onValueChanged
have been renamed toold
andnew
, and theoldMaxValue
andnewMaxValue
parameters ofListener.onMaxValueChanged
have been renamed toold
andnew
. - In
ChartView
,runInitialAnimation
is nowanimateIn
. - In
ZoomHandler.Listener
, theoldValue
andnewValue
parameters ofonValueChanged
have been renamed toold
andnew
, and theoldValueRange
andnewValueRange
parameters ofonValueRangeChanged
have been renamed toold
andnew
.