问题标签 [unicode-range]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
36 浏览

unicode - Find continuous range in a list of unicode code points

I have a list of unicode code points, something along these lines (not an actual set, problem illustration only):

I need to find the unicode-range for these. Some parts of this set are continuous, with some points missing - so the range is not U+050B-1EA0. Is there a sensible way of extracting those continuous "sub-ranges"?

0 投票
1 回答
442 浏览

css - 错误:CSS:unicode-range:值太多或无法识别值

我正在使用 validator.w3 进行案例研究,它向我展示了 unicode-range 的 3 个不同错误,我似乎无法弄清楚它背后的解释是什么。在 unicode 范围 U+A8E0-A8FB、U+A720-A7FF 和 U+FFFD 任何人都知道这个问题,请让我知道非常感谢!

在此处输入图像描述

0 投票
2 回答
237 浏览

font-face - W3C CSS 验证器在@font-face unicode-range 上给出错误

从几天前开始,W3C CSS 验证器开始变得更加严格,并开始在这种类型的 CSS3 实现上报错(这种类型的 CSS3 文件无处不在,例如被 Google Fonts 使用):

出现以下错误unicode-rangeToo many values or values are not recognized

显然,许多开发人员已经为他们的字体使用了具有多个值和多个范围的 unicode 范围,因为MDN 说没问题,但显然不是,因为根据 W3C 文档,for的语法unicode-range是:

也就是说,显然许多范围是不可能的。

如何解决这个问题?

这似乎是 W3C 的一种非常严格的方法,因为许多浏览器支持多个范围,并且它确实节省了带宽,因为在下载哪些字体文件时允许更大的灵活性。

0 投票
0 回答
11 浏览

unicode - 如何从此 unicode 范围中删除左右大括号标点符号?

我正在对字体进行子集化,而 Glyphhanger 蜘蛛给出了这个 unicode 范围:

现在,我想从这个范围中删除左右大括号标点符号,分别是 U+007B 和 U+007D

我试图从上述范围中省略-7BU+7D但字体几乎完全损坏。

我怎样才能正确地做到这一点?

0 投票
0 回答
11 浏览

css - 在反应应用程序中,如何设置 CSS font-face unicode-range 以包含中文字符?

在我的 create-react-app 中,我在 css 中设置了这个

汉字显示为Times New Roman,虽然unicode-range是空格(U+0020),为什么会这样?

我如何设置它以便我可以在 unicode 范围内使用中文字符的实际 unicode?