我们有一份相当庞大的手工制作的连字符数据,通过 > Fonts+Scripts > Hyphenation > Import List... 从底层的 PT 项目导入到 PTXPrint 中。
我找到了一个文件,看起来就是那次导入的结果:
"D:\[path]\PT9\[project]\shared\ptxprint\hyphen-[project].tex" 这个 .tex 文件采用 UTF8 编码,我只看到 U+002D 形式的“普通”连字符。现在我想使用正则表达式来减少那些“可能但难看”的连字符选项:
我会关闭 PTXPrint,制作一个备份副本,通过删除某些连字符来应用我的更改,然后再次运行 PTXPrint,并尝试“Print”(即“Make PDF”)。这样做听起来合理吗,还是我会以这种方式破坏 PTXPrint 项目? 如果是后者,是否有更好的方法来调整连字符?
注意:我不需要关于正则表达式的帮助,谢谢。这里的问题仅涉及 PTXPrint 的内部工作原理。 简而言之: 我们将 PT 项目视为许多可能出版物的“源”,正如 PTXPrint 在线示例库中很好地展示的那样。因此,我们在 Paratext 中仔细手动维护连字符主列表,标记所有 合法选项,包括那些不太美观的选项。 对于当前的出版物,我们针对成年读者群体,并且有特定的版式、页面大小和字体大小,这给了我们“更多的自由”和灵活性。因此,我们可以过滤掉一些允许但非理想的连字符选项。例如,我想删除所有会导致行尾只留下一个字符(如“孤儿”)的选项,以及类似的行尾孤立字符情况。
We are having a substantial list of hand-crafted hyphenation data, pulled into PTXPrint from an underlying PT-project via > Fonts+Scripts > Hyphenation > Import List...
I have found a file here, that seems to be a result of that import:
"D:\[path]\PT9\[project]\shared\ptxprint\hyphen-[project].tex" This .tex file is encoded in UTF8 and I see only "normal" hyphens in form of U+002D. Now I would like to use a regex to reduce hyphenation-options which are "possible but ugly":
I would shut down PTXPrint, make a backup-copy, apply my changes by removing certain hyphens, run PTXPrint again, and attempt to "Print" aka "Make PDF". Does this sound reasonable, or will I destroy the PTXPrint-project that way? If the latter, is there a better way to tune the hyphenation?
Note: I do not need help with the regex, thank you. The question here is only about the inner workings of PTXPrint. TL/DR: We consider the PT-project as the "source" for many possible publications, as demonstrated nicely on the PTXPrint online sample gallery. So inside Paratext we carefully manually maintain the hyphenation master-list, where we mark all legal options, even the not-very-pretty ones. For the present publication we have a certain adult-readers target audience and we have a layout, page-size, font-size, which gives us "a little more freedom" and flexibility. So we can filter-out some of the allowed but not-ideal hyphenation-options. For example, I want to remove all options, which would leave only one character like a "orphan" on the end of a printed line and similar for trailing lonely characters.
机器翻译自 English 显示原文