Skip to content

Commit

Permalink
[doc] update api and configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
monitor1394 committed Apr 7, 2022
1 parent 5476fa8 commit 20825c1
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 10 deletions.
5 changes: 4 additions & 1 deletion Documentation/XChartsAPI-EN.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ Inherits or Implemented: [BaseGraph](#BaseGraph),[ISerializationCallbackReceiver
| `CovertXYAxis` |public void CovertXYAxis(int index)</br>转换X轴和Y轴的配置 |
| `GenerateDefaultSerieName` |public string GenerateDefaultSerieName()</br> |
| `GetAllSerieDataCount` |public int GetAllSerieDataCount()</br> |
| `GetChartBackgroundColor` |public Color32 GetChartBackgroundColor()</br> |
| `GetChartComponentNum` |public int GetChartComponentNum(Type type)</br> |
| `GetData` |public double GetData(int serieIndex, int dataIndex, int dimension = 1)</br> |
| `GetData` |public double GetData(string serieName, int dataIndex, int dimension = 1)</br> |
Expand Down Expand Up @@ -797,7 +798,7 @@ Inherits or Implemented: [Attribute](#Attribute)
| `AvoidLabelOverlap` |public static void AvoidLabelOverlap(Serie serie, ComponentTheme theme)</br> |
| `CanShowLabel` |public static bool CanShowLabel(Serie serie, SerieData serieData, LabelStyle label, int dimesion)</br> |
| `GetLabelColor` |public static Color GetLabelColor(Serie serie, ThemeStyle theme, int index)</br> |
| `GetRealLabelPosition` |public static Vector3 GetRealLabelPosition(SerieData serieData, LabelStyle label, LabelLine labelLine)</br> |
| `GetRealLabelPosition` |public static Vector3 GetRealLabelPosition(Serie serie, SerieData serieData, LabelStyle label, LabelLine labelLine)</br> |
| `SetGaugeLabelText` |public static void SetGaugeLabelText(Serie serie)</br> |
| `UpdatePieLabelPosition` |public static void UpdatePieLabelPosition(Serie serie, SerieData serieData)</br> |

Expand Down Expand Up @@ -965,7 +966,9 @@ Inherits or Implemented: [MainComponentContext](#MainComponentContext)
| `GetChart` |public static BaseChart GetChart(string chartName)</br> |
| `GetCharts` |public static List<BaseChart> GetCharts(string chartName)</br> |
| `GetPackageFullPath` |public static string GetPackageFullPath()</br> |
| `GetRepeatChartNameInfo` |public static string GetRepeatChartNameInfo(BaseChart chart, string chartName)</br> |
| `IsExistTMPAssembly` |public static bool IsExistTMPAssembly()</br> |
| `IsRepeatChartName` |public static bool IsRepeatChartName(BaseChart chart, string chartName = null)</br> |
| `ModifyTMPRefence` |public static bool ModifyTMPRefence(bool removeTMP = false)</br> |
| `RemoveAllChartObject` |public static void RemoveAllChartObject()</br> |
| `RemoveChart` |public static void RemoveChart(string chartName)</br> |
Expand Down
5 changes: 4 additions & 1 deletion Documentation/XChartsAPI-ZH.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ Inherits or Implemented: [BaseGraph](#BaseGraph),[ISerializationCallbackReceiver
| `CovertXYAxis` |public void CovertXYAxis(int index)</br>转换X轴和Y轴的配置 |
| `GenerateDefaultSerieName` |public string GenerateDefaultSerieName()</br> |
| `GetAllSerieDataCount` |public int GetAllSerieDataCount()</br> |
| `GetChartBackgroundColor` |public Color32 GetChartBackgroundColor()</br> |
| `GetChartComponentNum` |public int GetChartComponentNum(Type type)</br> |
| `GetData` |public double GetData(int serieIndex, int dataIndex, int dimension = 1)</br> |
| `GetData` |public double GetData(string serieName, int dataIndex, int dimension = 1)</br> |
Expand Down Expand Up @@ -797,7 +798,7 @@ Inherits or Implemented: [Attribute](#Attribute)
| `AvoidLabelOverlap` |public static void AvoidLabelOverlap(Serie serie, ComponentTheme theme)</br> |
| `CanShowLabel` |public static bool CanShowLabel(Serie serie, SerieData serieData, LabelStyle label, int dimesion)</br> |
| `GetLabelColor` |public static Color GetLabelColor(Serie serie, ThemeStyle theme, int index)</br> |
| `GetRealLabelPosition` |public static Vector3 GetRealLabelPosition(SerieData serieData, LabelStyle label, LabelLine labelLine)</br> |
| `GetRealLabelPosition` |public static Vector3 GetRealLabelPosition(Serie serie, SerieData serieData, LabelStyle label, LabelLine labelLine)</br> |
| `SetGaugeLabelText` |public static void SetGaugeLabelText(Serie serie)</br> |
| `UpdatePieLabelPosition` |public static void UpdatePieLabelPosition(Serie serie, SerieData serieData)</br> |

Expand Down Expand Up @@ -965,7 +966,9 @@ Inherits or Implemented: [MainComponentContext](#MainComponentContext)
| `GetChart` |public static BaseChart GetChart(string chartName)</br> |
| `GetCharts` |public static List<BaseChart> GetCharts(string chartName)</br> |
| `GetPackageFullPath` |public static string GetPackageFullPath()</br> |
| `GetRepeatChartNameInfo` |public static string GetRepeatChartNameInfo(BaseChart chart, string chartName)</br> |
| `IsExistTMPAssembly` |public static bool IsExistTMPAssembly()</br> |
| `IsRepeatChartName` |public static bool IsRepeatChartName(BaseChart chart, string chartName = null)</br> |
| `ModifyTMPRefence` |public static bool ModifyTMPRefence(bool removeTMP = false)</br> |
| `RemoveAllChartObject` |public static void RemoveAllChartObject()</br> |
| `RemoveChart` |public static void RemoveChart(string chartName)</br> |
Expand Down
11 changes: 6 additions & 5 deletions Documentation/XChartsConfiguration-EN.md
Original file line number Diff line number Diff line change
Expand Up @@ -653,7 +653,6 @@ Text label of chart, to explain some data information about graphic item like va
| `backgroundHeight` |0 | the height of background. If set as default value 0, it means than the background height auto set as the text height. |
| `numericFormatter` | | Standard numeric format strings. |
| `autoOffset` |false | 是否开启自动偏移。当开启时,Y的偏移会自动判断曲线的开口来决定向上还是向下偏移。 |
| `autoColor` |false | 是否开启自动颜色。当开启时,会根据已支持的serie自动设置颜色。 |
| `textStyle` | | the sytle of text. [TextStyle](TextStyle)|

## `Lang`
Expand Down Expand Up @@ -865,9 +864,9 @@ Polar coordinate can be used in scatter and line chart. Every polar coordinate h
|field|default|comment|
|--|--|--|
| `show` |true | Whether to show the polor component. |
| `center` | | [default:[0.5f,0.45f]]The center of ploar. The center[0] is the x-coordinate, and the center[1] is the y-coordinate. |
| `radius` |0.35f | [default:0.35f]the radius of polar. |
| `backgroundColor` | | [default:Color.clear]Background color of polar, which is transparent by default. |
| `center` | | The center of ploar. The center[0] is the x-coordinate, and the center[1] is the y-coordinate. When value between 0 and 1 represents a percentage relative to the chart. |
| `radius` |0.35f | the radius of polar. |
| `backgroundColor` | | Background color of polar, which is transparent by default. |

## `Radar`

Expand Down Expand Up @@ -1160,6 +1159,7 @@ Settings related to text.
| `rotate` |0 | Rotation of text. |
| `extraWidth` |0 | Extra width of text preferred width. |
| `offset` |Vector2.zero | the offset of position. |
| `autoColor` |false | 是否开启自动颜色。当开启时,会自动设置颜色。 |
| `color` | | the color of text. |
| `autoBackgroundColor` |false | |
| `backgroundColor` | | the color of text. |
Expand Down Expand Up @@ -1206,7 +1206,8 @@ Theme.
|--|--|--|
| `show` |true | |
| `sharedTheme` | | [Theme](Theme)|
| `enableCustomTheme` | | |
| `transparentBackground` |false | Whether the background color is transparent. When true, the background color is not drawn. |是否透明背景颜色。当设置为true时,不绘制背景颜色。 |
| `enableCustomTheme` |false | Whether to customize theme colors. When set to true, you can use 'sync color to custom' to synchronize the theme color to the custom color. It can also be set manually. |
| `customFont` | | |
| `customBackgroundColor` | | the custom background color of chart. |
| `customColorPalette` | | |
Expand Down
7 changes: 4 additions & 3 deletions Documentation/XChartsConfiguration-ZH.md
Original file line number Diff line number Diff line change
Expand Up @@ -653,7 +653,6 @@ Inherits or Implemented: [ChildComponent](#ChildComponent),[ISerieExtraComponent
| `backgroundHeight` |0 | 标签的背景高度。一般不用指定,不指定时则自动是文字的高度。 |
| `numericFormatter` | | 标准数字格式字符串。用于将数值格式化显示为字符串。 使用Axx的形式:A是格式说明符的单字符,支持C货币、D十进制、E指数、F定点数、G常规、N数字、P百分比、R往返、X十六进制的。xx是精度说明,从0-99。 参考:https://docs.microsoft.com/zh-cn/dotnet/standard/base-types/standard-numeric-format-strings |
| `autoOffset` |false | 是否开启自动偏移。当开启时,Y的偏移会自动判断曲线的开口来决定向上还是向下偏移。 |
| `autoColor` |false | 是否开启自动颜色。当开启时,会根据已支持的serie自动设置颜色。 |
| `textStyle` | | 文本样式。 [TextStyle](TextStyle)|

## `Lang`
Expand Down Expand Up @@ -865,7 +864,7 @@ Inherits or Implemented: [CoordSystem](#CoordSystem),[ISerieContainer](#ISerieCo
|field|default|comment|
|--|--|--|
| `show` |true | 是否显示极坐标。 |
| `center` | | When value between 0 and 1 represents a percentage relative to the chart. |
| `center` | | 极坐标的中心点。数组的第一项是横坐标,第二项是纵坐标。 当值为0-1之间时表示百分比,设置成百分比时第一项是相对于容器宽度,第二项是相对于容器高度。 |
| `radius` |0.35f | 极坐标的半径。 |
| `backgroundColor` | | 极坐标的背景色,默认透明。 |

Expand Down Expand Up @@ -1160,6 +1159,7 @@ Inherits or Implemented: [ChildComponent](#ChildComponent)
| `rotate` |0 | 文本的旋转。 [default: `0f`] |
| `extraWidth` |0 | 额外的宽度 |
| `offset` |Vector2.zero | 坐标偏移。 [Default: `Vector2.zero`] |
| `autoColor` |false | 是否开启自动颜色。当开启时,会自动设置颜色。 |
| `color` | | 文本的颜色。 [default: `Color.clear`] |
| `autoBackgroundColor` |false | |
| `backgroundColor` | | 文本的背景颜色。 [default: `Color.clear`] |
Expand Down Expand Up @@ -1206,7 +1206,8 @@ Inherits or Implemented: [ChildComponent](#ChildComponent)
|--|--|--|
| `show` |true | |
| `sharedTheme` | | [Theme](Theme)|
| `enableCustomTheme` | | |
| `transparentBackground` |false | Whether the background color is transparent. When true, the background color is not drawn. |是否透明背景颜色。当设置为true时,不绘制背景颜色。 |
| `enableCustomTheme` |false | 是否自定义主题颜色。当设置为true时,可以用‘sync color to custom’同步主题的颜色到自定义颜色。也可以手动设置。 |
| `customFont` | | |
| `customBackgroundColor` | | 自定义的背景颜色。 |
| `customColorPalette` | | |
Expand Down

0 comments on commit 20825c1

Please sign in to comment.