Closed repi closed 1 month ago
Thanks for taking a look at this and opening an issue!
I agree that the clean solution is desirable, but also more complicated, so maybe I'll start with the simple solution.
sounds good!
Link to the ubuntu font license 404s Please correct me if wrong, but I assume this is it: https://ubuntu.com/legal/font-licence
Also just hit this - I think a separate crate for the fonts would be the right way to go
You wanna make a PR for that? epaint_default_fonts
makes sense imho. Maybe we should version and publish it separately from the other crates, though that's slightly more annoying. But releasing a new version of it every time we release a new egui
seems wasteful, when the default fonts rarely change.
The
epaint
crate uses licenseMIT OR Apache-2.0
but when one uses it with the default features or thedefault_fonts
features a set of default fonts are embedded in the binary that have additional licenses.This makes it so tools like cargo-deny (license compliance) and cargo-about (license attribution) can't see and validate/include the required licenses.
These are the licenses used for the default fonts:
fonts/emoji-icon-font.ttf
- license: MITfonts/Hack-Regular.ttf
- license: MITfonts/NotoEmoji-Regular.ttf
- license:OFL-1.1
fonts/Ubuntu-Light.ttf
- license: "UBUNTU FONT LICENSE 1.0"LicenseRef-UFL-1.0
.So to be fully correct in the license definition of the
epaint
crate I believe we would have to specify to license as:(MIT OR Apache-2.0) AND OFL-1.1 AND LicenseRef-UFL-1.0
.A recent and good previous example for another crate was https://github.com/dtolnay/unicode-ident/pull/9.
A drawback of that however would be that if you use the crate with
default-features = false
and not withfeatures = ["default_fonts"]
tools wouldn't know that these licenses are then not required.So believe the most clean solution for everyone would be to split out the default fonts into a separate crate (like
epaint-default-fonts
) that has this full license, a crate that just doesinclude_bytes!
on the fonts and exposes global variable with them. And then inepaint
we can keepMIT OR Apache-2.0
license and include theepaint-default-fonts
optionally in that.Tools like cargo-deny and cargo-about would fully understand this and then only require that the
OFL-1.1
andLicenseRef-UFL-1.0
are on the allow list if the optional default fonts are included.What do you think about such an approach @emilk ?