# gpui: Add support for text in SVGs \(\#26335\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/41c373eff159273e107584e1511badbfbb1d5c50)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 41c373eff159273e107584e1511badbfbb1d5c50

Requested commit: 41c373eff159273e107584e1511badbfbb1d5c50

Commit: 41c373eff159273e107584e1511badbfbb1d5c50

Tree: 965a1dce2d28357920db219d7ddb3f60ddae5677

Author: Kamal Ahmad

Committer: GitHub

## Message

```
gpui: Add support for text in SVGs (#26335)

Closes #21319
Before: 

![image](https://github.com/user-attachments/assets/f75d7d59-75b1-4836-ae3b-6a1f526a5833)
After:

![image](https://github.com/user-attachments/assets/5fa28a6d-c417-4777-99f8-2a17edf759a0)

Use fontdb to load system fonts and pass it to resvg renderer. This adds
a small increase in startup time (around 30ms on my Linux system to
traverse fonts on a cold start). In the future once cosmic-text bumps
their version of fontdb we could clone the Database from
CosmicTextSystem

Release Notes: 
- Added: support for rendering text in SVGs
```

## Parents

- [6a95ec6a64c7b56ce107cec5b089765610ebbabd](https://git.cafe/gitcafe/zed/commit/6a95ec6a64c7b56ce107cec5b089765610ebbabd?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/41c373eff159273e107584e1511badbfbb1d5c50?format=markdown)
