{"id":9306,"date":"2020-03-12T15:30:32","date_gmt":"2020-03-12T07:30:32","guid":{"rendered":"https:\/\/www.zhangxinxu.com\/wordpress\/?p=9306"},"modified":"2022-07-21T14:40:59","modified_gmt":"2022-07-21T06:40:59","slug":"css-emoji-opentype-svg-fonts","status":"publish","type":"post","link":"https:\/\/www.zhangxinxu.com\/wordpress\/2020\/03\/css-emoji-opentype-svg-fonts\/","title":{"rendered":"\u5173\u4e8eCSS emoji\u5b57\u4f53\u548cOpenType-SVG\u6211\u6240\u77e5\u9053\u7684\u4e00\u4e9b\u4e8b"},"content":{"rendered":"<p>by <a href=\"https:\/\/www.zhangxinxu.com\/\">zhangxinxu<\/a> from <a href=\"https:\/\/www.zhangxinxu.com\/wordpress\/?p=9306\">https:\/\/www.zhangxinxu.com\/wordpress\/?p=9306<\/a><br \/>\n\u672c\u6587\u6b22\u8fce\u5206\u4eab\u4e0e\u805a\u5408\uff0c\u5168\u6587\u8f6c\u8f7d\u5c31\u4e0d\u5fc5\u4e86\uff0c\u5c0a\u91cd\u7248\u6743\uff0c\u5708\u5b50\u5c31\u8fd9\u4e48\u5927\uff0c\u82e5\u6025\u7528\u53ef\u4ee5\u8054\u7cfb\u6388\u6743\u3002<\/p>\n<p><script>window.wxShareImgUrl = 'https:\/\/www.zhangxinxu.com\/study\/image\/share\/202003-emoji-font.jpg';<\/script><\/p>\n<p style=\"padding:10px;border:1px solid #eee;\"><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/emoji-480.png\" width=\"480\" height=\"238\" alt=\"emoji\u8868\u60c5\u5360\u4f4d\" class=\"aligncenter size-medium\" \/><\/p>\n<p>\u672c\u6587\u662f\u53c2\u8003\u4e00\u4e9b\u8d44\u6599\u4e4b\u540e\u7684\u788e\u788e\u5ff5\uff0c\u53ef\u80fd\u6bd4\u8f83\u6742\uff0c\u53ef\u80fd\u6bd4\u8f83\u4e71\uff0c\u53ef\u80fd\u6ca1\u6709\u4ec0\u4e48\u903b\u8f91\uff0c\u60f3\u5230\u54ea\u91cc\u8bf4\u5230\u54ea\u91cc\uff0c\u5982\u679c\u6709\u8bf4\u7684\u4e0d\u51c6\u786e\u7684\u5730\u65b9\uff0c\u6b22\u8fce\u6307\u6b63\u3002<\/p>\n<h3>\u4e00\u3001CSS emoji\u5b57\u4f53\u788e\u788e\u5ff5<\/h3>\n<p>\u76ee\u524d\u4e3b\u6d41\u7684\u64cd\u4f5c\u7cfb\u7edf\u90fd\u5df2\u7ecf\u5185\u7f6eemoji\u5b57\u4f53\uff0c\u4f8b\u5982\u82f9\u679c\u64cd\u4f5c\u7cfb\u7edf\uff0ciOS\uff0c\u5b89\u5353\u4ee5\u53caWindows 10\u7b49\u3002<\/p>\n<p>\u7136\u800c\u867d\u7136\u5185\u7f6e\u4e86emoji\u5b57\u4f53\uff0c\u4f46\u662f\u6211\u4eec\u7684emoji\u5b57\u7b26\u5e76\u4e0d\u603b\u662f\u4f1a\u81ea\u52a8\u663e\u793a\u4e3a\u5f69\u8272\u7684emoji\u7684\u56fe\u5f62\uff0c\u4f8b\u5982\u4e00\u4e2a\u7b11\u8138\uff1a\u263a<\/p>\n<p>\u5728\u6211\u73b0\u5728\u7684\u7f16\u8f91\u5668\u91cc\u9762\u5c31\u662f\u4e2a\u5b57\u7b26\u7b11\u8138\uff0c\u9884\u89c8\u4e5f\u662f\u4e2a\u5b57\u7b26\u7b11\u8138\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/2020-03-11_221551.png\" width=\"155\" height=\"104\" alt=\"emoji\u5b57\u7b26\u7b11\u8138\" class=\"alignnone size-medium\" \/><\/p>\n<p>\u5982\u679c\u6211\u4eec\u5e0c\u671b\u5b57\u7b26\u7b11\u8138\u5448\u73b0\u4e3a\u5f69\u8272\u7684\u56fe\u5f62\u7b11\u8138\uff0c\u9700\u8981\u4e13\u95e8\u4f7f\u7528\u4e00\u4e0bemoji\u5b57\u4f53\uff0c\u4f8b\u5982\uff1a<\/p>\n<pre>\r\narticle {\r\n    <span style=\"color:green;\">\/* windows\u7cfb\u7edf\u4e0bemoji\u5b57\u4f53 *\/<\/span>\r\n    font-family: Segoe UI Emoji;\r\n}<\/pre>\n<p>\u6b64\u65f6\u5c31\u4f1a\u53d8\u6210\u8fd9\u6837\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/2020-03-11_222124.png\" width=\"165\" height=\"123\" alt=\"emoji\u7b11\u8138\" class=\"alignnone size-medium\" \/><\/p>\n<p>\u8003\u8651\u5230\u8fd8\u8981\u517c\u987e\u5176\u4ed6\u64cd\u4f5c\u7cfb\u7edf\uff0c\u5b8c\u6210\u7684Emoji\u5b57\u4f53\u8bbe\u7f6e\u4ee3\u7801\u4e3a\uff1a<\/p>\n<pre>\r\narticle {\r\n    font-family: Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, Noto Color Emoji;\r\n}<\/pre>\n<p>\u5176\u4e2d\uff1a<\/p>\n<ul>\n<li>Apple Color Emoji\u7528\u5728Apple\u7684\u4ea7\u54c1\u4e2d\uff0c\u4f8b\u5982iPhone\uff08iOS\u7cfb\u7edf\uff09\u6216\u8005Mac Pro\uff08macOS\u7cfb\u7edf\uff09\u7b49\u3002<\/li>\n<li>Segoe UI Emoji\u7528\u5728Windows\u7cfb\u7edf\u4e2d\uff0c<\/li>\n<li>Segoe UI Symbol\u662f\u5728Windows 7\u4e2d\u6dfb\u52a0\u7684\u4e00\u79cd\u65b0\u5b57\u4f53\uff0c\u5b83\u5305\u62ec\u65b0\u7684\u811a\u672c\/\u7b26\u53f7\uff0c\u5982\u76f2\u6587\u3001\u5fb7\u585e\u83b1\u7279\u6587\u3001\u5965\u683c\u59c6\u6587\u6216\u7b26\u6587\u5b57\u5f62\u3002\u4e0d\u8fc7\uff0c\u5b83\u4e0d\u662f\u201c\u7b26\u53f7\u5b57\u7b26\u96c6\u7f16\u7801\u5b57\u4f53\u201d\uff08\u5982MS symbol\uff09\uff0c\u800c\u662f\u4e00\u79cdUnicode\u7f16\u7801\u5b57\u4f53\uff0c\u5176\u7b26\u53f7\u88ab\u5206\u914d\u7ed9\u5404\u4e2aUnicode\u7801\u4f4d\u3002Segoe UI symbol\u8fd8\u6709\u4e00\u4e9b\u5176\u4ed6\u6742\u9879\u7b26\u53f7\uff0c\u5982\u68cb\u5b50\uff0c\u6251\u514b\u724c\u548c\u9ab0\u5b50\u7b26\u53f7\uff08\u8fd9\u4e9b\u7b26\u53f7\u6784\u6210\u4e86Segoe\u56fd\u9645\u8c61\u68cb\u548cSegoe\u65b0\u95fb\u7b26\u53f7\u5b57\u4f53\u7684\u57fa\u7840\uff09\u3001\u5236\u8868\u7b26\u3001\u5757\u5143\u7d20\u3001\u6280\u672f\u7b26\u53f7\u3001\u6570\u5b66\u8fd0\u7b97\u7b26\u3001\u7bad\u5934\u3001\u63a7\u5236\u56fe\u7247\u548cOCR\u4f18\u5316\u7684\u7b26\u53f7\u3002\u5728Windows 8\u4e2d\uff0cSegoe UI\u7b26\u53f7\u6269\u5c55\u5230\u652f\u6301Glagolitic\u3001Gothic\uff0c\u65e7\u7684\u659c\u4f53\u548cOrkhon\u811a\u672c\u3002\u5728Windows 8.1\u4e2d\uff0c\u5b83\u83b7\u5f97\u4e86\u5bf9Meroitic\u8349\u4e66\u548c\u79d1\u666e\u7279\u811a\u672c\u7684\u652f\u6301\u3002\u4eceWindows 8\u66f4\u65b0\u7684Segoe UI\u7b26\u53f7\u4e5f\u5df2\u88ab\u79fb\u690d\u5230Windows 7\u3002<\/li>\n<li>Noto Color Emoji\u662f\u8c37\u6b4c\u7684Emoji\u5b57\u4f53\uff0c\u7528\u5728Android\u548cLinux\u7cfb\u7edf\u4e2d\u3002\u7ecf\u8fc7\u6211\u7684\u6d4b\u8bd5\u53d1\u73b0\uff0cNoto Color Emoji\u8fd9\u4e2a\u5b57\u4f53\u76f4\u63a5\u7528\u5728<code>font-family<\/code>\u5c5e\u6027\u4e2d\u662f\u6ca1\u6709\u7528\u7684\uff0c\u4f7f\u7528<code>@font-face<\/code> <code>local(\"Noto Color Emoji\")<\/code>\u4e00\u4e0b\u662f\u6709\u6548\u7684\uff0c\u6709\u4e9b\u5947\u602a\u3002<\/li>\n<\/ul>\n<p>\u6211\u4eec\u53ef\u4ee5\u4e13\u95e8\u5b9a\u4e49\u4e00\u4e2a\u65b0\u7684Emoji\u5b57\u4f53\u6765\u7b80\u5316\u6211\u4eec\u7684\u4ee3\u7801\uff0c\u4f8b\u5982\uff1a<\/p>\n<pre>@font-face {\r\n  font-family: \"color-emoji\";\r\n  src: local(\"Apple Color Emoji\"),\r\n       local(\"Segoe UI Emoji\"), \r\n       local(\"Segoe UI Symbol\"),\r\n       local(\"Noto Color Emoji\");\r\n}\r\narticle {\r\n    font-family: \"color-emoji\";\r\n}<\/pre>\n<h4>\u7b11\u8138\u4e0d\u662femoji\u56fe\u5f62\u7684\u539f\u56e0\uff1f<\/h4>\n<p>\u7b11\u8138\u263a\u5b57\u7b26\uff08\\263a\uff09\u7b97\u5f97\u4e0a\u4e00\u4e2a\u5f88\u5e38\u89c1\u7684\u5b57\u7b26\uff0c\u4e8e\u662f\u5f88\u591a\u5b57\u4f53Unicode\u8303\u56f4\u5c31\u5305\u542b\u4e86\u8fd9\u4e2a\u5b57\u7b26\uff0c\u5bfc\u81f4\u4e0d\u662f\u5f69\u8272\u56fe\u5f62\u3002<\/p>\n<p>\u5982\u679c\u6211\u4eec\u4f7f\u7528\u7684\u662f\u4e00\u4e2a\u4e0d\u5e38\u89c1\u7684\u8138\u90e8\u7b11\u8138\u8868\u60c5\uff0c\u4f8b\u5982?\uff08\\1f600\uff09\uff0c\u6211\u4eec\u65e0\u9700\u989d\u5916\u7684\u5b57\u4f53\u8bbe\u7f6e\uff0c\u5b83\u5c31\u5448\u73b0\u51fa\u4e86emoji\u56fe\u5f62\u7684\u6837\u5b50\u3002\u622a\u56fe\u793a\u610f\u5982\u4e0b\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/2020-03-11_223539.png\" width=\"440\" height=\"105\" alt=\"emoji\u5929\u7136\u5448\u73b0\u793a\u610f\" class=\"alignnone size-medium\" \/><\/p>\n<p>\u56e0\u6b64\uff0c\u6211\u4e00\u76f4\u6000\u7591github\u7b49\u7f51\u7ad9\u8bbe\u7f6e\u4e0b\u9762\u8fd9\u79cdCSS\u6ca1\u4ec0\u4e48\u7528\uff1f<\/p>\n<pre>body {\r\n    font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-serif,<strong>Apple Color Emoji,Segoe UI Emoji<\/strong>;\r\n}<\/pre>\n<p>\u5927\u5bb6\u53ef\u4ee5\u770b\u5230<code>Apple Color Emoji<\/code>\u548c<code>Segoe UI Emoji<\/code>\u8fd9\u4e24\u4e2a\u5b57\u4f53\u653e\u5728\u4e86\u6700\u540e\u3002<\/p>\n<p>\u6709\u4ec0\u4e48\u610f\u4e49\u5462\uff1f<\/p>\n<p>\u6211\u80fd\u60f3\u5230\u6709\u91cd\u8981\u7684\u5c31\u4e24\u4e2a\u573a\u666f\u3002<\/p>\n<ol>\n<li>\u7528\u6237\u5728windows\u7cfb\u7edf\u4e0a\u4e5f\u5b89\u88c5\u4e86\u82f9\u679c\u7684emoji\u5b57\u4f53\uff0c\u4e8e\u662fWindows\u7cfb\u7edf\u4f18\u5148\u663e\u793a\u82f9\u679c\u7684emoji\u8868\u60c5\u3002<\/li>\n<li>\u4e00\u4e9b\u8001\u65e7\u64cd\u4f5c\u7cfb\u7edf\uff0c\u4f8b\u5982win7\uff0cwindows8\u5e76\u6ca1\u6709\u5f69\u8272\u7684emoji\u5b57\u4f53\uff0c\u7528\u6237\u81ea\u5df1\u5b89\u88c5\u4e86\uff0c\u9700\u8981\u5728\u8fd9\u4e9b\u7cfb\u7edf\u4e0a\u663e\u793a\u3002<\/li>\n<\/ol>\n<p>\u4f46\u662f\u4e0b\u9762\u8fd9\u4e24\u79cd\u573a\u666f\u51fa\u73b0\u7684\u6982\u7387\u4e5f\u5b9e\u5728\u592a\u5c0f\u4e86\u5440\uff0c\u767e\u601d\u4e0d\u5f97\u5176\u89e3\uff01<\/p>\n<p>\u601d\u662f\u65e0\u89e3\uff0c\u4e8e\u662f\u6211\u5c31\u52a8\u624b\u518d\u6d4b\u8bd5\uff0c\u7ec8\u4e8e\u641e\u6e05\u695a\u5230\u5e95\u600e\u4e48\u56de\u4e8b\u4e86\uff0cemoji\u5b57\u4f53\u653e\u5728\u6700\u540e\u8fd8\u662f\u6709\u70b9\u7528\u5904\u7684\u3002<\/p>\n<h4>\u539f\u6765\u7b11\u8138\u662f\u7279\u6b8a\u7684<\/h4>\n<p>\u7b11\u8138\u7684Unicode\u6bd4\u8f83\u9760\u524d\uff0c\u4e8e\u662f\u4e00\u4e9b\u5e38\u89c4\u7684\u5b57\u4f53\u5c31\u53ef\u4ee5\u8986\u76d6\u5230\uff0c\u4f8b\u5982Arial\u3002<\/p>\n<p>\u6709\u5b57\u7b26\u7684Unicode\u6bd4\u8f83\u9760\u540e\uff0c\u5c5e\u4e8e\u5178\u578b\u7684Emoji\u5b57\u7b26\uff0c\u8fd9\u4e9b\u5b57\u7b26\u8bbe\u4e0d\u8bbe\u7f6e\u90fd\u4f1a\u8868\u73b0\u4e3aEmoji\u56fe\u5f62\uff0c\u4f8b\u5982\\1f600\u8fd9\u4e2a\u7b11\u8138?\u3002<\/p>\n<p>\u8fd8\u6709\u4e9b\u5b57\u7b26\uff0c\u5904\u5728\u4e0d\u4e0a\u4e0d\u4e0b\u7684\u4f4d\u7f6e\uff0c\u4f8b\u5982\u94c5\u7b14\u270f\u548c\u8b66\u793a\u26a0\u3002\u65e2\u7136\u6700\u7ec8\u5448\u73b0\u7684\u4e0d\u662f\u65b9\u6846\u5b57\u7b26\uff0c\u8bf4\u660e\u6284\u7cfb\u7edf\u4e2d\u8fd8\u662f\u6709\u5b57\u4f53\u53ef\u4ee5\u8986\u76d6\u5230\u4ed6\u4eec\u7684\uff0c\u4f46\u662f\u8fd9\u4e9b\u5b57\u4f53\u53ef\u80fd\u5e76\u4e0d\u5728Web\u8bbe\u7f6e\u7684\u5b57\u4f53\u8303\u56f4\u5185\uff0c\u4f8b\u5982Segoe UI\u3001Helvetica\u3001Arial\u8fd9\u4e9b\u5b57\u4f53\u90fd\u6ca1\u6709\u8986\u76d6\u5230\uff0c\u4e8e\u662f\u4e0b\u9762\u8fd9\u6bb5CSS\u4ee3\u7801\u540e\u9762\u7684\u201cApple Color Emoji,Segoe UI Emoji\u201d\u5c31\u6709\u4f5c\u7528\u4e86\uff0c\u53ef\u4ee5\u8ba9\u94c5\u7b14\u270f\u548c\u8b66\u793a\u26a0\u5728\u89c6\u89c9\u4e0a\u662fEmoji\u56fe\u5f62\uff1a<\/p>\n<pre>body {\r\n    font-family: -apple-system,BlinkMacSystemFont,Segoe UI,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji;\r\n}<\/pre>\n<p>\u5982\u4e0b\u56fe\u6240\u793a\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/2020-03-11_235307.png\" width=\"662\" height=\"354\" alt=\"\u94c5\u7b14\u548c\u8b66\u793a\u53d8\u6210Emoji\u56fe\u5f62\" class=\"alignnone size-medium\" \/><\/p>\n<p>\u6240\u4ee5emoji\u5b57\u4f53\u653e\u5728\u6700\u540e\u8fd8\u662f\u6709\u90e8\u5206\u7528\u5904\u7684\u3002<\/p>\n<p>\u5f53\u7136\uff0c\u5982\u679c\u4f60\u60f3\u6240\u6709\u7684\u7279\u6b8a\u5b57\u7b26\u4ee5Emoji\u56fe\u5f62\u7684\u65b9\u5f0f\u5448\u73b0\uff0c\u90a3\u5c31\u5e94\u8be5\u628aemoji\u5b57\u4f53\u653e\u5728\u6700\u524d\u9762\u3002\u4f8b\u5982\uff1a<\/p>\n<pre>body {\r\n    font-family: \"color-emoji\", system-ui, Segoe UI,Helvetica,Arial,sans-serif;\r\n}<\/pre>\n<p>\u4f46\u662f\uff0c\u5176\u4ed6\u666e\u901a\u6587\u5b57\u5448\u73b0\u7684\u5730\u65b9\u4e0d\u8981\u8fd9\u4e48\u505a\uff0c\u56e0\u4e3aemoji\u5b57\u4f53\u4e5f\u5305\u542b\u6570\u5b57\u82f1\u6587\u5b57\u6bcd\u4e4b\u7c7b\u7684\uff0c\u4f1a\u5f71\u54cd\u6b63\u5e38\u5185\u5bb9\u7684\u663e\u793a\u3002\u540c\u65f6\uff0c\u6709\u65f6\u5019\u6211\u4eec\u5e0c\u671b\u6709\u4e9b\u5b57\u7b26\u8fd8\u662f\u539f\u59cb\u5f62\u72b6\uff0c\u4f8b\u5982\u56db\u4e2a\u503e\u659c\u7bad\u5934\u5b57\u7b26\u2196 \u2197 \u2199 \u2198\uff0c\u800c\u4e0d\u662fEmoji\u6548\u679c\u3002\u8fd9\u4e2a\u65f6\u5019\u53ef\u4ee5\u901a\u8fc7<code>unicode-range<\/code>\u9650\u5b9a\u4e0b\u4f7f\u7528Emoji\u5b57\u7b26\u7684\u8303\u56f4\uff0c\u4f8b\u5982\uff1a<\/p>\n<pre>@font-face {\r\n  font-family: \"color-emoji\";\r\n  src: local(\"Apple Color Emoji\"),\r\n       local(\"Segoe UI Emoji\"), \r\n       local(\"Segoe UI Symbol\"),\r\n       local(\"Noto Color Emoji\");\r\n  <span style=\"color:green;\">\/* \u8303\u56f4\u793a\u610f\uff0c\u81ea\u5df1\u6839\u636e\u9700\u6c42\u8c03\u6574 *\/<\/span>\r\n  unicode-range: U+1F000-1F644, U+203C-3299;\r\n}<\/pre>\n<p>\u4e0d\u8fc7\u8fd8\u662f\u5570\u55e6\uff0c\u56e0\u6b64\uff0c\u6211\u4eec\u8fd8\u662f\u628aemoji\u8868\u60c5\u653e\u5728\u6700\u540e\uff0c\u4e00\u5b9a\u7a0b\u5ea6\u589e\u5f3aemoji\u8868\u60c5\u7684\u663e\u793a\u3002<\/p>\n<h4>\u5982\u679c\u5e0c\u671b\u4e0d\u663e\u793a\u5f69\u8272emoji<\/h4>\n<p>\u5728\u9ed1\u6697\u6a21\u5f0f\u4e0b\uff0c\u989c\u8272\u53cd\u8f6c\u7684\u65f6\u5019\uff0cemoji\u4e5f\u53cd\u8f6c\u4f1a\u5f88\u4e0d\u597d\u770b\uff0c\u6b64\u65f6\u53ef\u4ee5\u8bd5\u8bd5\u5728 emoji \u5b57\u7b26\u540e\u9762\u52a0\u4e00\u4e2a &amp;#xFE0E; \u53ef\u4ee5\u8ba9\u5b57\u7b26\u4ee5\u7eaf\u672c\u6587\u5b57\u7b26\u663e\u793a\uff0c\u800c\u4e0d\u662f emoji \u5b57\u7b26\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/image.zhangxinxu.com\/image\/blog\/202203\/emoji-convert.jpeg\" width=\"76\" height=\"138\" alt=\"\u4e0d\u663e\u793a emoji\" class=\"alignnone size-medium\" \/><\/p>\n<h3>\u4e8c\u3001\u81ea\u5b9a\u4e49\u7684emoji\u5b57\u4f53<\/h3>\n<p>\u9664\u4e86\u51e0\u4e2a\u7cfb\u7edf\u5185\u7f6e\u7684emoji\u5b57\u4f53\uff0c\u6211\u4eec\u8fd8\u53ef\u4ee5\u5f15\u5165\u81ea\u5df2\u7684emoji\u5b57\u4f53\u3002<\/p>\n<p>\u4f8b\u5982Adobe\u51fa\u4e86\u4e2a\u540d\u53eb<a href=\"https:\/\/github.com\/adobe-fonts\/emojione-color\" target=\"_blank\" rel=\"noopener\">EmojiOne<\/a>\u7684Emoji\u5b57\u4f53\uff0c\u662f\u4e00\u79cdOpenType-SVG\u5b57\u4f53\u5f69\u8272\u5b57\u4f53\uff1bTwitter\u4e5f\u5f00\u6e90\u4e86\u4e00\u4e2a<a href=\"https:\/\/github.com\/eosrei\/twemoji-color-font\" rel=\"noopener\" target=\"_blank\">Twemoji<\/a>\u7684Emoji\u5b57\u4f53\u3002<\/p>\n<p>\u4f7f\u7528\u793a\u610f\uff1a<\/p>\n<pre>@font-face {\r\n  font-family: 'emoji';\r\n  src: url('emojione-svg.woff2') format('woff2');\r\n}<\/pre>\n<p>\u6b64\u65f6\u8f93\u5165Emoji\u7b26\u53f7\uff0c\u5c31\u4f1a\u51fa\u73b0\u5f69\u8272\u7684\u56fe\u5f62\u6548\u679c\uff0c\u4f8b\u5982\u5728Firefox\u6d4f\u89c8\u5668\u4e0b\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/emoji-4.png\" width=\"487\" height=\"128\" alt=\"Firefox\u6d4f\u89c8\u5668\u4e0bEmoji\u793a\u610f\" class=\"alignnone size-medium\" \/><\/p>\n<p>\u76ee\u524dOpenType-SVG\u5b57\u4f53Chrome\u548cSafari\u6d4f\u89c8\u5668\u662f\u4e0d\u652f\u6301\u7684\uff0cFirefox\u6d4f\u89c8\u5668\u548cEdge\u652f\u6301\u3002<\/p>\n<p>\u4e0b\u9762\u8fd9\u4e2aCSS-tricks\u4e0a<a href=\"https:\/\/css-tricks.com\/it-all-started-with-emoji-color-typography-on-the-web\/\" rel=\"noopener\" target=\"_blank\">\u8fd9\u7bc7\u6587\u7ae0<\/a>\u4e2d\u627e\u5230\u7684\u5f69\u8272\u5b57\u4f53\u56db\u79cd\u4e0d\u540c\u6807\u51c6\u7684\u517c\u5bb9\u6027\u8868\uff1a<\/p>\n<table style=\"text-align: center;\" class=\"params_table\">\n<tbody>\n<tr>\n<td><\/td>\n<th scope=\"col\">Chrome<\/th>\n<th scope=\"col\">Safari<\/th>\n<th scope=\"col\">Edge<\/th>\n<th scope=\"col\">Firefox<\/th>\n<\/tr>\n<tr>\n<th scope=\"row\">SVG-in-Opentype<\/th>\n<td>\u274c<\/td>\n<td>\u274c<\/td>\n<td>\u2705<\/td>\n<td>\u2705<\/td>\n<\/tr>\n<tr>\n<th scope=\"row\">COLR\/CPAL<\/th>\n<td>\u2705<\/td>\n<td>\u2705<\/td>\n<td>\u2705<\/td>\n<td>\u2705<\/td>\n<\/tr>\n<tr>\n<th scope=\"row\">SBIX<\/th>\n<td>\u2705<\/td>\n<td>\u2705<\/td>\n<td>\u2705<\/td>\n<td>\u274c<\/td>\n<\/tr>\n<tr>\n<th scope=\"row\">CBDT\/CBLC<\/th>\n<td>\u2705<\/td>\n<td>\u274c<\/td>\n<td>\u2705<\/td>\n<td>\u274c<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>\u4e4b\u6240\u4ee5\u4f1a\u67094\u4e2a\u6807\u51c6\uff0c\u662f\u56e0\u4e3a\u5f53emoji\u88ab\u6dfb\u52a0\u5230unicode\u65f6\uff0c\u4e0a\u9762\u7684\u90a3\u7fa4\u4eba\u610f\u8bc6\u5230\u9700\u8981\u4ee5\u67d0\u79cd\u65b9\u5f0f\u5411OpenType\u6dfb\u52a0\u591a\u8272\u652f\u6301\u3002\u7136\u540e\u4e0d\u540c\u7684\u516c\u53f8\u63d0\u51fa\u4e86\u4e0d\u540c\u7684\u89e3\u51b3\u65b9\u6848\uff0c\u4e8e\u662f\u5c31\u6709\u4e864\u79cd\u4e0d\u540c\u7684\u6807\u51c6\u3002<\/p>\n<p><strong>\u66f4\u65b0\u4e8e2022-07-21<\/strong><\/p>\n<p>\u60f3\u8981\u77e5\u9053\u4f60\u7684\u6d4f\u89c8\u5668\u662f\u5426\u652f\u6301\u8fd94\u79cd\u6807\u51c6\uff0c\u53ef\u4ee5\u8bbf\u95ee<a href=\"https:\/\/pixelambacht.nl\/chromacheck\/\" rel=\"noopener\" target=\"_blank\">\u8fd9\u4e2a\u9875\u9762<\/a>\u3002<\/p>\n<p>\u4f8b\u5982 Chrome 103 \u7248\u672c\u4e0b\u4ec5 SVG Opentype \u6807\u51c6\u4e0d\u652f\u6301\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/image.zhangxinxu.com\/image\/blog\/202207\/2022-07-21_143858.png\" width=\"533\" height=\"586\" alt=\"\u68c0\u6d4b\u7ed3\u679c\" class=\"alignnone size-medium\" \/><\/p>\n<h4>\u63d0\u4e00\u4e0b\u5f69\u8272\u5b57\u4f53<\/h4>\n<p>\u6709\u4e00\u4e9b\u4e13\u95e8\u7684\u5f69\u8272\u5b57\u4f53\uff0c\u4f8b\u5982Gilbert\u5b57\u4f53\uff0c\u6587\u5b57\u5929\u7136\u5f69\u8272\uff0c\u5982\u4e0b\u56fe\u793a\u610f\uff1a<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/emoji-colorful-6.png\" width=\"627\" height=\"119\" alt=\"\u5f69\u8272\u5b57\u4f53\u6587\u5b57\" class=\"alignnone size-medium\" \/><\/p>\n<p>\u5f69\u8272\u5b57\u4f53\u662f\u4e00\u9879\u65b0\u6280\u672f\uff0c\u76ee\u524d\u53ef\u4ee5\u514d\u8d39\u4f7f\u7528\u7684\u5b57\u4f53\u975e\u5e38\u5c11\uff0c\u6d4f\u89c8\u5668\u7684\u517c\u5bb9\u6027\u4e5f\u662f\u969c\u788d\uff0c\u6709\u5174\u8da3\u7684\u8bdd\u4f60\u53ef\u4ee5\u8bd5\u8bd5<a href=\"https:\/\/djr.com\/bungee\/\" rel=\"noopener\" target=\"_blank\">Bungee\u8fd9\u4e2a\u5b57\u4f53<\/a>\uff0c\u662fDavid Jonathan Ross\u8bbe\u8ba1\u5e76\u5236\u4f5c\u7684\uff0c<a href=\"https:\/\/fonts.google.com\/?selection.family=Bungee&#038;query=bungee\" rel=\"noopener\" target=\"_blank\">Google Fonts\u9884\u89c8<\/a>\uff0cGithub\u9879\u76ee\u5730\u5740\uff1a<a href=\"https:\/\/github.com\/djrrb\/bungee\" rel=\"noopener\" target=\"_blank\">https:\/\/github.com\/djrrb\/bungee<\/a>\u3002<\/p>\n<h3>\u4e09\u3001\u4e86\u89e3OpenType-SVG\u5b57\u4f53<\/h3>\n<p>OpenType SVG\u662f\u4e00\u79cd\u5b57\u4f53\u683c\u5f0f\uff0cOpenType\u5b57\u4f53\u7684\u5168\u90e8\u6216\u90e8\u5206\u5b57\u5f62\u8868\u793a\u4e3aSVG\uff08\u53ef\u7f29\u653e\u77e2\u91cf\u56fe\u5f62\uff09\u56fe\u5f62\u3002\u8fd9\u5141\u8bb8\u5728\u4e00\u4e2a\u5b57\u5f62\u4e2d\u663e\u793a\u591a\u4e2a\u989c\u8272\u548c\u6e10\u53d8\u3002\u7531\u4e8e\u8fd9\u4e9b\u7279\u6027\uff0c\u6211\u4eec\u8fd8\u5c06OpenType SVG\u5b57\u4f53\u79f0\u4e3a\u201c\u5f69\u8272\u5b57\u4f53\u201d\u3002<\/p>\n<p>Adove\u7684EmojiOne Color\u8fd9\u4e2aEmoji\u5b57\u4f53\u5c31\u662fOpenType-SVG\u5b57\u4f53\uff0cEmojiOne Color\u662fAdobe\u4eceDenis Denz\u8bbe\u8ba1\u7684EmojiOne\u827a\u672f\u4f5c\u54c1\u4e2d\u6784\u5efa\u7684\u5f00\u6e90\u5f69\u8272\u5b57\u4f53\uff0c\u7531Rick Moby\u5236\u4f5c\u3002\u8be5\u5b57\u4f53\u5305\u542bUnicode 9.0\u4e2d\u7684\u6240\u6709\u8868\u60c5\u7b26\u53f7\uff0c\u5e76\u652f\u6301ZWJ\u3001\u80a4\u8272\u591a\u6837\u6027\u548c\u56fd\u65d7\u8868\u60c5\u7b26\u53f7\u3002\u3002<\/p>\n<p>OpenType SVG\u5b57\u4f53\u5305\u542b\u53ef\u4ee5\u50cf\u5176\u4ed6OpenType\u5b57\u4f53\u4e00\u6837\u901a\u8fc7CSS\u542f\u7528\u3002\u6709\u5173\u8bbf\u95ee\u8fd9\u4e9b\u529f\u80fd\u7684\u6982\u8ff0\uff0c\u8bf7\u53c2\u9605<a href=\"https:\/\/helpx.adobe.com\/fonts\/using\/use-open-type-features.html\" rel=\"noopener\" target=\"_blank\">\u4f7f\u7528OpenType\u529f\u80fd<\/a>\u548c<a href=\"https:\/\/helpx.adobe.com\/fonts\/using\/open-type-syntax.html\" rel=\"noopener\" target=\"_blank\">CSS\u4e2dOpenType\u529f\u80fd\u8bed\u6cd5<\/a>\u3002<\/p>\n<p>Trajan Color Concept\u662fAdobe\u7b2c\u4e00\u4e2a\u5f69\u8272\u5b57\u4f53\uff08\u6548\u679c\u89c1\u4e0b\u56fe\uff09\uff0c\u4f7f\u7528\u65b0\u7684OpenType SVG\u6807\u51c6\u6784\u5efa\uff0c\u9644\u52a0\u4e86\u8ddf\u591a\u989c\u8272\u6837\u5f0f\uff0c\u79f0\u4e3a\u6837\u5f0f\u96c6\uff0c\u7f16\u53f7\u4e3a1\u523020\uff08ss01\u3001ss02\u3001ss03\u7b49\uff09\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/2020-03-12_145135.png\" width=\"591\" height=\"397\" alt=\"Trajan Color\u5f69\u8272\u5b57\u4f53\" class=\"alignnone size-medium\" \/><\/p>\n<p>\u8981\u5c0620\u79cd\u6837\u5f0f\u4e4b\u4e00\u5e94\u7528\u4e8e\u6587\u5b57\u4e0a\uff0c\u53ef\u4ee5\u4f7f\u7528CSS\u4e2d\u7684<code>font-feature-settings<\/code>\u5c5e\u6027\u8fdb\u884c\u8bbe\u7f6e\uff0c\u4f8b\u5982\uff1a<\/p>\n<pre>.Trajan-gold { \r\n    font-family: 'Trajan Color Concept';\r\n    font-feature-settings: \"ss01\";\r\n}\r\n.Trajan-silver {\r\n    font-family: 'Trajan Color Concept';\r\n    font-feature-settings: \"ss02\";\r\n}<\/pre>\n<p>\u5728\u4e0d\u652f\u6301OpenType SVG\u5b57\u4f53\u7684\u6d4f\u89c8\u5668\u4e2d\uff0c\u5c06\u663e\u793a\u515c\u5e95\u7684\u6837\u5f0f\uff08\u4e0e\u5e8f\u53f7\u4e3a20\u7684\u6837\u5f0f\u96c6\u6548\u679c\u76f8\u540c\uff09\u3002<\/p>\n<p>\u5173\u4e8efont-feature-settings\u5c5e\u6027\uff0c\u6211\u4e4b\u524d\u6709\u4e13\u95e8\u5199\u6587\u7ae0\u8be6\u7ec6\u6574\u7406\u8fc7\u652f\u6301\u7684\u8d85\u8fc7\u534a\u767e\u7684\u5c5e\u6027\u503c\uff1a\u201c<a href=\"https:\/\/www.zhangxinxu.com\/wordpress\/2018\/12\/css-font-feature-settings-keyword-value\/\">CSS font-feature-settings 50+\u5173\u952e\u5b57\u5c5e\u6027\u503c\u5b8c\u6574\u4ecb\u7ecd<\/a>\u201d<\/p>\n<h4>\u652f\u6301OpenType-SVG\u5b57\u4f53\u7684\u5e94\u7528\u7a0b\u5e8f<\/h4>\n<ul>\n<li>Photoshop CC 2017\u53ca\u5176\u4ee5\u4e0a\u7248\u672c<\/li>\n<li>Illustrator<\/li>\n<li>Firefox 32\u53ca\u5176\u4ee5\u4e0a\u7248\u672c<\/li>\n<li>Microsoft Edge, Windows 10\u5468\u5e74\u7eaa\u5ff5\u7248\u53ca\u4ee5\u4e0a\u7248\u672c<\/li>\n<li>\u5728Windows 10\u4e2d\uff0cDirectWrite\u548cDirect2D\u5e73\u53f0\u7ec4\u4ef6\u5141\u8bb8\u5728\u4efb\u4f55\u4f7f\u7528\u8fd9\u4e9bapi\u7684\u5e94\u7528\u7a0b\u5e8f\u4e2d\u652f\u6301OpenType SVG<\/li>\n<\/ul>\n<h4>\u5df2\u77e5\u7684\u95ee\u9898<\/h4>\n<ul>\n<li>\u5728\u5bfc\u51fa\u4e3aPDF\u6216SVG\u540e\uff0c\u56fe\u793a\u7b26\u53ef\u80fd\u51fa\u73b0\u5728\u9519\u8bef\u7684\u4f4d\u7f6e\u3002<\/li>\n<li>\u5728\u5f69\u8272SVG\u5b57\u4f53\u4e0a\u5e94\u7528\u900f\u660e\u3001\u65cb\u8f6c\u6216\u53cd\u5c04\u6548\u679c\u65f6\uff0c\u6548\u679c\u53ef\u80fd\u4f1a\u4e22\u5931\uff0c\u6216\u8005\u5728\u521b\u5efa\u5b57\u5f62\u8f6e\u5ed3\u65f6\u5b57\u7b26\u53ef\u80fd\u4f1a\u79bb\u5f00\u5176\u539f\u59cb\u4f4d\u7f6e\u3002<\/li>\n<li>\u5782\u76f4\u8bbe\u7f6e\u6587\u672c\u65f6\uff0c\u5bfc\u51fa\u540e\u7684\u5b57\u7b26\u4f4d\u7f6e\u53ef\u80fd\u4f1a\u4e0d\u540c\u3002<\/li>\n<li>\u5728\u87ba\u65cb\u8def\u5f84\u653e\u7f6e\u4e0a\u8bbe\u7f6e\u6587\u672c\u65f6\uff0c\u5b57\u7b26\u53ef\u80fd\u4f1a\u663e\u793a\u4e3a\u653e\u7f6e\u4e0d\u6b63\u786e\u3002<\/li>\n<\/ul>\n<h3>\u56db\u3001\u7ed3\u8bed\u53ca\u53c2\u8003\u6587\u6863<\/h3>\n<p>\u5206\u4eab\u4e00\u5957\u5b57\u4f53\u8bbe\u7f6e\u96c6\uff0c\u9488\u5bf9\u4e0d\u540c\u7684\u5b57\u4f53\u65cf\uff0c\u886c\u7ebf\u5b57\u4f53\uff0c\u65e0\u886c\u7ebf\u5b57\u4f53\u548c\u7b49\u5bbd\u5b57\u4f53\uff1a<\/p>\n<pre>.font-sans\t{\r\n    font-family: system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, \"Helvetica Neue\", Arial, \"Noto Sans\", sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, Noto Color Emoji;\r\n}\r\n.font-serif {\r\n    font-family: Georgia, Cambria, \"Times New Roman\", Times, serif;\r\n}\r\n.font-mono {\r\n    font-family: Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace;\r\n}<\/pre>\n<p>\u5206\u522b\u9002\u5408\u7528\u5728\u6b63\u6587\u663e\u793a\u3001\u6807\u9898\u663e\u793a\u548c\u4ee3\u7801\u663e\u793a\u4e2d\u3002<\/p>\n<h4>\u53c2\u8003\u6587\u6863<\/h4>\n<ul>\n<li><a href=\"https:\/\/helpx.adobe.com\/fonts\/using\/ot-svg-color-fonts.html\" rel=\"noopener\" target=\"_blank\">OpenType-SVG color fonts<\/a><\/li>\n<li><a href=\"https:\/\/css-tricks.com\/snippets\/css\/system-font-stack\/\" rel=\"noopener\" target=\"_blank\">System Font Stack<\/a><\/li>\n<li><a href=\"https:\/\/css-tricks.com\/it-all-started-with-emoji-color-typography-on-the-web\/\" rel=\"noopener\" target=\"_blank\">It All Started With Emoji: Color Typography on the Web<\/a>\n<\/li>\n<li><a href=\"https:\/\/www.client9.com\/css-color-emoji-stack\/\" rel=\"noopener\" target=\"_blank\">CSS Color Emoji Stack<\/a><\/li>\n<\/ul>\n<p>\u6700\u540e\uff0c\u6709\u4e9bEmoji\u5b57\u7b26\u5728\u7f16\u8f91\u5668\u662f\u4e2a\u65b9\u5757\uff0c\u770b\u5f97\u8111\u58f3\u75bc\uff0c\u53ef\u4ee5\u4f7f\u7528\u6211\u505a\u7684\u8fd9\u4e2a<a href=\"https:\/\/www.zhangxinxu.com\/sp\/char.html\" rel=\"noopener\" target=\"_blank\">char\u5b57\u7b26\u8f6c\u6362\u5c0f\u5de5\u5177<\/a>\u53d8\u6210HTML\u8bc6\u522b\u7684unicode\u683c\u5f0f\u3002<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/2020-03-12_150835.png\" width=\"523\" height=\"218\" alt=\"\u5b57\u7b26\u8f6cHTML\u683c\u5f0f\" class=\"alignnone size-medium\" \/><\/p>\n<p>\u5c31\u8bf4\u8fd9\u4e48\u591a\uff0c\u5e0c\u671b\u672c\u6587\u5185\u5bb9\u53ef\u4ee5\u6700\u4f60\u7684\u5b66\u4e60\u6709\u6240\u5e2e\u52a9\u3002<\/p>\n<p>\u6b22\u8fce\u5206\u4eab\uff01<\/p>\n<p>?<\/p>\n<p>\u672c\u6587\u4e3a\u539f\u521b\u6587\u7ae0\uff0c\u6b22\u8fce\u5206\u4eab\uff0c\u52ff\u5168\u6587\u8f6c\u8f7d\uff0c\u5982\u679c\u5b9e\u5728\u559c\u6b22\uff0c\u53ef\u6536\u85cf\uff0c\u6c38\u4e0d\u8fc7\u671f\uff0c\u4e14\u4f1a\u53ca\u65f6\u66f4\u65b0\u77e5\u8bc6\u70b9\u53ca\u4fee\u6b63\u9519\u8bef\uff0c\u9605\u8bfb\u4f53\u9a8c\u4e5f\u66f4\u597d\u3002<br \/>\n\u672c\u6587\u5730\u5740\uff1a<a href=\"https:\/\/www.zhangxinxu.com\/wordpress\/?p=9306\">https:\/\/www.zhangxinxu.com\/wordpress\/?p=9306<\/a><\/p>\n<p>\uff08\u672c\u7bc7\u5b8c\uff09<\/p>\n","protected":false},"excerpt":{"rendered":"<p><img decoding=\"async\" src=\"\/\/image.zhangxinxu.com\/image\/blog\/202003\/emoji-cover.jpg\" width=\"160\" height=\"108\" alt=\"Emoji\u6587\u7ae0\u7f29\u7565\u56fe\" class=\"alignright size-medium\" loading=\"lazy\"><\/p>\n<p>\u5173\u4e8eEmoji\u5b57\u4f53\u4f60\u53ef\u80fd\u4e0d\u77e5\u9053\u7684\u4e00\u4e9b\u77e5\u8bc6\uff0c\u987a\u4fbf\u7b80\u5355\u4ecb\u7ecd\u4e86\u4e0b\u5f69\u8272\u5b57\u4f53\u6807\u51c6\u4e4b\u4e00\u7684OpenType SVG\u5b57\u4f53\u7684\u4e00\u4e9b\u77e5\u8bc6\u3002<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[1581,655,417,1109,1845,1578,1580,1579,1087],"_links":{"self":[{"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/posts\/9306"}],"collection":[{"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/comments?post=9306"}],"version-history":[{"count":0,"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/posts\/9306\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/media?parent=9306"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/categories?post=9306"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.zhangxinxu.com\/wordpress\/wp-json\/wp\/v2\/tags?post=9306"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}