Last active
November 13, 2023 12:29
-
-
Save mfornos/9991865 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
----------------------------------- | |
Emoji - natural display for the web | |
----------------------------------- | |
These font face definitions allows to display emoji glyphs intermingled with | |
arbitrary characters outside emoji unicode blocks. | |
Usage | |
----- | |
<p style="font-family: emoji;"> | |
You can mix text with em😶ji glyphs, like this one 💓, | |
WITHOUT wrapping into any HTML tag. 💕 | |
</p> | |
Known Limitations | |
----------------- | |
- See https://developer.mozilla.org/en-US/docs/Web/CSS/unicode-range | |
for unicode-range CSS descriptor compatibility. | |
Have fun! | |
*/ | |
@font-face { | |
font-family: emoji; | |
/* Fonts for text outside emoji blocks */ | |
src: local('Droid Sans Mono'), | |
local('Lucida Console'), | |
local('Arial Monospaced'), | |
local(Arial); | |
} | |
@font-face { | |
font-family: emoji; | |
src: local('Apple Color Emoji'), | |
local('Android Emoji'), | |
local('Segoe UI'), | |
local(EmojiSymbols), | |
local(Symbola), | |
url('font/Symbola-Emoji.eot?#iefix') format('embedded-opentype'), | |
url('font/Symbola-Emoji.woff') format('woff'), | |
url('font/Symbola-Emoji.ttf') format('truetype'); | |
/* Emoji unicode blocks */ | |
unicode-range: U+1F300-1F5FF, U+1F600-1F64F, U+1F680-1F6FF, U+2600-26FF; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/fontforge | |
/* | |
================== | |
Keeps Emoji Glyphs | |
================== | |
Usage: | |
$ chmod +x emoji.pe | |
$ ./emoji.pe | |
alternately | |
$ fontforge -script emoji.pe font.ttf emoji-font.ttf | |
*/ | |
Open($argv[1]); | |
SelectNone(); | |
SelectMore(0u1F300, 0u1F5FF); | |
SelectMore(0u1F600, 0u1F64F); | |
SelectMore(0u1F680, 0u1F6FF); | |
SelectMore(0u2600, 0u26FF); | |
SelectInvert(); | |
Clear(); | |
Generate($argv[2], "", 4); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
These fonts are supposed to be generated using the posted
emoji.pe
Font Forge script.