w3c / jlreq

Text Layout Requirements for Japanese
https://w3c.github.io/jlreq/
Other
100 stars 16 forks source link

Proportional J text has spacing needs beyond JIS X 4051 mojikumi #296

Open macnmm opened 2 years ago

macnmm commented 2 years ago

JIS X 4051 describes conventional mojikumi tsume and aki (spacing adjustments) in terms of even fractions of 1 em, because the line box is usually exactly x em wide (c.f. kihon hanmen), and so normally monospaced Japanese text with kinsoku clusters at the line ends or line starts only cause the lines to be short by 1/2 em or 1 em. To make the cluster fit by pushing in the line end, the mojikumi aki can be removed in even fractional (e.g. 1/2 em) increments, so the rules are in place to determine which character pairs should give up their space first, etc. In the case of full-justification and line width expansion, again the amount to be distributed among the character pairs can be expressed in even fractional em units, and so the differences in width for each pair between "desired" width and "maximum" width can also fit these even em units. These rules achieve two goals: One is to make the composer's job easier and more efficient by minimizing the places where adjustment must happen and in what amounts, the other is minimal disruption to the line's normal unadjusted width for maximum legibility and aesthetics.

The issue becomes that when proportional type is introduced into the lines that necessarily create lines that are shorter than the line box width by amounts not easily divided among the 1/4 em or 1/2 em spacing around punctuation characters, or proportional punctuation glyphs whose aki space is not an even 1/2 em, you essentially have chaos in the available line width adjustments and no rules that deal with it nicely. The JIS X 4051 style of adjustment rules assume aki is always 1/2 em or 1/4 em or 1 em between punctuation and surrounding text, and has a dictated order of which aki is dealt with first, so the characters on the line return to a grid-like configuration as quickly and easily as possible. With proportional layout, the characters were never in that configuration to begin with, and so rules designed to preserve it are not suitable for such situations.

In particular, the assumptions in JIS X 4051 need to be revisited, and new rules formed.

  1. Aki amounts: not always 1/4 em or 1/2 em. Does this change priority rules at all? Does it change how adjustments should happen?
  2. Text box width in even ems: The Kihon Hanmen of a embox grid seems well-suited for monospaced typography, but the needs of modern reflowable content and digital media seem to favor a much freer use of space when combined with proportional typography. This marriage of embox-based grids, embox-sized text or line boxes, and monospaced traditional Japanese layout, with the corresponding marriage of proportional layout within an arbitrary width, should be emphasized in the next JLReq. How to reflow content dynamically in either scenario should be explicitly described. The mixed use of arbitrary text box size with monospaced text, or, more rarely, proportional layout within an even embox-sized line box, can cause layout issues, bad adjustment decisions, and make beautiful line composition more difficult.
  3. Aki contraction or expansion: Should proportional lines of type be adjusted differently or more evenly on a gradient in such cases? Now that adjustments can be done automatically in software, the prior historical considerations of efficiency in how and where adjustments are to be made by hand no longer apply.
KobayashiToshi commented 2 years ago

Now that adjustments can be done automatically in software, the prior historical considerations of efficiency in how and where adjustments are to be made by hand no longer apply.

その通りだと思います.

プロポーショナルまたは字間を詰めた(または空けた)組版は,書籍ではたまに,雑誌ではよく見かけます.この方式は,ベタ組に慣れたものにとって,あまり読みやすいとは思いませんが,今後は増えていくでしょう.以下のことはいえるかもしれません.

1 プロポーショナルまたはツメ組にすると,ベタ組に比較すると,いくらか行間のアキを小さくできる.また,文字面が一定の濃度を保つという効果はある.紙に印刷する場合では,そうしたメリットはあるが,モニタでの表示では,そうした目的は必要になるのであろうか?

2 行長の設定は,そこで使用されている文字サイズの整数倍に設定する必要はなく,適宜に設定できるし,それでよいと思われるかもしれませんが,そう簡単ではない.一定量をツメル(アケル)場合では,文字サイズの整数倍にはならないが,1行に配置する字数から行長に半端のでない行長は決まってくる.プロポーショナルの場合も,できるだけ行長に半端のでない行長はあるかもしれないが,適宜に設定できるでしょう.

3 プロポーショナルな組版を読んでいて感じることは,行の調整で字間を調整した場合,行によって文字間のアキに乱れが感じられ,あまり読みやすくはない(これは,文字組に見慣れている私だけの感じかもしれないが).ということは,いっそのこと,字間の調整を行わないという選択,つまり,“行頭・行末そろえ”を選択しないで,“行頭そろえ”を選ぶということでよい,ということにならないか.

4 仮に,プロポーショナル又はツメ組で“行頭・行末そろえ”を選択した場合,特にプロポーショナルの場合は,行長の半端は,どの行でも発生するする可能性が高く,行長の調整を行う必要が出る.文字間は詰められているので,詰める調整よりは空ける処理が主になろう.この場合,約物の字間での調整を優先すると,一定の範囲を決めるとしても,常に約物のアキが一定しない可能性がある,その意味では,比較的に字間の乱れが一般の読者には感じられない漢字及び仮名の字間だけで空ける調整を行うという方式が主になろう.

5 句読点や括弧類のアキについては,従来の方式は適用できない.そこで,すべてアキを無くし,ベタ組にする方法も考えられるが,括弧類はそれでもよいが,句読点は区切りとしての役割があるので,一定のアキがほしい.そのアキは決まったアキではなく,プロポーショナル又はツメ組の程度にもよる.プロポーショナル又はツメ組のツメぐわいにもよるので,そのアキは選択できることが望ましいでしょう.(ツメ組の場合は,約物の字間は,文字間の詰める量と揃えるというのが一般的であろう.)

kidayasuo commented 2 years ago

Something we should consider for the digital native version of JLReq. Relating to #281 .

macnmm commented 2 years ago

Something @KobayashiToshi mentioned in the JLReq meeting made me think of this: When the font designer is creating a proportional J font, and deciding the optimal spacing for punctuation (e.g. the left side of the opening full width parenthesis), some knowledge of which mojikumi class that glyph falls into, and which other glyphs will share the spacing rules with it, is necessary if the rules for proportional are to share the mojikumi classes with the traditional rules. If the same amount of space is not added to all members of a given mojikumi class, the application will likely have problems adding the wrong amount of space to glyphs that differ. Or, we establish a more fluid grouping of like glyphs with shared spacing rules, not based on the traditional mojikumi classes..?

KobayashiToshi commented 2 years ago

文字クラスは,問題にならないように思います.括弧類や句読点,中点類で前後か仮名・漢字の場合は,それぞれが保持する前又は後ろのアキを仮名・漢字との間に確保すればよい.

問題は,括弧類や句読点,中点類が連続する場合で,そろぞれの約物の前後のアキが異なる場合です.これは,文字サイズなどが異なる約物が連続した場合と同じ問題です.この処理方法を一般化すればよい.

約物が連続し,字間の調整を必要とするケースは,大きく分けると,以下の3つがある. A 句読点や括弧類(以下,句読点と括弧類を併せて括弧類等という)が連続する場合 B 中点類と括弧類等が連続する場合 C 全角スペースと括弧類等が連続する場合

BとCは,原則として,中点類や全角スペースの前後に配置される括弧類等のアキに差異があっても,これらのどちらかの後ろ又は前にあるアキを削除して配置すればよい(方法は,JIS X 4051やJLReqに記述あり)ので,文字サイズやアキ等の差異があっても問題とはならない.なお,プロポーショナルの中点類でアキがない場合も,同様に,その前後に配置される括弧類等の後ろ又は前にあるアキを削除すればよい.

問題はAである.ただし,Aは以下の4つのケース(実例が考えられるのは3つ)があるが,問題はaのケースだけである.(なお,句読点は“終わり”に含める.) a 終わりの括弧類等の後ろに,始めの括弧類等が連続 b 始めの括弧類等と,始めの括弧類等が連続 c 終わりの括弧類等と,終わりの括弧類等が連続 d 始めの括弧類等の後ろに,終わりの括弧類等が連続

dは,実例はほとんどない(あれば2つの括弧類等の字間をベタにすればよい).bとcは,前又は後ろの括弧類等のアキを削除すればよいので,文字サイズ等の差異があっても問題とはならない.

つまり,問題はAのaだけである.

以下は,Aのaに限り,その処理を考えてみる.aの場合は,前又は後ろの括弧類等との間にアキを確保する必要になり,文字サイズやアキ等に差異があった場合,そのアキの大きさが問題になる.

なお,aのアキを詰めない処理(全角アキとなる)は,bやcの処理を行わない(二分アキとなる)と比べると,いくぶん,見た目のバランスの悪さは低いと考えられる.ベタとアキのある場合の差異は誰でもが気がつくが,アキの大きさは,注意しないと気がつかないこともある.例えば,早川書房の書籍では,bやcの調整は行っている(ベタにする)が,aの調整は行わないで,全角アキを許容している.(このことからいえば,aの調整したアキの量は,ある意味,許容範囲があるので,厳密に決めなくてもよいのかもしれない.)

文字サイズや等が異なる場合のaの調整では,前後に配置する括弧類等の後ろ及び前にある括弧類等のアキ(一般に二分)を削除,その間のアキを決める必要がある.このアキを決める基準としては,以下のような方法が考えられる.(なお,プロポーショナルの括弧類等で,アキを確保しない括弧類等を含む場合は,字間の調整は行わない.両方ともにアキがない場合はベタとなり,片方にアキがない場合は,アキのある括弧類のアキをそのまま維持する.)

1 前に配置する括弧類等の文字サイズを基準とした1/2(半分)のアキ,又は,前に配置する括弧類等の約物の後ろにあるアキ(例えば三分,あるいは300/800)とする(その約物の保持しているアキ).つまり前に配置する括弧類等を基準にする.この方法は,JIS X 4051で規定している方法である(これは,書籍等で本文中に括弧書きの後ろに,文字サイズを1段階小さくした括弧書きが連続するケースが一般的であったことによるものと思われる).

2 その段落の文字サイズの1/2とする.この方法はプロポーショナルの場合は,うまくいかないかもしれない.

3 前に配置する括弧類等の約物の後ろのアキの1/2,及び後ろに配置する括弧類等の約物の後ろのアキの1/2とする.例えば,括弧類等の約物の前後のアキが二分で,前が10ポイント,後ろが12ポイントの場合は,アキは5.5ポイント.文字サイズは両方とも12ポイントであるが,片方が二分で,別の約物のアキが三分の場合は,6/2+4/2=5の計算から5ポイントとなる.両方の約物のアキの平均をとるという方法である.

4 文字サイズの大きい方又は約物のアキの大きい方を基準とする.例えば,前後のアキが二分で,前が10ポイント,後ろが12ポイントの場合は,アキは6ポイント.文字サイズは両方とも12ポイントであるが,片方の約物のアキが二分,別のが三分の場合は,アキの大きい方を基準にして,アキは6ポイント.

前述したように,aのケースのアキは,ある意味で,許容範囲があるので,1, 2, 4のいずれでもよいと考えてもよいが,3又は4が,ある種の合理性を持っていると思われる.見た目では,優先的な(つまり大きな文字サイズ)の文字のアキが確保される,ということを考えれば4ということになろう.