Closed javan closed 10 years ago
Please disregard my original comment. I was looking at some outdated information on wikipedia -- I should have been looking at the page from the Apple reference manual you linked instead. :blush:
https://developer.apple.com/fonts/TrueType-Reference-Manual/RM06/Chap6sbix.html
With that in mind, I think we probably could accept this patch, but please add some tests for it.
Ok, cool. Happy to add some tests. It's probably best to test against a file with an sbix table and the only one that I know of is Apple's emoji font. Do you have any copyright concerns about bundling it in the test suite? If so, do you happen to know of an alternative?
@javan: Maybe give this one a try? https://github.com/MorbZ/OpenSansEmoji
We definitely can't bundle non-free fonts, unfortunately.
OpenSansEmoji doesn't have an sbix table, but I found a sample font here - http://typophile.com/node/103268 - that does. Added some tests.
Merged, thank you!
:metal:
@javan: Because your pull request was accepted, you now have commit access to all prawnpdf repositories. See the contribution guidelines for more details, and thanks for the patch!
Cool. Already putting this to work https://github.com/github/gemoji/pull/63 :grin:
@javan: Nice! I'll try to make sure to get a release cut soon, so you can switch back to the rubygems.org version of TTFunk when that happens.
I'm trying to shoehorn the Android emoji font into this. I'm not having any luck. I don't know anything about TTF fonts: is it maybe the same issue as above, with this font not having an sbix table?
I'm trying to do extract all the emojis with TTFunk but can't find the way. Can someone help me. What do I have to run from the terminal after installing the gem TTFunk?
@Danny182 You can take a look at sbix table specs
@pointlessone , thank you for the reply. I didn't understand how to run the code. If I run "ruby file_spec.rb" I get the missing "spec_helper.rb". If I run that one I get another missing one. Sorry but I'm having problems to run the "Rakefile".
@Danny182 That code won't extract anything for you. That is merely an example of usage. You would need to write your own code to actually extract emoji.
The file is not a "Rakefile". It's a spec file meant to be run with RSpec. Try rspec spec/integration/file_spec.rb
to run it but I'm not sure how that might be helpful to you.
I found a way. By running "gemoji" by terminal running "rake images:extract" it extracts the emojis but it doesn't extracts some of them. "🙄 1F644" doesn't get extracted. I updated manually the "db/NamesList.txt" (the info of that emoji is in there). Can someone help me?
Thanks in advance @pointlessone @javan
I set out to find an effective way of extracting emoji images from Apple's "Apple Color Emoji.ttf" font and found that the data necessary data is in the sbix table.