Code Monkey home page Code Monkey logo

fixcjk's People

Contributors

explorare avatar stecue avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fixcjk's Issues

B站首页 部分区域排版出错

浏览器:Chrome 63 (firefox57 下正常)
网址:www.bilibili.com
出错分区:番剧区、国创区

正常情况
b
排版出错(会将其他星期同个位置的字符串显示出来)
b
issues#128类似视乎与Chrome浏览器的排版引擎有关

与 B 站新版播放器不兼容

FixCJK 版本: 1.3.9
Chrome 版本: 71.0.3578.44 (正式版本) beta (64 位) (cohort: Beta)

问题: 启用 FixCJK 后,播放器一点击播放就消失不见。

Broken style for Twitter voting post

image
さいとう なおき on Twitter: "埼玉で人並みの生活をするためには月収50万円必要らしいですけど、そんな中イラストレーターさんに質問(フリーに限らず)。私の月収は...."

My script settings:

var CJKdefault = '"Source Han Serif SC",
var CJKSimSun= '"Source Han Serif SC",
var CJKserif = '"Source Han Serif SC",
var CJKsans = '"Source Han Serif SC",
var CJKBold = '"Source Han Serif SC",
var CJKPunct = 'Source Han Serif SC,SimHei,SimSun';

var LatinInSimSun = 'Source Serif Pro';
var LatinSans = '"Source Sans Pro",
var LatinSerif = '"Source Serif Pro",
var LatinMono = 'Consolas,"DejaVu Sans Mono"';

var FixRegular = true;
var FixMore = true;
var FixPunct = true; strings are adding to your editing area.

var usePaltForCJKText = true;
var usePaltForAll = true;
var useJustify = false;
var forceAutoSpaces = true;
var useBroaderSpaces = true;
var useXBroaderSpaces = false;
var use2XBroaderSpaces = false;
var use3XBroaderSpaces = false;
var scrollToFixAll = false;

Strange behavior on Firefox with skia disabled。

Environment

Windows 10 1709 16299.19
Firefox 57.0b14
FixCJK! 1.3.9 (Modified

Issue

There is a significant difference on rendering between the script is enabled or disabled, especially on some characters such as "自由“. I've set he default font to Source Han Sans SC on Firefox so they should be the same font no matter if the script is enabled. This issue came out when I was testing skia on Firefox, here are more information.

Screenshots

Script enabled
Script enabled

Script disabled
Script disabled

Conflict with "Advanced Font Settings"

原标题:FixPunct 功能失效
Chromium version: 57.0.2987.110
Script version: 1.1.52/1.2.0/1.2.3/1.2.4
Conf:

var CJKdefault = '"Source Han Sans SC"'
var CJKSimSun= '"Source Han Serif SC"'
var CJKserif = '"Source Han Serif SC"'
var CJKsans = '"Source Han Sans SC"'
var CJKBold = '"Source Han Sans SC"'
var CJKPunct = 'Noto Sans CJK SC'

var LatinInSimSun = 'Source Serif Pro'
var LatinSans = '"Source Sans Pro"'
var LatinSerif = '"Source Serif Pro"'
var LatinMono = 'Consolas'

var FixRegular = true;
var FixMore = true;
var FixPunct = true;

var usePaltForCJKText = true;
var usePaltForAll = false;
var useJustify = false;
var forceAutoSpaces = true;

image
Source: Feedly

是我配置有问题了么,突然发现 FixPunct 功能不能用了(其实最早就是为了这个功能才发现这个脚本的)。另外那个符号就是 U+2019 单引号。


刚才突然想到会不会是因为结果被 Advanced Font Settings 覆盖了,就关掉了这个插件,问题消失。同时之前反馈的 Slack/Feedly 中渲染延迟、需要双击重新渲染的问题也消失了。

关于默认字体的选择和排序

5d78aad 中添加了 Source Han Sans CN 作为 Microsoft Yahei 的 fallback,请问这个选择的理由是?我的建议是使用 Source Han Sans/Serif SC 而不是 CN,因为 Source Han Sans SC 属于 Language-specific OpenType,包含所有 65,535 个字形

This deployment configuration is available in four languages—Simplified Chinese, Traditional Chinese, Japanese,
and Korean—and sets the language as the default (a default language is required due to the single
'cmap' table), and the 'locl' (Localized Forms) GSUB feature is expected to be used to access glyphs that are
appropriate for the other three languages.

而 Source Han Sans CN 是 Region-specific Subset OpenType,只包含用来显示该地区文字所必要的字形,比如 Source Han Sans CN 就不包含日语的平假名、片假名。

This deployment configuration includes four different subsets, and each subset includes only the glyphs that
are necessary for Simplified Chinese, Traditional Chinese, Japanese, or Korean.
These fonts are considered the most broadly usable because the 'locl' GSUB feature is not required to access
the region-specific glyphs. Instead, only the glyphs that are necessary for each region are included. This deployment
configuration is recommended for users who need only the glyphs for a specific region, and also
desire the smallest possible footprint. These fonts are expected to behave the same as conventional Simplified
Chinese, Traditional Chinese, Japanese, or Korean fonts.

所以如果在一个同时存在日语和中文的页面上使用 Source Han Sans CN 会导致日语部分 fallback 到 Noto Sans CJK SC,如果环境中存在此字体就看不出区别,如果不存在又会继续 fallback。所以我认为为了维持字体效果的统一性,这里选用 Source Han Sans/Serif SC 或 Noto Sans/Serif CJK SC 更为合适。


关于字体顺序,既然有 fallback 机制,为何不把 Source Han Sans/Serif SC 和 Noto Sans/Serif CJK SC 排在 Microsoft Yahei 之前?这样搭载此字体的环境可以直接使用,没有搭载的环境也可以自动 fallback 到 Microsoft Yahei。

对于快速刷新内容的页面的支持

今天在用 Slack (一款 Web 端协作、聊天工具)时发现新出现的内容并不能及时得到渲染,而是在双击之后重新检查页面才会渲染,所以是否能自动检测页面变动来渲染变动的内容呢?

纯中文页面错误应用日文字形

image

ver. 1.3.9

    var CJKdefault = 'Source Han Sans SC,"s
    var CJKSimSun= '"Source Han Serif SC",
    var CJKserif = '"Source Han Serif SC", 
    var CJKsans = '"Source Han Sans SC","M
    var CJKBold = '"Source Han Sans SC","M 
    var CJKPunct = 'Source Han Sans SC,Not
    var KanaSerif = 'Source Han Serif SC,N
    var KanaSans = 'Source Han Sans SC,Not
    var JaSerif = 'Source Han Serif SC,Not.
    var JaSans = 'Source Han Sans SC,Noto 
    var JaDefault = CJKsans; //Default fon
    ///---Latin Fonts. Note: *DO NOT* use 
    var LatinInSimSun = 'Source Serif Pro,
    var LatinSerif = 'Source Serif Pro,"PT 
    var LatinSans = '"Source Sans Pro","Op
    var LatinMono = 'Consolas,"DejaVu Sans
    var LatinDefault = LatinSans; //The de
    ///---Choose what to fix---///
    var FixRegular = true; //Also fix regu
    var FixPunct = true; //If Latin puncti
    ///=== Experimental Options. The follo
    var usePaltForCJKText = true; //If app
    var usePaltForAll = false; //If apply 
    var useJustify = false; //Make justify
    var forceAutoSpaces = true; //if enabl
    var useBroaderSpaces = true; //Now It 
    var useXBroaderSpaces = false; //It wi
    var use2XBroaderSpaces = false; //It w
    var use3XBroaderSpaces = false; //It w
    var scrollToFixAll = false; //Scoll to
    var skipJaLang = false; //Skip lang=ja
    var unifiedCJK = true; // Use Chinese 
    var FixPureLatin = false; //Appendent s

建议增加 Homebrew 安装字体方法

对使用 Homebrew 的 macOS 用户来说只需在终端运行一下命令行即可安装字体:

brew cask install font-noto-serif-cjk-sc
brew cask install font-noto-sans-cjk-sc

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.