Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

impl AsRef<[u8]> for FontData #5757

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

StratusFearMe21
Copy link
Contributor

@StratusFearMe21 StratusFearMe21 commented Mar 3, 2025

  • I have followed the instructions in the PR template

This PR implements AsRef<[u8]> for FontData, allowing it to be passed into fontdb's Source type. This would allow egui and cosmic_text to share font data with eachother

Copy link
Collaborator

@lucasmerlin lucasmerlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

This would allow egui and cosmic_text to share font data with eachother

Note that this would have been possible previously as well though, since FontData::font is public

@lucasmerlin lucasmerlin added epaint feature New feature or request labels Mar 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
epaint feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants