This commit is contained in:
monitor1394
2025-03-16 10:45:38 +08:00
parent a1c7e1a64b
commit e4e1a69e76
8 changed files with 192 additions and 48 deletions

View File

@@ -405,7 +405,7 @@ the delegate function of animation delay.
### AnimationInfo.duration
public float duration
the duration of animation.
the duration of animation. Default is used to calculate the speed of animation. It can also be specified by speed.
### AnimationInfo.durationFunction
@@ -432,6 +432,11 @@ the callback function of animation start.
public bool reverse
whether enable reverse animation.
### AnimationInfo.speed
public float speed
the speed of animation. When speed is specified, duration will be invalid. Default is 0, which means no speed specified.
### AnimationInfo.End
public void End()
@@ -1042,6 +1047,10 @@ public bool needAnimation
public List<string> runtimeData
the tick value of value axis.
### AxisContext.sortedDataIndices
public List<int> sortedDataIndices
## AxisHandler<T>
class in XCharts / Inherits from: [MainComponentHandler](#maincomponenthandler)
@@ -1170,7 +1179,7 @@ public void Copy(AxisLabel axisLabel)
### AxisLabel.GetFormatterContent
public override string GetFormatterContent(int labelIndex, double value, double minValue, double maxValue, bool isLog = false)
public override string GetFormatterContent(int labelIndex, int totalIndex, double value, double minValue, double maxValue, bool isLog = false)
### AxisLabel.IsNeedShowLabel
@@ -1383,6 +1392,10 @@ public int containerIndex
public int containterInstanceId
### Bar.useSortData
public override bool useSortData
### Bar.AddDefaultSerie
public static Serie AddDefaultSerie(BaseChart chart, string serieName)
@@ -1941,6 +1954,10 @@ public T GetOrAddChartComponent<T>() where T : MainComponent
public Painter GetPainter(int index)
### BaseChart.GetRealtimeSortSerie
public Serie GetRealtimeSortSerie(int gridIndex)
### BaseChart.GetSerie
public Serie GetSerie(int serieIndex)
@@ -1953,19 +1970,19 @@ public T GetSerie<T>(int serieIndex) where T : Serie
### BaseChart.GetSerieBarGap<T>
public float GetSerieBarGap<T>() where T : Serie
public float GetSerieBarGap<T>(int gridIndex) where T : Serie
### BaseChart.GetSerieBarRealCount<T>
public int GetSerieBarRealCount<T>() where T : Serie
public int GetSerieBarRealCount<T>(int gridIndex) where T : Serie
### BaseChart.GetSerieIndexIfStack<T>
public int GetSerieIndexIfStack<T>(Serie currSerie) where T : Serie
public int GetSerieIndexIfStack<T>(Serie currSerie, int gridIndex) where T : Serie
### BaseChart.GetSerieSameStackTotalValue<T>
public double GetSerieSameStackTotalValue<T>(string stack, int dataIndex) where T : Serie
public double GetSerieSameStackTotalValue<T>(string stack, int dataIndex, int gridIndex) where T : Serie
### BaseChart.GetSeriesMinMaxValue
@@ -1973,11 +1990,11 @@ public virtual void GetSeriesMinMaxValue(Axis axis, int axisIndex, out double te
### BaseChart.GetSerieTotalGap<T>
public float GetSerieTotalGap<T>(float categoryWidth, float gap, int index) where T : Serie
public float GetSerieTotalGap<T>(float categoryWidth, float gap, int index, int gridIndex) where T : Serie
### BaseChart.GetSerieTotalWidth<T>
public float GetSerieTotalWidth<T>(float categoryWidth, float gap, int realBarCount) where T : Serie
public float GetSerieTotalWidth<T>(float categoryWidth, float gap, int realBarCount, int gridIndex) where T : Serie
### BaseChart.GetTitlePosition
@@ -2007,6 +2024,10 @@ public bool HasChartComponent(Type type)
public bool HasChartComponent<T>()
### BaseChart.HasRealtimeSortSerie
public bool HasRealtimeSortSerie(int gridIndex)
### BaseChart.HasSerie
public bool HasSerie(Type type)
@@ -3082,6 +3103,10 @@ public static List<string> ParseStringFromString(string jsonData)
public static void RemoveComponent<T>(GameObject gameObject)
### ChartHelper.RemoveTMPComponents
public static void RemoveTMPComponents(GameObject gameObject)
### ChartHelper.RotateRound
public static Vector3 RotateRound(Vector3 position, Vector3 center, Vector3 axis, float angle)
@@ -3434,10 +3459,9 @@ class in XCharts.Runtime / Inherits from: [ChildComponent](#childcomponent)
comment of chart.
### CommentItem.content
### CommentItem.labelObject
public string content
content of comment.
public ChartLabel labelObject
### CommentItem.markRect
@@ -3886,9 +3910,13 @@ public static bool NeedFormat(string content)
### FormatterHelper.ReplaceAxisLabelContent
public static void ReplaceAxisLabelContent(ref string content, string value)
public static void ReplaceAxisLabelContent(ref string content, string value, int index, int totalIndex)
### FormatterHelper.ReplaceIndexContent
public static void ReplaceIndexContent(ref string content, int currIndex, int totalIndex)
### FormatterHelper.TrimAndReplaceLine
public static string TrimAndReplaceLine(string content)
@@ -4399,7 +4427,7 @@ public override void ClearData()
### Indicator.GetFormatterIndicatorContent
public string GetFormatterIndicatorContent(string indicatorName)
public string GetFormatterIndicatorContent(string indicatorName, int index, int totalIndex)
### Indicator.GetIndicator
@@ -4650,12 +4678,12 @@ public Color GetColor(Color defaultColor)
### LabelStyle.GetFormatterContent
public virtual string GetFormatterContent(int labelIndex, double value, double minValue, double maxValue, bool isLog = false)
public virtual string GetFormatterContent(int labelIndex, int totalIndex, double value, double minValue, double maxValue, bool isLog = false)
### LabelStyle.GetFormatterDateTime
public string GetFormatterDateTime(int labelIndex, double value, double minValue, double maxValue)
public string GetFormatterDateTime(int labelIndex, int totalIndex, double value, double minValue, double maxValue)
### LabelStyle.GetOffset
@@ -6719,7 +6747,7 @@ public double GetData(int index, int dimension, DataZoom dataZoom = null)
### Serie.GetDataList
public List<SerieData> GetDataList(DataZoom dataZoom = null)
public List<SerieData> GetDataList(DataZoom dataZoom = null, bool sorted = false)
获得系列的数据列表
### Serie.GetDataTotal
@@ -7026,6 +7054,10 @@ public SelectStyle selectStyle
public bool show
[default:true] Whether the data item is showed.
### SerieData.sortIndex
public int sortIndex
### SerieData.state
public SerieState state
@@ -7172,7 +7204,7 @@ public void SetIconActive(bool flag)
### SerieData.SetLabelActive
public void SetLabelActive(bool flag)
public void SetLabelActive(bool flag, bool force = false)
### SerieData.SetPolygon
@@ -7949,7 +7981,7 @@ class in XCharts.Runtime / Inherits from: [SymbolStyle](#symbolstyle),[ISerieDat
### SerieSymbol.GetSize
public float GetSize(List<double> data, float themeSize)
public float GetSize(SerieData serieData, float themeSize)
根据指定的sizeType获得标记的大小
### SerieSymbol.Reset

View File

@@ -6,6 +6,7 @@ slug: /changelog
# Changelog
[master](#master)
[v3.14.0](#v3140)
[v3.13.0](#v3130)
[v3.12.1](#v3121)
[v3.12.0](#v3120)
@@ -78,6 +79,36 @@ slug: /changelog
## master
## v3.14.0
**Key Highlights:**
* Added real-time sorting functionality for `Bar`
* Added support for `\n` line breaks in `itemFormatter` for `Tooltip`
* Added support for `{index}` formatting in `AxisLabel`
* Added `speed` to `Animation` to specify animation speed
* Optimized column alignment in `Tooltip`
**Detailed Changelog:**
* (2025.03.15) Released version `v3.14.0`
* (2025.03.09) Fixed an issue where `Bar` displayed abnormally when placed in different `Grids` within the same `Chart`
* (2025.03.07) Added `speed` to `Animation` to specify animation speed
* (2025.03.06) Optimized the performance of newly added animations in `Animation`
* (2025.03.04) Fixed an issue where `label` in `Treemap` displayed abnormally
* (2025.03.02) Added `columnGapWidths` parameter to `Tooltip` to set the gap distance between column texts
* (2025.03.01) Optimized the refresh of `Comment` component
* (2025.02.23) Added support for `{index}`, `{index-1}`, `{-index}`, and `{-index-1}` wildcards in `formatter` for `Label` in `Axis`
* (2025.02.23) Added `realtimeSort` to `Bar` to support real-time sorting
* (2025.02.19) Added support for `\n` line breaks in `itemFormatter` for `Tooltip`
* (2025.02.18) Optimized the alignment of `Tooltip`
* (2025.02.09) Fixed an issue where `SaveAsImage` did not support transparency when saving images (#337)
* (2025.02.05) Added support for setting `data` styles separately in `GraphChart`
* (2025.02.05) Refactored the `sizeFunction` parameter in `SerieSymbol`
* (2025.01.23) Fixed an issue where `Label` in `Treemap` was not displayed
* (2025.01.15) Fixed an issue where dynamically adding `Component` to `Chart` at runtime caused exceptions (#339)
* (2025.01.08) Fixed an issue where residual components affected `Text` initialization when `TextMeshPro` was turned off
## v3.13.0
Key Features:
@@ -148,7 +179,6 @@ Log Details:
* (2024.09.01) Added `radiusGradient` parameter for `Ring` to set the gradient direction
* (2024.09.01) Optimized the position of the first Label when `Axis` is used as a time axis
## v3.11.2
* (2024.08.01) Release `v3.11.2`

View File

@@ -276,7 +276,7 @@ the delay time before animation start.
`float` `1000` `v3.8.0`
the duration of animation.
the duration of animation. Default is used to calculate the speed of animation. It can also be specified by speed.
### AnimationInfo.enable
@@ -290,6 +290,12 @@ whether enable animation.
whether enable reverse animation.
### AnimationInfo.speed
`float` `0` `v3.14.0`
the speed of animation. When speed is specified, duration will be invalid. Default is 0, which means no speed specified.
## AnimationInteraction
class in XCharts.Runtime / Inherits from: [AnimationInfo](#animationinfo)
@@ -2462,7 +2468,7 @@ the distance of label to axis line.
`string`
label content string template formatter. \n line wrapping is supported. Formatters for some components will not take effect. <br /> Template placeholder have the following, some of which apply only to fixed components: <br /> `\{.\}` : indicates the dot mark. <br /> `\{a\}` : indicates the series name. <br /> `\{b\}` : category value of x axis or data name. <br /> `\{c\}` : data value. <br /> `\{d\}` : percentage. <br /> `\{e\}` : indicates the data name. <br /> `\{f\}` : data sum. <br /> `\{g\}` : indicates the total number of data. <br /> `\{h\}` : hexadecimal color value. <br /> `\{y\}` : category value of y axis. <br /> `\{value\}` : The value of the axis or legend. <br /> The following placeholder apply to `UITable` components: <br /> `\{name\}` : indicates the row name of the table. <br /> `\{index\}` : indicates the row number of the table. <br /> The following placeholder apply to `UIStatistc` components: <br /> `\{title\}` : title text. <br /> `\{dd\}` : day. <br /> `\{hh\}` : hours. <br /> `\{mm\}` : minutes. <br /> `\{ss\}` : second. <br /> `\{fff\}` : milliseconds. <br /> `\{d\}` : day. <br /> `\{h\}` : hours. <br /> `\{m\}` : minutes. <br /> `\{s\}` : second. <br /> `\{f\}` : milliseconds. <br /> Example :\{b\}:\{c\}<br />
label content string template formatter. \n line wrapping is supported. Formatters for some components will not take effect. <br /> Template placeholder have the following, some of which apply only to fixed components: <br /> `\{.\}` : indicates the dot mark. <br /> `\{a\}` : indicates the series name. <br /> `\{b\}` : category value of x axis or data name. <br /> `\{c\}` : data value. <br /> `\{d\}` : percentage. <br /> `\{e\}` : indicates the data name. <br /> `\{f\}` : data sum. <br /> `\{g\}` : indicates the total number of data. <br /> `\{h\}` : hexadecimal color value. <br /> `\{y\}` : category value of y axis. <br /> `\{value\}` : the value of the axis or legend. <br /> `\{index\}` : the index of the axis. <br /> The following placeholder apply to `UITable` components: <br /> `\{name\}` : indicates the row name of the table. <br /> `\{index\}` : indicates the row number of the table. <br /> The following placeholder apply to `UIStatistc` components: <br /> `\{title\}` : title text. <br /> `\{dd\}` : day. <br /> `\{hh\}` : hours. <br /> `\{mm\}` : minutes. <br /> `\{ss\}` : second. <br /> `\{fff\}` : milliseconds. <br /> `\{d\}` : day. <br /> `\{h\}` : hours. <br /> `\{m\}` : minutes. <br /> `\{s\}` : second. <br /> `\{f\}` : milliseconds. <br /> Example :\{b\}:\{c\}<br />
### LabelStyle.height
@@ -3755,6 +3761,12 @@ Options:
the radius of chart.
### Serie.realtimeSort
`bool` `false` `v3.14.0`
Whether to enable realtime sorting, which is used for bar-racing effect. Currently only available in Bar.
### Serie.right
`float`
@@ -4816,11 +4828,17 @@ the color of tooltip border.
the width of tooltip border.
### Tooltip.columnGapWidths
`List<float>` `v3.14.0`
the column gap width of content. When there is only one column, it only represents the gap width of the second column.
### Tooltip.contentLabelStyles
`List<LabelStyle>`
the textstyle list of content.
the column text style list of content. The first represents the text style of the first column, and so on.
### Tooltip.fixedHeight