Closes [1729](https://github.com/longbridge/gpui-component/issues/1729)
## Description
Adds support for inline completions, which allows the editor to support
agentic "tab to complete" solutions. This works, (tested macOS), but not
sure of any gotchas or different approaches.
## Screenshot
https://github.com/user-attachments/assets/8e437f1e-9792-4417-b070-0a1dd8de6024
## How to Test
User implements the `inline_completion` method in CompletionsProvider.
Not implementing should have no effect.
## Checklist
- [x] I have read the [CONTRIBUTING](../CONTRIBUTING.md) document and
followed the guidelines.
- [x] Reviewed the changes in this PR and confirmed AI generated code
(If any) is accurate.
- [x] Passed `cargo run` for story tests related to the changes.
- [ ] Tested macOS, Windows and Linux platforms performance (if the
change is platform-specific)
---------
Co-authored-by: Jason Lee <huacnlee@gmail.com>
All WEF (Web Embedding Framework) related code has been successfully
removed from the repository as it has been extracted to
https://github.com/longbridge/wef
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: huacnlee <5518+huacnlee@users.noreply.github.com>
Now with 10K lines plain text, in release mode on macOS. The
`large-text` example can work with:
- 120 FPS for display.
- 90 FPS for update text.
```
MTL_HUD_ENABLED=1 cargo run --example large-text --release
```
- Fixed the cursor position at end of line, also support at start of
line.
https://github.com/user-attachments/assets/1de52f6c-e138-4ed3-a600-06372a807ed8
### Check list
- [x] Modifying Text with Rope
- [x] LineColumn, GoToLine
- [x] Code Highlight
- [x] Delete word, select word
- [x] Delete line
- [x] Move left, right, up, down
Inspired by Zed, this PR implements a simple live Rust and JSON style
editor for the inspector.
The rust style editor only supports `Styled` and `StyledExt` method
calls with no arguments.
https://github.com/user-attachments/assets/df7f1746-92d7-416c-afd5-e389ac3ea9ae
---------
Co-authored-by: Floyd Wang <gassnake999@gmail.com>
This change to fix some incorrect style use, that will break in Taffy
0.5.2+
Ref https://github.com/zed-industries/zed/pull/34827
- Add `Tab::empty` to create a Tab without label.
- Fix form layout in Taffy new version.
- Update GPUI for scroll API changes.
- Added a lot of default fallbacks for theme colors based on `base`
colors.
- Added `hue`, `saturation`, `lightness` method to change Hsla color.
- Update stories to use theme colors, not a direct color.
- Improve `Badge`, `Avatar` to use theme colors.
- Added a new theme: `Fahrenheit`.