$ npm i puppeteer
added 105 packages in 14s
11 packages are looking for funding
CSS Text Module Level 4 の text-spacing-trim プロパティ が最近のブラウザ Chrome (Chromium) 123 以降で利用可能になりました。また、CSS組版ソフトVivliostyleでも以前から利用可能です。
この text-spacing-trim プロパティの機能(行頭・行末や連続する約物の詰めの制御)は、DTPソフトのInDesignの文字組みアキ量設定に近いものです。そこで文字組みアキ量設定に対応するCSSでの設定方法をまとめます。
text-spacing-trim プロパティの値は次の通り:
CSS Text Module Level 4
W3C Working Draft, 19 February 2024
- This version: https://www.w3.org/TR/2024/WD-css-text-4-20240219/
- Latest published version: https://www.w3.org/TR/css-text-4/
- Editor's Draft: https://drafts.csswg.org/css-text-4/
この文書はCSS Text Level 4を読むための参考として部分的に訳した抄訳です。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="ja"> | |
<head> | |
<meta charset="UTF-8" /> | |
<title>text-spacing-trimテスト</title> | |
<style> | |
p { | |
border: 1px solid silver; | |
text-align: justify; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="ja"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>行頭約物処理のテスト [text-spacing-trim space-first... test]</title> | |
<style> | |
@page { | |
size: A4 landscape; | |
margin: 5%; | |
スプレッドシート「EPUBリーダー表示チェック(JAGAT XMLパブリッシング準研究会)2023」 https://docs.google.com/spreadsheets/d/1xKDlL4TrMHMa1qq2QsWcXLEGMPjx-JWcTdaw_8KkftE/edit#gid=0
今回の調査で分かったことは、モダンCSSをサポートしているのはモダンブラウザエンジンを利用しているEPUBリーダーのみであるということ。そうではないEPUBリーダーでは、基本的に EPUB 3.0 で規定されていた "EPUB 3 CSS Profile" の範囲しかサポートしていない。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="ja"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>日本語の文節区切りでの行分割(word-break: auto-phrase)のテスト</title> | |
</head> | |
<body> | |
<h1>日本語の文節区切りでの行分割(word-break: auto-phrase)のテスト</h1> | |
<h2>word-break: auto-phrase</h2> |
リンク http://example.com をクリック。
リンク www.example.com をクリック。
リンクwww.example.comをクリック。
NewerOlder