Closed jrmuizel closed 6 years ago
It uses fontconfig, which seems plenty sophisticated to me :D
[Disclaimer:Author] I think he meant sophisticated on its own, which is right! It provides a minimalistic wrapper over the native font capabilities. It could probably do more things, like trying to query the systems default fonts or something, but nobody declared interest in such features yet.
Its meant specifically to support such libraries. If there are questions/suggestions, feel free to open issues!
Yeah thanks for the heads up, wasn't aware of this library but ultimately this functionality will be needed, and it would be nice to have it as a dependency.
@MSleepyPanda I'm wondering though, does it support Android/iOS or is it planned to? It will probably be a while before limn is usable on those platforms but I still want to keep them in mind and minimize changes that will make it harder to support them.
It should make sense to support those two targets as well, but we currently don't. Opened issues for both!
Thanks! I should mention that adding support for those to font-loader shouldn't be a pre-requisite for adding font-loader support to limn. If anybody is interested in working on it, PRs are welcome! If no one gets around to working on it I'll add it eventually, but it's not high priority for me yet.
Also, please don't do this for images, either. limn
should not be responsible for loading the data of images and loading fonts. These could, for example come over the network (ex. an FTP program that views data from a remote server). This is up to the user of the binary - limn
should only have a R: std::io::Read
trait bound and that's it.
font-loader support added by #39
It's not very sophisticated but it works on all platforms and is better than having to include fonts in assets. It's what we use for font-loading in webrender/wrench.