跳到主要内容
Version: master

LiquidChart 水位图

XCharts的付费扩展图表 - 水位图。

截图

Liquid01Liquid02Liquid03Liquid04Liquid05
Liquid07Liquid08

许可

扩展图表,需付费购买后才获得使用许可。

示例

Demo仓库:XCharts-LiquidChart-Demo

教程

扩展图表如何导入Demo项目或导入自己项目

文档

API
配置项手册

日志

v3.10.0

  • (2024.01.21) 增加Liquid的更多创建默认图表的快捷方式和API

v3.9.0

  • (2023.12.01) 发布v3.9.0版本
  • (2023.12.01) 更新文档

v3.8.0

  • (2023.07.31) 同步XCharts v3.8.0

v3.6.1

  • (2023.06.08) 发布v3.6.1版本
  • (2023.06.08) 更新文档

v3.6.0

  • (2023.04.01) 发布v3.6.0版本
  • (2023.02.14) 同步XCharts v3.6.0

v3.5.0

  • (2022.12.01) 发布v3.5.0版本
  • (2022.11.27) 调整Documentation文档结构

v3.4.0

  • (2022.11.01) 支持AnimationunscaledTime
  • (2022.11.01) 同步XCharts v3.4.0

v3.2.0

  • (2022.08.22) 发布v3.2.0版本
  • (2022.08.19) 同步XCharts v3.2.0

API

Liquid

class in XCharts.Runtime.Liquids / 继承自: Serie,INeedSerieContainer

API版本描述
AddDefaultSerie()public static Serie AddDefaultSerie(BaseChart chart, string serieName)

LiquidChart

class in XCharts.Runtime.Liquids / 继承自: BaseChart

水位图

API版本描述
DefaultCapsuleLiquidChart()public void DefaultCapsuleLiquidChart()
generate default capsule liquid chart. 生成默认的胶囊形水位图。
DefaultRectLiquidChart()public void DefaultRectLiquidChart()
generate default rect liquid chart. 生成默认的矩形水位图。
DefaultRoundRectLiquidChart()public void DefaultRoundRectLiquidChart()
generate default round rect liquid chart. 生成默认的圆角矩形水位图。

Vessel

class in XCharts.Runtime.Liquids / 继承自: MainComponent,ISerieContainer,IUpdateRuntimeData

容器组件。 一般用于LiquidChart。一个Chart中可以有多个Vessel,Serie中用vesselIndex来对应。

API版本描述
IsPointerEnter()public bool IsPointerEnter()
UpdateRuntimeData()public void UpdateRuntimeData(BaseChart chart)

VesselContext

class in XCharts.Runtime.Liquids / 继承自: MainComponentContext

配置项手册

Liquid

class in XCharts.Runtime.Liquids / 继承自: Serie, INeedSerieContainer

参数默认版本描述
waveHeight10f波高。
waveLength20f波长。为0-1小数时指直线的百分比。
waveSpeed5f波速。正数时左移,负数时右移。
waveOffset0f波偏移。

Vessel

class in XCharts.Runtime.Liquids / 继承自: MainComponent, ISerieContainer, IUpdateRuntimeData

容器组件。 一般用于LiquidChart。一个Chart中可以有多个Vessel,Serie中用vesselIndex来对应。

参数默认版本描述
showtrue是否显示容器组件。 [defaut: true]
shape容器形状。 [default: Shape.Circle]
Vessel.Shape:
- Circle: 圆形
- Rect: 正方形。
- Triangle: 三角形。
- Diamond: 菱形。
shapeWidth5f容器厚度。 [defaut: 5f]
gap5f间隙。容器和液体的间隙。 [defaut: 10f]
colorColor32(70, 70, 240, 255)容器颜色。默认和serie一致。
backgroundColor背景色,默认透明。 [default: Color.clear]
autoColortrue是否自动颜色。为true时颜色会和serie一致。 [default: true]
centerWhen value between 0 and 1 represents a percentage relative to the chart.
radius0.35fWhen value between 0 and 1 represents a percentage relative to the chart.
smoothness1f水波平滑度。 [default: 1f]
width0.5fWhen value between 0 and 1 represents a percentage relative to the chart.
height0.7fWhen value between 0 and 1 represents a percentage relative to the chart.
borderWidth0f内壁边框。
borderColorColor32(70, 70, 240, 255)容器内壁边框颜色。默认和serie一致。
cornerRadius容器的圆角半径。用数组分别指定4个圆角半径(顺时针左上,右上,右下,左下)。shape为Rect时有效。