You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[`FWorksheet.newChart()`](https://docs.univer.ai/reference/facade/worksheet#newchart) method is used to create a chart builder, returning an instance of `FChartBuilderBase`. You can chain method calls to set various properties of the chart.
165
+
`FWorksheet.newChart()` method is used to create a chart builder, returning an instance of `FChartBuilderBase`. You can chain method calls to set various properties of the chart.
166
166
167
-
Then call `build()` to generate an `IChartBuilderInfo` object, and use the [`FWorksheet.insertChart(chartBuildInfo: IChartBuilderInfo)`](https://docs.univer.ai/reference/facade/worksheet#insertchart) method to insert the chart into the worksheet.
167
+
Then call `build()` to generate an `IChartBuilderInfo` object, and use the `FWorksheet.insertChart(chartBuildInfo: IChartBuilderInfo)` method to insert the chart into the worksheet.
[`FWorksheet.getCharts()`](https://docs.univer.ai/reference/facade/worksheet#getcharts) method is used to get all charts in the current worksheet, returning an array of `FChart` objects.
471
+
`FWorksheet.getCharts()` method is used to get all charts in the current worksheet, returning an array of `FChart` objects.
Here are some member methods on [`FChart`](https://docs.univer.ai/reference/facade/chart):
481
+
Here are some member methods on `FChart`:
482
482
483
483
| Method | Description |
484
484
| --- | --- |
@@ -489,7 +489,7 @@ Here are some member methods on [`FChart`](https://docs.univer.ai/reference/faca
489
489
490
490
### Update Chart
491
491
492
-
The [`FWorksheet.updateChart(chartBuildInfo: IChartBuilderInfo)`](https://docs.univer.ai/reference/facade/worksheet#updatechart) method is used to update the chart, passing in an `IChartBuilderInfo` object to update the chart configuration.
492
+
The `FWorksheet.updateChart(chartBuildInfo: IChartBuilderInfo)` method is used to update the chart, passing in an `IChartBuilderInfo` object to update the chart configuration.
493
493
494
494
```typescript
495
495
const fWorkbook =univerAPI.getActiveWorkbook()
@@ -519,7 +519,7 @@ setTimeout(() => {
519
519
520
520
### Remove Chart
521
521
522
-
The [`FWorksheet.removeChart(chart: FChart)`](https://docs.univer.ai/reference/facade/worksheet#removechart) method is used to remove a chart, passing in an `FChart` object to remove the specified chart.
522
+
The `FWorksheet.removeChart(chart: FChart)` method is used to remove a chart, passing in an `FChart` object to remove the specified chart.
523
523
524
524
```typescript
525
525
const fWorkbook =univerAPI.getActiveWorkbook()
@@ -546,7 +546,7 @@ setTimeout(async () => {
546
546
547
547
### Chart Theme
548
548
549
-
The [`FWorksheet.registerChartTheme(themeName: string, theme: IEchartTheme)`](https://docs.univer.ai/reference/facade/worksheet#registercharttheme) method is used to register a chart theme, passing in a theme name and theme object to register a custom theme.
549
+
The `FWorksheet.registerChartTheme(themeName: string, theme: IEchartTheme)` method is used to register a chart theme, passing in a theme name and theme object to register a custom theme.
550
550
551
551
Univer chart is implemented based on the echarts library, so you can use the echart theme [builder tool to create your custom theme](https://echarts.apache.org/en/theme-builder.html).
552
552
You can create your own theme on this website and download it as a configuration file. Use the following API to use your custom theme:
0 commit comments