mirror of
https://github.com/XCharts-Team/XCharts.git
synced 2026-05-28 03:58:49 +00:00
3.15.0
This commit is contained in:
@@ -182,6 +182,7 @@ slug: /api
|
||||
- [ParallelCoordContext](#parallelcoordcontext)
|
||||
- [Pie](#pie)
|
||||
- [PieChart](#piechart)
|
||||
- [PieType](#pietype)
|
||||
- [PolarAxisTheme](#polaraxistheme)
|
||||
- [PolarChart](#polarchart)
|
||||
- [PolarCoord](#polarcoord)
|
||||
@@ -1723,6 +1724,11 @@ public Dictionary<Type, FieldInfo> typeListForComponent
|
||||
|
||||
public Dictionary<Type, FieldInfo> typeListForSerie
|
||||
|
||||
### BaseChart.useUtc
|
||||
|
||||
public bool useUtc
|
||||
图表的时间是否都显示为UTC时间。
|
||||
|
||||
### BaseChart.AddChartComponent
|
||||
|
||||
public MainComponent AddChartComponent(Type type)
|
||||
@@ -1979,6 +1985,10 @@ public Color32 GetLegendRealShowNameColor(string name)
|
||||
|
||||
public int GetLegendRealShowNameIndex(string name)
|
||||
|
||||
### BaseChart.GetMainAxis
|
||||
|
||||
public Axis GetMainAxis()
|
||||
|
||||
### BaseChart.GetMarkColor
|
||||
|
||||
public Color32 GetMarkColor(Serie serie, SerieData serieData)
|
||||
@@ -2626,11 +2636,6 @@ public void RefreshAllComponent()
|
||||
public virtual void RefreshGraph()
|
||||
在下一帧刷新图形。
|
||||
|
||||
### BaseGraph.SaveAsImage
|
||||
|
||||
public void SaveAsImage(string imageType = "png", string savePath = "")
|
||||
保存图表为图片。
|
||||
|
||||
### BaseGraph.ScreenPointToChartPoint
|
||||
|
||||
public bool ScreenPointToChartPoint(Vector2 screenPoint, out Vector2 chartPoint)
|
||||
@@ -2918,11 +2923,11 @@ public static string IntToStr(int value, string numericFormatter = "")
|
||||
|
||||
### ChartCached.NumberToDateStr
|
||||
|
||||
public static string NumberToDateStr(double timestamp, string formatter)
|
||||
public static string NumberToDateStr(double timestamp, string formatter, bool local = false)
|
||||
|
||||
### ChartCached.NumberToDateTime
|
||||
|
||||
public static DateTime NumberToDateTime(double timestamp)
|
||||
public static DateTime NumberToDateTime(double timestamp, bool local = false)
|
||||
|
||||
### ChartCached.NumberToStr
|
||||
|
||||
@@ -3168,10 +3173,6 @@ public static void RemoveTMPComponents(GameObject gameObject)
|
||||
|
||||
public static Vector3 RotateRound(Vector3 position, Vector3 center, Vector3 axis, float angle)
|
||||
|
||||
### ChartHelper.SaveAsImage
|
||||
|
||||
public static Texture2D SaveAsImage(RectTransform rectTransform, Canvas canvas, string imageType = "png", string path = "")
|
||||
|
||||
### ChartHelper.SetActive
|
||||
|
||||
public static bool SetActive(Image image, bool active)
|
||||
@@ -3844,11 +3845,11 @@ class in XCharts.Runtime
|
||||
|
||||
### DateTimeUtil.GetDateTime
|
||||
|
||||
public static DateTime GetDateTime(double timestamp, bool local = true)
|
||||
public static DateTime GetDateTime(double timestamp, bool local = false)
|
||||
|
||||
### DateTimeUtil.GetDefaultDateTimeString
|
||||
|
||||
public static string GetDefaultDateTimeString(double timestamp, double range = 0)
|
||||
public static string GetDefaultDateTimeString(double timestamp, double range = 0, bool local = false)
|
||||
|
||||
### DateTimeUtil.GetTimestamp
|
||||
|
||||
@@ -4764,7 +4765,7 @@ public virtual string GetFormatterContent(int labelIndex, int totalIndex, double
|
||||
|
||||
### LabelStyle.GetFormatterDateTime
|
||||
|
||||
public string GetFormatterDateTime(int labelIndex, int totalIndex, double value, double minValue, double maxValue)
|
||||
public string GetFormatterDateTime(int labelIndex, int totalIndex, double value, double minValue, double maxValue, bool local)
|
||||
|
||||
### LabelStyle.GetOffset
|
||||
|
||||
@@ -6067,10 +6068,6 @@ class in XCharts.Runtime / 继承自: [MaskableGraphic](https://docs.unity3d.com
|
||||
|
||||
public int index
|
||||
|
||||
### Painter.onPopulateMesh
|
||||
|
||||
public Action<VertexHelper, Painter> onPopulateMesh
|
||||
|
||||
### Painter.type
|
||||
|
||||
public Type type
|
||||
@@ -6205,6 +6202,15 @@ public void DefaultLabelPieChart()
|
||||
public void DefaultRadiusRosePieChart()
|
||||
默认玫瑰饼图。
|
||||
|
||||
## PieType
|
||||
|
||||
class in XCharts.Runtime
|
||||
|
||||
可选:
|
||||
|
||||
- `Solid`: 实心饼图 - 默认填充样式
|
||||
- `Wireframe`: 线框饼图 - 仅显示轮廓线框
|
||||
|
||||
## PolarAxisTheme
|
||||
|
||||
class in XCharts.Runtime / 继承自: [BaseAxisTheme](#baseaxistheme)
|
||||
@@ -7226,12 +7232,12 @@ public double GetLastData()
|
||||
|
||||
### SerieData.GetMaxData
|
||||
|
||||
public double GetMaxData(bool inverse = false)
|
||||
public double GetMaxData(bool inverse = false, int startDimensionIndex = 0)
|
||||
最大值。
|
||||
|
||||
### SerieData.GetMinData
|
||||
|
||||
public double GetMinData(bool inverse = false)
|
||||
public double GetMinData(bool inverse = false, int startDimensionIndex = 0)
|
||||
最小值。
|
||||
|
||||
### SerieData.GetMinMaxData
|
||||
|
||||
@@ -6,6 +6,7 @@ slug: /changelog
|
||||
# 更新日志
|
||||
|
||||
[master](#master)
|
||||
[v3.15.0](#v3150)
|
||||
[v3.14.0](#v3140)
|
||||
[v3.13.0](#v3130)
|
||||
[v3.12.1](#v3121)
|
||||
@@ -80,6 +81,19 @@ slug: /changelog
|
||||
|
||||
## master
|
||||
|
||||
## v3.15.0
|
||||
|
||||
版本要点:
|
||||
|
||||
* __时间轴与缩放能力增强__:新增 `DataZoom.minZoomRatio`(替代 `minShowNum`)、`Chart.useUtc`,并持续优化 `Axis Time` 在缩放与大年份场景下的表现。
|
||||
* __柱图与坐标轴配置更灵活__:新增 `Axis.mainAxis` 控制柱图朝向、`Serie.ignoreZeroOccupy` 控制 0 值柱是否占位、`AxisLine` 延长线配置等。
|
||||
* __图表样式与交互能力提升__:新增 `Pie.pieType`、`Legend.itemInactiveOpacity`、`Axis.onLabelClick`、`Animation.Exchange`、`LabelStyle.fixedX/fixedY` 等。
|
||||
* __扩展 UI 组件持续完善__:`UITable` 新增 `Title` 与 `Viewport` 配置,`UIStatistic.desc` 增强,`Comment.layer` 与坐标刷新体验优化。
|
||||
* __稳定性与兼容性修复集中推进__:修复 `SaveAsImage` 遮挡保存、`Pie` 点击失效、`TMP` 兼容、`Gantt` 时间区间与 2038 年问题、`MarkArea/GridCoord/Axis` 等多项关键问题。
|
||||
|
||||
日志详情:
|
||||
|
||||
* (2026.03.01) 发布`v3.15.0`版本
|
||||
* (2026.02.26) 增加`Serie`的`ignoreZeroOccupy`可设置0数据的Bar是否占位 (#286)
|
||||
* (2026.02.26) 修复`SaveAsImage`被其他组件遮挡时无法正常保存的问题 (#337)
|
||||
* (2026.02.26) 增加`Axis`的`mainAxis`参数设置主轴可控制柱图的朝向 (#331)
|
||||
|
||||
@@ -618,6 +618,12 @@ class in XCharts.Runtime / 继承自: [MainComponent](#maincomponent) / 子类:
|
||||
|
||||
对数轴是否以自然数 e 为底数,为 true 时 logBase 失效。
|
||||
|
||||
### Axis.mainAxis
|
||||
|
||||
`bool` `false` `v3.15.0`
|
||||
|
||||
是否为主轴。当XY轴类型都相同时,设置为主轴的轴会决定朝向,如横向柱图和纵向柱图。
|
||||
|
||||
### Axis.max
|
||||
|
||||
`double`
|
||||
@@ -828,6 +834,12 @@ class in XCharts.Runtime / 继承自: [BaseLine](#baseline)
|
||||
|
||||
轴线箭头。
|
||||
|
||||
### AxisLine.endExtendLength
|
||||
|
||||
`float`
|
||||
|
||||
轴线终点延长线长度。
|
||||
|
||||
### AxisLine.onZero
|
||||
|
||||
`bool`
|
||||
@@ -840,6 +852,12 @@ X 轴或者 Y 轴的轴线是否在另一个轴的 0 刻度上,只有在另一
|
||||
|
||||
是否显示箭头。
|
||||
|
||||
### AxisLine.startExtendLength
|
||||
|
||||
`float`
|
||||
|
||||
轴线起点延长线长度。
|
||||
|
||||
## AxisMinorSplitLine
|
||||
|
||||
class in XCharts.Runtime / 继承自: [BaseLine](#baseline)
|
||||
@@ -1504,11 +1522,11 @@ DataZoom 组件 用于区域缩放,从而能自由关注细节的数据信息
|
||||
|
||||
选取框样式。
|
||||
|
||||
### DataZoom.minShowNum
|
||||
### DataZoom.minZoomRatio
|
||||
|
||||
`int` `2`
|
||||
`float` `0.2f`
|
||||
|
||||
最小显示数据个数。当DataZoom放大到最大时,最小显示的数据个数。
|
||||
缩放区域组件的最小缩放比例,范围0f-1f。
|
||||
|
||||
### DataZoom.orient
|
||||
|
||||
@@ -3361,6 +3379,17 @@ grid 组件离容器上侧的距离。
|
||||
|
||||
class in XCharts.Runtime / 继承自: [Serie](#serie)
|
||||
|
||||
### Pie.pieType
|
||||
|
||||
[PieType](#pietype) `v3.15.0`
|
||||
|
||||
饼图类型。
|
||||
|
||||
可选:
|
||||
|
||||
- `Solid`: 实心饼图 - 默认填充样式
|
||||
- `Wireframe`: 线框饼图 - 仅显示轮廓线框
|
||||
|
||||
### Pie.radiusGradient
|
||||
|
||||
`bool` `false` `v3.8.1`
|
||||
@@ -3639,6 +3668,12 @@ class in XCharts.Runtime / 继承自: [BaseSerie](#baseserie), [IComparable](htt
|
||||
|
||||
忽略数据的默认值。当ignore为true才有效。
|
||||
|
||||
### Serie.ignoreZeroOccupy
|
||||
|
||||
`bool` `false` `v3.15.0`
|
||||
|
||||
柱图是否忽略值为0的柱子占位。开启后,值为0的柱子将不会占用空间,柱子之间的间距会根据实际显示的柱子自动调整。一般用在柱状图中。
|
||||
|
||||
### Serie.index
|
||||
|
||||
`int`
|
||||
|
||||
Reference in New Issue
Block a user