Commit graph

17 commits

Author SHA1 Message Date
Floyd Wang
51caf932db
plot(tooltip): Add support for custom appearance (#1226) 2025-09-09 14:47:07 +08:00
Floyd Wang
84b2d2a6f5
plot(scale): Add least index support for linear (#1225) 2025-09-09 11:40:09 +08:00
Floyd Wang
78dccd4d79
plot: Apply linear scale based on the direction of given range (#1219)
## Breaking Change
- Apply linear scale based on the direction of given range.

```diff
- ScaleLinear::new(vec![1., 2., 3.], vec![0., 100.])
+ ScaleLinear::new(vec![1., 2., 3.], vec![100., 0.])
```

Currently, you can draw the linear scale from minimum to maximum or from
maximum to minimum; it depends on the direction of the range.
2025-09-08 15:56:58 +08:00
Floyd Wang
7fb6000189
plot(scale): Correct the least index (#1186) 2025-08-29 16:42:59 +08:00
Floyd Wang
1267857a8c
plot(scale): Point scale support single point (#1185)
<img width="447" height="446" alt="image"
src="https://github.com/user-attachments/assets/fff44252-ff5b-4d73-8b98-0eb4c0877563"
/>
2025-08-29 15:05:51 +08:00
Floyd Wang
9b3900b6cf
plot: Fix the full circle cannot be drawn (#1161) 2025-08-20 16:01:15 +08:00
Floyd Wang
566f5b0d4d fixup! plot: Fix the point scale cannot selecting the last point (#1143) 2025-08-15 17:23:42 +08:00
Floyd Wang
4c545165eb
plot: Fix the point scale cannot selecting the last point (#1143) 2025-08-15 17:09:41 +08:00
Floyd Wang
d559b56fb0
plot: Improve the band scale least_index (#1141) 2025-08-15 11:23:11 +08:00
Floyd Wang
e37369ea16
plot: Support multiple directions for the tooltip cross line (#1128) 2025-08-12 14:16:31 +08:00
Floyd Wang
3b759cd448
plot: Use f32 instead of f64 (#1052)
## Break Change
- Convert all `f64` parameters to `f32`.

Since the GPUI geometry module uses f32 for rendering, we are also
switching to f32. This helps avoid many as operators and unnecessary
conversions.
2025-07-08 16:24:59 +08:00
Floyd Wang
32d0beff22
plot: Tooltip support multiple dots (#1030) 2025-07-03 11:28:48 +08:00
Jason Lee
a3a4f1942d
chart: Update Chart story by use JSON file data. (#947) 2025-06-11 21:34:22 +08:00
Floyd Wang
44ec74f1fb
chart: Draw dashed lines using gpui PathBuilder (#927)
https://github.com/zed-industries/zed/pull/31678
2025-06-09 11:55:32 +08:00
Floyd Wang
9afe0063a4
plot: Fix incorrect tooltip dot left position (#919) 2025-06-05 16:25:28 +08:00
Floyd Wang
ecfa6b8451
chart: Add decimal feature (#918) 2025-06-05 16:03:20 +08:00
Floyd Wang
516c8fada4
chart: Introduce chart (#878)
Add a new component called `plot`. It provides a low-level approach to
data analysis and visualization.
Chart is a collection of ready-to-use chart components built with
`plot`.

| Light | Dark |
| - | - |
| <img width="1712" alt="SCR-20250604-qhxb"
src="https://github.com/user-attachments/assets/bf7ce76e-ab7a-42c2-92e7-17cd135de66f"
/> | <img width="1712" alt="SCR-20250604-qhxr"
src="https://github.com/user-attachments/assets/dd3e44ea-bbb5-41a2-8cce-38b316d7d800"
/> |
2025-06-04 19:22:11 +08:00