summaryrefslogtreecommitdiff
path: root/macros/jptex
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2024-02-14 03:01:19 +0000
committerNorbert Preining <norbert@preining.info>2024-02-14 03:01:19 +0000
commita90336c3069c198b41b7b6eb76e3389610ad5eb7 (patch)
tree1d39210ab0b0caece02b2322e3fd773db8385982 /macros/jptex
parentff59efb1f42e705d74a6d50a1f8dbd7988ccf380 (diff)
CTAN sync 202402140301
Diffstat (limited to 'macros/jptex')
-rw-r--r--macros/jptex/latex/jlreq/LICENSE2
-rw-r--r--macros/jptex/latex/jlreq/README-ja.md16
-rw-r--r--macros/jptex/latex/jlreq/README.md9
-rw-r--r--macros/jptex/latex/jlreq/jfm-jlreq.lua127
-rw-r--r--macros/jptex/latex/jlreq/jlreq-helpers.sty2
-rw-r--r--macros/jptex/latex/jlreq/jlreq-ja.pdfbin377536 -> 383391 bytes
-rw-r--r--macros/jptex/latex/jlreq/jlreq-trimmarks-ja.md4
-rw-r--r--macros/jptex/latex/jlreq/jlreq-trimmarks.md4
-rw-r--r--macros/jptex/latex/jlreq/jlreq-trimmarks.sty4
-rw-r--r--macros/jptex/latex/jlreq/jlreq.cls287
-rw-r--r--macros/jptex/latex/jlreq/jlreq.pdfbin121065 -> 121523 bytes
-rw-r--r--macros/jptex/latex/jlreq/luajfm2pl.lua2
12 files changed, 237 insertions, 220 deletions
diff --git a/macros/jptex/latex/jlreq/LICENSE b/macros/jptex/latex/jlreq/LICENSE
index 3cf9a90f88..10fee31031 100644
--- a/macros/jptex/latex/jlreq/LICENSE
+++ b/macros/jptex/latex/jlreq/LICENSE
@@ -1,6 +1,6 @@
(2-clause BSD license)
jlreq and jlreq-trimmarks
-Copyright 2017-2023, Noriyuki Abe.
+Copyright 2017-2024, Noriyuki Abe.
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
diff --git a/macros/jptex/latex/jlreq/README-ja.md b/macros/jptex/latex/jlreq/README-ja.md
index 3f458194b7..6d142be200 100644
--- a/macros/jptex/latex/jlreq/README-ja.md
+++ b/macros/jptex/latex/jlreq/README-ja.md
@@ -48,7 +48,7 @@ pLaTeX / upLaTeX / LuaLaTeX上で動きます.以下のパッケージを内
`\section*[running head]{見出し文字列}[副題]`というように,通常の書式に加えて副題を受け付けられるように拡張されています.その他,`\part`(articleのみ),`\chapter`(book/reportのみ),`\subsection`,`\subsubsection`も副題を受け付けます.
### `abstract`環境
-プリアンブルにもかけるようになっています.プリアンブルに書かれた場合は,`\maketitle`とともに出力されます.二段組の場合は,段組にならず概要を出力することができます.
+プリアンブルにもかけ,そのときは`\maketitle`とともに出力されます.二段組の場合は,段組にならず概要を出力することができます.ただし今では非推奨の方法です.`\jlreqsetup`で`abstract_with_maketitle=true`を指定して`\maketitle`よりも前に書くことで同様のことができます.
### `\sidenote`
この命令は傍注の幅が正の時にのみ定義されます.デフォルトの基本版面ではこの幅は0に設定されています.従って`\sidenote`は定義されません.後の基本版面の設定を参考にしてください.
@@ -204,6 +204,8 @@ pLaTeX / upLaTeX / LuaLaTeX上で動きます.以下のパッケージを内
* `mainmatter_pagination`に`continuous`と`independent`は指定できません.
* `appendix_pagebreak`,`appendix_pagestyle`,`appendix_pagination`はありません.
+### 概要
+* `abstract_with_maketitle=[true/false]`:abstract環境が`\maketitle`に先行して書かれた場合,その中身を`\maketitle`とともに遅延します.二段組みの場合でも一段で出力されます.デフォルトは`false`です.`article`および`report`時のみ.
## 見出し
新しい見出しを`\New***Heading`という命令で作ることができます(***には見出しの種類に応じた文字列が入る).書式はすべて
@@ -340,7 +342,8 @@ pLaTeX / upLaTeX / LuaLaTeX上で動きます.以下のパッケージを内
* `nombre=<書式>`:出力するノンブルを指定します.デフォルトは`\thepage`.
* `odd_running_head=<書式>`,`even_running_head=<書式>`:それぞれ奇数ページ,偶数ページの柱を指定します.`_section`のように`_`から始まる名前を指定すると,対応する見出しを出力します.(`_section`だと現在の`\section`を出力する.)
* `mark_format={[odd=<書式>/even=<書式>/_<見出し命令名>=<書式>],...}`:見出しを柱に出力する際のフォーマットを指定します.`mark_format={_section={節\thesection:#1},_chapter={第\thechapter 章\quad #1}}`のように指定します.見出し命令名の代わりに`odd`や`even`も指定でき,それぞれ奇数ページ/偶数ページの柱の書式になります.`\pagestyle`実行時に`\sectionmark`等を定義することで実現しています.
-* `nombre_ii=<書式>`: 二つ目のノンブルを指定します.`nombre_ii_position`で場所指定,`nombre_ii_font`でフォント設定もできます.指定方法は`nombre`や`nombre_position`と同じです.`odd_running_head_ii`,`even_running_head_ii`,`running_head_ii_position`,`running_head_ii_font`もあります.`nombre_ii_position`や`running_head_ii_position`が指定されなかった場合,`yoko`指定時にはそれぞれ`nombre_position`および`running_head_position`と同じ位置に設定されます.`tate`指定時は一つ目のノンブルや柱に続く場所に表示されます.
+* `nombre_ii=<書式>`:二つ目のノンブルを指定します.`nombre_ii_position`で場所指定,`nombre_ii_font`でフォント設定もできます.指定方法は`nombre`や`nombre_position`と同じです.`odd_running_head_ii`,`even_running_head_ii`,`running_head_ii_position`,`running_head_ii_font`もあります.`nombre_ii_position`や`running_head_ii_position`が指定されなかった場合,`yoko`指定時にはそれぞれ`nombre_position`および`running_head_position`と同じ位置に設定されます.`tate`指定時は一つ目のノンブルや柱に続く場所に表示されます.
+* `odd_head_format=<書式>`, `odd_foot_format=<書式>`, `even_head_format=<書式>`, `even_foot_format=<書式>`:ヘッダやフッタのフォーマットを指定します.`#1`がヘッダまたはフッタ全体に書き換えられます.ただし`#1`には位置調整用のコードが入っている場合もあるので,特に`\NewPageStyle`に`tate`を指定している場合には思うようにならないこともあります.例えば奇数ページのヘッダに罫線を引くためには`odd_head_format={\underline{\makebox[\jlreqyokoheadlength]{#1}}}`とするとよいでしょう.なお,ここで使った`\jlreqyokoheadlength`は本クラスファイル内で定義されているマクロで,ヘッダの横方向の長さを与えます.(フッタの長さも同じです.)縦方向の長さ,すなわち`\DeclarePageStyle`で`tate`が指定されている場合の長さは`\jlreqtateheadlength`で取得できます.
`\RenewPageStyle`,`\ProvidePageStyle`,`\DeclarePageStyle`もあります.`\ModifyPageStyle`により既存のページスタイルを改変することが可能です.
@@ -576,6 +579,15 @@ JFMの名前は次の通りです.`[]`で囲まれている文字は設定に
- LuaLaTeX利用時の`everyhook'パッケージの利用をやめた(ドキュメントと整合的でなかった).
- `enumerate'環境直前の空白が入らないことがあったのを修正.
- `use_reverse_pagination`に関するバグ修正.
+* 2024-02-13
+ - LaTeXのhookシステムのために\parをいくつか挿入.
+ - `\jlreqsetup`に`tableofcontents_twocolumn`,`abstract_with_maketitle`を追加.
+ - `everyhook`の機能が呼び出されていたのを削除.
+ - jfmを少し修正.
+ - 見出し内で無限ループが出ることがあったのを修正.
+ - LuaLaTeX利用時に`stfloats`を読み込むようにした.
+ - ページスタイル内の位置調整を改善.
+ - そのほかいくつか改善など.
--------------
Noriyuki Abe
diff --git a/macros/jptex/latex/jlreq/README.md b/macros/jptex/latex/jlreq/README.md
index 5747ed263f..aba05f53b8 100644
--- a/macros/jptex/latex/jlreq/README.md
+++ b/macros/jptex/latex/jlreq/README.md
@@ -186,6 +186,15 @@ This package is distributed under the BSD 2-Clause License. See [LICENSE](LICENS
- Stopped to load `everyhook' package LuaLaTeX (it was not compatible with the document).
- Fixed a bug: a space before `enumerate' environment was not inserted sometimes.
- Fixed a bug on `use_reverse_pagination`.
+* 2024-02-13
+ - Added some `\par` (for hook system in LaTeX kernel)
+ - Added `tableofcontents_twocolumn` and `abstract_with_maketitle` to `\jlreqsetup`.
+ - Deleted `\PushPostHook`.
+ - Some modifications of jfm.
+ - Fixed a bug: heading command may have an infinite loop.
+ - Load `stfloats` with LuaLaTeX.
+ - Improved position adjustment in pagestyle.
+ - Some other improvements etc.
--------------
Noriyuki Abe
diff --git a/macros/jptex/latex/jlreq/jfm-jlreq.lua b/macros/jptex/latex/jlreq/jfm-jlreq.lua
index e2a2e0a68d..958f5f952e 100644
--- a/macros/jptex/latex/jlreq/jfm-jlreq.lua
+++ b/macros/jptex/latex/jlreq/jfm-jlreq.lua
@@ -14,41 +14,6 @@ xkanjiskipは{1,-3},kanjiskip={0,0}
local stretch_width = 0.25 -- 空き第四段階の空き量
-local hyphen_glue = {
- [1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
- [2] = {0, 0, 0, kanjiskip_natural = 1},
- [300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
- [4] = {0, 0, 0, kanjiskip_natural = 1},
- [5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
- [6] = {0, 0, 0, kanjiskip_natural = 1},
- [7] = {0, 0, 0, kanjiskip_natural = 1},
- [8] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
- [9] = {0, 0, 0, kanjiskip_natural = 1},
- [10] = {0, 0, 0, kanjiskip_natural = 1},
- [11] = {0, 0, 0, kanjiskip_natural = 1},
- [12] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
- [13] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
- [14] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
- [15] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
- [16] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
- [0] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
- [27] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
---[[
- [20] = {0, 0, 0},
- [21] = {0, 0, 0},
- [22] = {0, 0, 0},
- [23] = {0, 0, 0},
- [24] = {0, 0, 0},
- [25] = {0, 0, 0},
- [26] = {0, 0, 0},
- [28] = {0, 0, 0},
- [29] = {0, 0, 0},
- [30] = {0, 0, 0},
-]]
-}
-
local jfm = {
dir = 'yoko',
zw = 1.0,
@@ -68,8 +33,6 @@ local jfm = {
[1] = {0, 0, 0, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -110,8 +73,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 0, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0.5, 0, 0.5, ratio = 0, priority = {0,-2}, kanjiskip_natural = 1},
- [301] = {0.5, 0, 0.5, ratio = 0, priority = {0,-2}, kanjiskip_natural = 1},
- [302] = {0.5, 0, 0.5, ratio = 0, priority = {0,-2}, kanjiskip_natural = 1},
[4] = {0.5, 0, 0.5, ratio = 0, priority = {0,-2}, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -148,21 +109,52 @@ local jfm = {
chars = {'‐'},
width = 0.25,height = 0.88,depth = 0.12,
align = 'middle',
- glue = hyphen_glue,-- 上の方で定義
+ glue = {
+ [1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
+ [2] = {0, 0, 0, kanjiskip_natural = 1},
+ [300] = {0, 0, 0, kanjiskip_natural = 1},
+ [4] = {0, 0, 0, kanjiskip_natural = 1},
+ [5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
+ [6] = {0, 0, 0, kanjiskip_natural = 1},
+ [7] = {0, 0, 0, kanjiskip_natural = 1},
+ [8] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
+ [9] = {0, 0, 0, kanjiskip_natural = 1},
+ [10] = {0, 0, 0, kanjiskip_natural = 1},
+ [11] = {0, 0, 0, kanjiskip_natural = 1},
+ [12] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
+ [13] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
+ [14] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
+ [15] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
+ [16] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
+ [0] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
+ [27] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
+--[[
+ [20] = {0, 0, 0},
+ [21] = {0, 0, 0},
+ [22] = {0, 0, 0},
+ [23] = {0, 0, 0},
+ [24] = {0, 0, 0},
+ [25] = {0, 0, 0},
+ [26] = {0, 0, 0},
+ [28] = {0, 0, 0},
+ [29] = {0, 0, 0},
+ [30] = {0, 0, 0},
+]]
+ }
},
[301] = {
chars = {'゠', '–'},
width = 0.5,height = 0.88,depth = 0.12,
align = 'middle',
- glue = hyphen_glue,
+ glue = {} -- 後で処理
},
[302] = {
chars = {'〜'},
width = 1,height = 0.88,depth = 0.12,
align = 'middle',
- glue = hyphen_glue,
+ glue = {} -- 後で処理
},
[4] = { -- 区切り約物
@@ -173,8 +165,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, stretch_width, 0.25, ratio = 1, priority = {-1,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -215,8 +205,6 @@ local jfm = {
[1] = {0.25, stretch_width, 0.25, ratio = 0, priority = {-1,-1}, kanjiskip_natural = 1},
[2] = {0.25, 0, 0.25, ratio = 0, priority = {0,-1}, kanjiskip_natural = 1},
[300] = {0.25, 0, 0.25, ratio = 0, priority = {0,-1}, kanjiskip_natural = 1},
- [301] = {0.25, 0, 0.25, ratio = 0, priority = {0,-1}, kanjiskip_natural = 1},
- [302] = {0.25, 0, 0.25, ratio = 0, priority = {0,-1}, kanjiskip_natural = 1},
[4] = {0.25, 0, 0.25, ratio = 0, priority = {0,-1}, kanjiskip_natural = 1},
[5] = {0.5, 0, 0.5, ratio = 0.5, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0.25, 0, 0.25, ratio = 0, priority = {0,-1}, kanjiskip_natural = 1},
@@ -257,8 +245,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0, ratio = 0, priority = {-1,0}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0.5, 0, 0, ratio = 0, kanjiskip_natural = 1},
- [301] = {0.5, 0, 0, ratio = 0, kanjiskip_natural = 1},
- [302] = {0.5, 0, 0, ratio = 0, kanjiskip_natural = 1},
[4] = {0.5, 0, 0, ratio = 0, kanjiskip_natural = 1},
[5] = {0.75, 0, 0.25, ratio = 0.33333333, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -299,8 +285,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 0, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0.5, 0, 0.5, ratio = 0, priority = {0,-2}, kanjiskip_natural = 1},
- [301] = {0.5, 0, 0.5, ratio = 0, priority = {0,-2}, kanjiskip_natural = 1},
- [302] = {0.5, 0, 0.5, ratio = 0, priority = {0,-2}, kanjiskip_natural = 1},
[4] = {0.5, 0, 0.5, ratio = 0, priority = {0,-2}, kanjiskip_natural = 1},
[5] = {0.75, 0, 0.75, ratio = 0.33333333, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -340,8 +324,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -380,8 +362,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -420,8 +400,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -460,8 +438,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -500,8 +476,6 @@ local jfm = {
[1] = {0.5, 0, 0.5, ratio = 1, priority = {0,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -540,8 +514,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -580,8 +552,6 @@ local jfm = {
[1] = {0, stretch_width, 0, priority = {-1,0}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -620,8 +590,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -662,8 +630,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -697,10 +663,10 @@ local jfm = {
},
[161] = { -- 半角カナ
- chars = {'ヲ', 'ァ', 'ィ', 'ゥ', 'ェ', 'ォ', 'ャ', 'ュ', 'ョ', 'ッ', 'ー', 'ア', 'イ', 'ウ', 'エ', 'オ', 'カ', 'キ', 'ク', 'ケ', 'コ', 'サ', 'シ', 'ス', 'セ', 'ソ', 'タ', 'チ', 'ツ', 'テ', 'ト', 'ナ', 'ニ', 'ヌ', 'ネ', 'ノ', 'ハ', 'ヒ', 'フ', 'ヘ', 'ホ', 'マ', 'ミ', 'ム', 'メ', 'モ', 'ヤ', 'ユ', 'ヨ', 'ラ', 'リ', 'ル', 'レ', 'ロ', 'ワ', 'ン'},
+ chars = {'ヲ', 'ァ', 'ィ', 'ゥ', 'ェ', 'ォ', 'ャ', 'ュ', 'ョ', 'ッ', 'ー', 'ア', 'イ', 'ウ', 'エ', 'オ', 'カ', 'キ', 'ク', 'ケ', 'コ', 'サ', 'シ', 'ス', 'セ', 'ソ', 'タ', 'チ', 'ツ', 'テ', 'ト', 'ナ', 'ニ', 'ヌ', 'ネ', 'ノ', 'ハ', 'ヒ', 'フ', 'ヘ', 'ホ', 'マ', 'ミ', 'ム', 'メ', 'モ', 'ヤ', 'ユ', 'ヨ', 'ラ', 'リ', 'ル', 'レ', 'ロ', 'ワ', 'ン','。', '「', '」', '、', '・', '゙', '゚'},
width = 0.5, height = 0.88, depth = 0.12,
align = 'left',
- glue = {} -- あとで
+ glue = {} -- あとで処理
},
@@ -727,8 +693,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -790,8 +754,6 @@ local jfm = {
[1] = {0,5, 0, 0.5, ratio = 1, priority = {0,-2}},
[2] = {0, 0, 0},
[300] = {0, 0, 0},
- [301] = {0, 0, 0},
- [302] = {0, 0, 0},
[4] = {0, 0, 0},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}},
[6] = {0, 0, 0},
@@ -825,8 +787,6 @@ local jfm = {
[1] = {0,5, 0, 0.5, ratio = 1, priority = {0,-2}},
[2] = {0, 0, 0},
[300] = {0, 0, 0},
- [301] = {0, 0, 0},
- [302] = {0, 0, 0},
[4] = {0, 0, 0},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}},
[6] = {0, 0, 0},
@@ -860,8 +820,6 @@ local jfm = {
[1] = {0,5, 0, 0.5, ratio = 1, priority = {0,-2}},
[2] = {0, 0, 0},
[300] = {0, 0, 0},
- [301] = {0, 0, 0},
- [302] = {0, 0, 0},
[4] = {0, 0, 0},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}},
[6] = {0, 0, 0},
@@ -895,8 +853,6 @@ local jfm = {
[1] = {0,5, 0, 0.5, ratio = 1, priority = {0,-2}},
[2] = {0, 0, 0},
[300] = {0, 0, 0},
- [301] = {0, 0, 0},
- [302] = {0, 0, 0},
[4] = {0, 0, 0},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}},
[6] = {0, 0, 0},
@@ -931,8 +887,6 @@ local jfm = {
[1] = {0,5, 0, 0.5, ratio = 1, priority = {0,-2}},
[2] = {0, 0, 0},
[300] = {0, 0, 0},
- [301] = {0, 0, 0},
- [302] = {0, 0, 0},
[4] = {0, 0, 0},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}},
[6] = {0, 0, 0},
@@ -967,8 +921,6 @@ local jfm = {
[1] = {0,5, 0, 0.5, ratio = 1, priority = {0,-2}},
[2] = {0, 0, 0},
[300] = {0, 0, 0},
- [301] = {0, 0, 0},
- [302] = {0, 0, 0},
[4] = {0, 0, 0},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}},-- 注12
[6] = {0, 0, 0},
@@ -1003,8 +955,6 @@ local jfm = {
[1] = {0.5, 0, 0.5, ratio = 1},
[2] = {0, 0, 0},
[300] = {0, 0, 0},
- [301] = {0, 0, 0},
- [302] = {0, 0, 0},
[4] = {0, 0, 0},
[5] = {0.25, 0, 0.25, ratio = 1},
[6] = {0, 0, 0},
@@ -1038,8 +988,6 @@ local jfm = {
[1] = {0.5, stretch_width, 0.5, ratio = 1, priority = {-1,-2}, kanjiskip_natural = 1},
[2] = {0, 0, 0, kanjiskip_natural = 1},
[300] = {0, 0, 0, kanjiskip_natural = 1},
- [301] = {0, 0, 0, kanjiskip_natural = 1},
- [302] = {0, 0, 0, kanjiskip_natural = 1},
[4] = {0, 0, 0, kanjiskip_natural = 1},
[5] = {0.25, 0, 0.25, ratio = 1, priority = {0,-1}, kanjiskip_natural = 1},
[6] = {0, 0, 0, kanjiskip_natural = 1},
@@ -1238,6 +1186,7 @@ copy_jfm(0,191)
copy_jfm(0,192)
copy_jfm(0,193)
copy_jfm(16,161)
-
+copy_jfm(300,301)
+copy_jfm(300,302)
luatexja.jfont.define_jfm(jfm)
diff --git a/macros/jptex/latex/jlreq/jlreq-helpers.sty b/macros/jptex/latex/jlreq/jlreq-helpers.sty
index 76af5d797a..0980d4e397 100644
--- a/macros/jptex/latex/jlreq/jlreq-helpers.sty
+++ b/macros/jptex/latex/jlreq/jlreq-helpers.sty
@@ -1,7 +1,7 @@
% エンジン非依存のマクロ集
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{jlreq-helpers}[2023/06/19 jlreq-helpers]
+\ProvidesPackage{jlreq-helpers}[2024/02/13 jlreq-helpers]
\ExplSyntaxOn
%. helper1
diff --git a/macros/jptex/latex/jlreq/jlreq-ja.pdf b/macros/jptex/latex/jlreq/jlreq-ja.pdf
index 98e0e76019..9cc052ddff 100644
--- a/macros/jptex/latex/jlreq/jlreq-ja.pdf
+++ b/macros/jptex/latex/jlreq/jlreq-ja.pdf
Binary files differ
diff --git a/macros/jptex/latex/jlreq/jlreq-trimmarks-ja.md b/macros/jptex/latex/jlreq/jlreq-trimmarks-ja.md
index 7524828894..683ba23928 100644
--- a/macros/jptex/latex/jlreq/jlreq-trimmarks-ja.md
+++ b/macros/jptex/latex/jlreq/jlreq-trimmarks-ja.md
@@ -41,7 +41,7 @@ dviドライバの指定です.エンジンに`lualatex`を利用する場合
### `trimmarks_paper`
トンボ付きの紙サイズを指定します.
-* `trimmarks_paper=a4`のように,`a0--a10`, `b0--b10`, `c2--c8`(BはJIS B列)を指定できる他,`trimmarks_paper={<width>,<height>}`と直接寸法を指定することができます.
+* `trimmarks_paper=a4paper`のように,`a0paper--a10paper`, `b0paper--b10paper`, `c2paper--c8paper`を指定できる他,`trimmarks_paper={<width>,<height>}`と直接寸法を指定することができます.B列はISO B列です.JIS B列を指定する場合は`b0j--b10j`を指定してください.
* `a4+{1cm,2cm}`や`{10cm,20cm}+{1cm,2cm}`のように`<紙サイズ>+{<寸法横>,<寸法縦>}`とした場合は,指定された紙サイズから指定された寸法だけ増やした紙サイズを設定します.
* `a4+2cm`は`a4+{2cm,2cm}`と等価です.
* `+2cm`と紙サイズの部分を省略すると,現在の紙サイズを利用します.
@@ -189,6 +189,8 @@ dviドライバの指定です.エンジンに`lualatex`を利用する場合
- `trimmarks_pattern`を`\jlreqtrimmarkssetup`に追加.
* 2023-06-19
- 縦書きで読み込み時にエラーが出るバグ修正.
+* 2024-02-13
+ - ドキュメントの間違いを修正.
--------------
Noriyuki Abe
diff --git a/macros/jptex/latex/jlreq/jlreq-trimmarks.md b/macros/jptex/latex/jlreq/jlreq-trimmarks.md
index 315b400311..724969599b 100644
--- a/macros/jptex/latex/jlreq/jlreq-trimmarks.md
+++ b/macros/jptex/latex/jlreq/jlreq-trimmarks.md
@@ -39,7 +39,7 @@ Set the dvi driver. You do not have to specify it when using the engine `lualate
### `trimmarks_paper`
Set the size of the paper including trim marks.
-* `trimmarks_paper=<paper type>`: specify via the paper type. for the paper type, you can use `a0--a10`, `b0--b10` and `c2--c8`. Note that `b0--b10` is `JIS B' (Japanese B-series variant).
+* `trimmarks_paper=<paper type>`: specify via the paper type. For the paper type, you can use `a0paper--a10paper`, `b0paper--b10paper` and `c2paper--c8paper`. Note that `b0--b10` is ISO B. If you wan to specify JIS B (Japanese B-series variant), use `b0j--b10j`.
* `trimmarks_paper={<width>,height>}`: specify via the width and height.
* `trimmarks_paper=<paper size>+{<width>,<height>}` (e.g. `trimmarks_paper=a4+{1cm,2cm}`): `<width>` (resp. `<height>`) is added to the width (resp. height) of the paper size specified by `<paper size>` For `<paper size>`, one can use `<paper type>` or `{<width>,<height>}` as in the above.
* `trimmarks_paper=a4+2cm` is equivalent to `trimmarks_paper=a4+{2cm,2cm}`.
@@ -183,6 +183,8 @@ This package is distributed under the BSD 2-Clause License. See [LICENSE](LICENS
- Added `trimmarks_pattern` to `\jlreqtrimmarkssetup`.
* 2023-06-19
- Fixed a bug: an error occurred when the package is loaded with tate mode.
+* 2023-02-13
+ - Fixed a bug in a document.
--------------
Noriyuki Abe
diff --git a/macros/jptex/latex/jlreq/jlreq-trimmarks.sty b/macros/jptex/latex/jlreq/jlreq-trimmarks.sty
index 36f95d6805..ec65cabae9 100644
--- a/macros/jptex/latex/jlreq/jlreq-trimmarks.sty
+++ b/macros/jptex/latex/jlreq/jlreq-trimmarks.sty
@@ -1,7 +1,7 @@
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{jlreq-trimmarks}[2023/06/19 jlreq-trimmarks]
+\ProvidesPackage{jlreq-trimmarks}[2024/02/13 jlreq-trimmarks]
\RequirePackage{l3keys2e}
-\RequirePackage{jlreq-helpers}[2023/06/19]
+\RequirePackage{jlreq-helpers}[2024/02/13]
\ExplSyntaxOn
% check \tombowdatetrue
diff --git a/macros/jptex/latex/jlreq/jlreq.cls b/macros/jptex/latex/jlreq/jlreq.cls
index 1d0d498877..b285102585 100644
--- a/macros/jptex/latex/jlreq/jlreq.cls
+++ b/macros/jptex/latex/jlreq/jlreq.cls
@@ -5,10 +5,10 @@
%%
% (based on JLReq 20200811 https://www.w3.org/TR/2020/NOTE-jlreq-20200811/)
\NeedsTeXFormat{LaTeX2e}
-\ProvidesClass{jlreq}[2023/06/19 jlreq]
+\ProvidesClass{jlreq}[2024/02/13 jlreq]
\RequirePackage{l3keys2e}
\RequirePackage{etoolbox}
-\RequirePackage{jlreq-helpers}[2023/06/19]
+\RequirePackage{jlreq-helpers}[2024/02/13]
\ExplSyntaxOn
\int_new:N \l__jlreq_tmpa_int
@@ -57,9 +57,9 @@
}
% preambleにいるかのスイッチ
-\newif\ifjlreq@preamble
-\jlreq@preambletrue
-\AtBeginDocument{\jlreq@preamblefalse}
+\bool_new:N \g__jlreq_inpreamble_bool
+\bool_gset_true:N \g__jlreq_inpreamble_bool
+\AtBeginDocument{ \bool_gset_false:N \g__jlreq_inpreamble_bool }
\def\jlreq@saveoriginalcs#1{%
\@ifundefined{#1}{
@@ -482,6 +482,7 @@
% http://oku.edu.mie-u.ac.jp/tex/mod/forum/discuss.php?d=1508&parent=8435
\if@tate\AtEndPreamble{\par}\fi
\fi
+% \zwや\zhが再定義されても動くようにするために内部では\jlreq@zw,\jlreq@zhを使う.
\let\jlreq@zw=\zw
\let\jlreq@zh=\zh
\if@tate
@@ -529,8 +530,8 @@
% 組方向を判定
% \jlreq@if(y|t)(dir|box)を定義する.
\jlreq@if{\ifx l\jlreq@engine\fi}{
- \def\jlreq@ifydir { \int_compare:nTF { \ltjgetparameter{direction} == 4 } }
- \def\jlreq@iftdir { \int_compare:nTF { (\ltjgetparameter{direction}-(\ltjgetparameter{direction}/8)*8) == 3 } }
+ \def\jlreq@ifydir { \int_compare:nTF { \ltjgetparameter{direction} == 4 } }
+ \def\jlreq@iftdir { \int_compare:nTF { (\ltjgetparameter{direction}-(\ltjgetparameter{direction}/8)*8) == 3 } }
\def\jlreq@ifybox#1{ \int_compare:nTF { \ltjgetparameter{boxdir}{#1} == 4 } }
\def\jlreq@iftbox#1{ \int_compare:nTF { (\ltjgetparameter{boxdir}{#1}-(\ltjgetparameter{boxdir}{#1}/8)*8) == 3 } }
}{
@@ -808,37 +809,14 @@
\edef\jlreq@jafontscale{\strip@pt\jlreq@resultdimen}
\__jlreq_aftercls_addtodeletecs:N \jlreq@jafontscale
\ifx l\jlreq@engine
- \jlreq@saveoriginalcs{DeclareFontShape@}
- \def\DeclareFontShape@#1#2#3#4#5#6{
- \group_begin:
- \bool_if:nT { \str_if_eq_p:nn {#1} {JY3} || \str_if_eq_p:nn {#1} {JT3} } {
- \tl_set:Nx \l__jlreq_tmpa_tl {#5}
- \tl_if_in:NnTF \l__jlreq_tmpa_tl { jfm=jlreq } {
- \tl_if_in:NnTF \l__jlreq_tmpa_tl { jfm=jlreqv }{
- \tl_replace_all:Nnn \l__jlreq_tmpa_tl { jfm=jlreqv } { jfm=jlreqv-jidori }
- }{
- \tl_replace_all:Nnn \l__jlreq_tmpa_tl { jfm=jlreq } { jfm=jlreq-jidori }
- }
- \cs_set:Nx \l_jlreq_do: {
- \exp_not:N \jlreq@useoriginalcs{DeclareFontShape@}
- \exp_not:n { {#1} {#2} {#3} { #4-jidori } }
- { \tl_use:N \l__jlreq_tmpa_tl } { \exp_not:n {#6} }
- }
- }{
- \tl_if_in:NnT \l__jlreq_tmpa_tl {<->ssub} {
- \cs_set:Nn \l_jlreq_do: {
- \jlreq@useoriginalcs{DeclareFontShape@} {#1} {#2} {#3} { #4-jidori } {#5} {#6}
- }
- }
- }
- }
- \exp_after:wN \group_end: \l_jlreq_do:
- \jlreq@useoriginalcs{DeclareFontShape@} {#1} {#2} {#3} {#4} {#5} {#6}
- }
- \DeclareFontShape{JY3}{mc}{m}{n}{<->s*[\jlreq@jafontscale]\ltj@stdmcfont :jfm=jlreq;script=latn;-kern}{}
- \DeclareFontShape{JY3}{gt}{m}{n}{<->s*[\jlreq@jafontscale]\ltj@stdgtfont :jfm=jlreq;script=latn;-kern}{}
- \DeclareFontShape{JT3}{mc}{m}{n}{<->s*[\jlreq@jafontscale]\ltj@stdmcfont :jfm=jlreqv;script=latn;-kern}{}
- \DeclareFontShape{JT3}{gt}{m}{n}{<->s*[\jlreq@jafontscale]\ltj@stdgtfont :jfm=jlreqv;script=latn;-kern}{}
+ \DeclareFontShape{JY3}{mc}{m}{n}{<->s*[\jlreq@jafontscale]\ltj@stdmcfont :jfm=jlreq;-kern}{}
+ \DeclareFontShape{JY3}{gt}{m}{n}{<->s*[\jlreq@jafontscale]\ltj@stdgtfont :jfm=jlreq;-kern}{}
+ \DeclareFontShape{JT3}{mc}{m}{n}{<->s*[\jlreq@jafontscale]\ltj@stdmcfont :jfm=jlreqv;-kern}{}
+ \DeclareFontShape{JT3}{gt}{m}{n}{<->s*[\jlreq@jafontscale]\ltj@stdgtfont :jfm=jlreqv;-kern}{}
+ \DeclareFontShape{JY3}{mc}{m}{n-jidori}{<->s*[\jlreq@jafontscale]\ltj@stdmcfont :jfm=jlreq-jidori;-kern}{}
+ \DeclareFontShape{JY3}{gt}{m}{n-jidori}{<->s*[\jlreq@jafontscale]\ltj@stdgtfont :jfm=jlreq-jidori;-kern}{}
+ \DeclareFontShape{JT3}{mc}{m}{n-jidori}{<->s*[\jlreq@jafontscale]\ltj@stdmcfont :jfm=jlreqv-jidori;-kern}{}
+ \DeclareFontShape{JT3}{gt}{m}{n-jidori}{<->s*[\jlreq@jafontscale]\ltj@stdgtfont :jfm=jlreqv-jidori;-kern}{}
\else
\DeclareFontShape{\jlreq@yokokanjiencoding}{mc}{m}{n}{<->s*[\jlreq@jafontscale]\jlreq@jfmname}{}
\DeclareFontShape{\jlreq@yokokanjiencoding}{gt}{m}{n}{<->s*[\jlreq@jafontscale]\jlreq@jfmnameg}{}
@@ -856,14 +834,17 @@
\clist_map_inline:nn { m,b,bx,sb,c } {% ####1 = series
\bool_if:nF { \str_if_eq_p:nn {##1} {n} && \str_if_eq_p:nn {####1} {m} } {
\DeclareFontShape{#1}{gt}{####1}{##1}{<->ssub*gt/m/n}{}
+ \DeclareFontShape{#1}{gt}{####1}{##1-jidori}{<->ssub*gt/m/n-jidori}{}
}
}
\clist_map_inline:nn { bx,b,sb } {% ####1 = series
\DeclareFontShape{#1}{mc}{####1}{##1}{<->ssub*gt/m/n}{}
+ \DeclareFontShape{#1}{mc}{####1}{##1-jidori}{<->ssub*gt/m/n-jidori}{}
}
\clist_map_inline:nn { m,c } {% ####1 = series
\bool_if:nF { \str_if_eq_p:nn {##1} {n} && \str_if_eq_p:nn {####1} {m} } {
\DeclareFontShape{#1}{mc}{####1}{##1}{<->ssub*mc/m/n}{}
+ \DeclareFontShape{#1}{mc}{####1}{##1-jidori}{<->ssub*mc/m/n-jidori}{}
}
}
}
@@ -1778,7 +1759,7 @@
\keys_set:nn { DeclareTobiraHeading:#1 } {#3}
\def\jlreq@do{}%
\ifx\jlreq@format\@undefined
- \def\jlreq@format##1##2{##1##2}%
+ \long\def\jlreq@format##1##2{##1##2}%
\fi
\edef\jlreq@formatwlabel{\noexpand\jlreq@format{\exp_not:o {\jlreq@label@format}}}%
\jlreq@heading@make@l@{#1}{#2}{\jlreq@label@format}%
@@ -2082,6 +2063,7 @@
\jlreq@ifempty{#2}{}{\unexpanded{\hsize=\dimexpr\hsize - #2\relax}}%
\jlreq@ifempty{#3}{}{\unexpanded{\hsize=\dimexpr\hsize - #3\relax}}%
\unexpanded{#4}%
+ \noexpand\par
}%
}%
}
@@ -2129,7 +2111,7 @@
% {1 = 前空き}{2 = 後ろ空き}{3 = トータル行数}{4 = 出力}
% 最後には\nobreak(と\vskip)が入っている
\long\def\jlreq@BlockHeading@start@gyodori#1#2#3#4{\par{%
- \setbox\jlreq@tempboxa=\vbox{#4}%
+ \setbox\jlreq@tempboxa=\vbox{#4\par}%
% \jlreq@tempskip(a/b)に前/後ろに入れるべき値を入れる
% #1がa:ならばその値は\jlreq@tempskipaには足さず\jlreq@tempskipcに入れておく
\jlreq@tempskipa=0pt
@@ -2226,8 +2208,8 @@
}%
\expandafter}\jlreq@do
}
-\cs_set:Nn \g__jlreq_gyodori_hook_par: {}
-\PushPostHook{par}{\g__jlreq_gyodori_hook_par:}
+%\cs_set:Nn \g__jlreq_gyodori_hook_par: {}
+%\PushPostHook{par}{\g__jlreq_gyodori_hook_par:}
% 行取り情報をゲットだぜ
@@ -2455,7 +2437,7 @@
\exp_not:o {\jlreq@heading@text@format}%
}%
% 副題:ラベルありかなしかはhangindentの扱いだけなので,他はまとめる
- \def\jlreq@make@subtitle@format##1##2{%
+ \long\def\jlreq@make@subtitle@format##1##2{%
\edef##1{%
\ifjlreq@subtitle@break
\noexpand\par
@@ -2838,7 +2820,7 @@
\jlreq@do
}
% #2: デフォルト値を使うならば*,#3#4#5が設定された値,#6#7#8がデフォルト値,#9は偶数ページの
-\def\jlreq@BlockHeading@spaces@output@@@@#1#2#3#4#5#6#7#8#9{%
+\long\def\jlreq@BlockHeading@spaces@output@@@@#1#2#3#4#5#6#7#8#9{%
\edef\jlreq@tempa{%
\unexpanded{\long\def\jlreq@tempa##1}{\exp_args:Nc \exp_not:o {jlreq@BlockHeading@spaces@current@format@\the\jlreq@tempcnta}}%
}%
@@ -2910,10 +2892,10 @@
\begingroup
\def\jlreq@do{\@nobreakfalse\global\@noskipsectrue}%
\ifnum0\jlreq@ifempty{#3}{}{1}\ifnum #2>\c@secnumdepth 1\fi>0
- \def\jlreq@tempa##1{#8}%
+ \long\def\jlreq@tempa##1{#8}%
\else
\tl_put_right:Nn \jlreq@do {\refstepcounter{#1}}%
- \def\jlreq@tempa##1{#7}%
+ \long\def\jlreq@tempa##1{#7}%
\fi
\par}%
\unexpanded{\tl_put_right:Nx \jlreq@do}{%
@@ -3366,6 +3348,7 @@
\ifx l\jlreq@engine
\fnfixbottomtrue
+ \IfFileExists{stfloats.sty}{\RequirePackage{stfloats}\fnbelowfloat}{}
\fi
% \footnoteと\footnotemarkの前後に\jlreq@hook@prenote/\jlreq@hook@postnoteを入れる
@@ -3377,7 +3360,7 @@
\def\footnote{%
\jlreq@footnote{\footnote}{\footnotemark}{\jlreq@footnotetext@for@footnote}%
}
-\def\jlreq@footnote#1#2#3{%
+\long\def\jlreq@footnote#1#2#3{%
\jlreq@hook@prenote
\@ifnextchar[{\jlreq@footnote@impl@woption{#1}{#2}{#3}}{\jlreq@footnote@impl@wooption{#1}{#2}{#3}}%
}
@@ -3602,6 +3585,8 @@
\long\def\jlreq@output@endnotes#1#2{%
\expandafter\def\csname\jlreq@endnotemarkname\endcsname{#1}%
\item\@makeendtext{#2}%
+ % グルーピングした方がよいか? https://okumuralab.org/tex/mod/forum/discuss.php?d=3669
+ % \item\leavevmode {\@makeendtext{#2}}%
}
\newcommand*{\theendnotes}{%
@@ -4009,7 +3994,7 @@
% * それ以降はX
% として整形した際に,#5行以内に収まる.
% \jlreq@resultboxに整形結果を返す(垂直ボックス).見つからなかったらvoid.\globalに設定する.
-\def\jlreq@inlinenote@determinelength#1#2#3#4#5#6#7{%
+\long\def\jlreq@inlinenote@determinelength#1#2#3#4#5#6#7{%
\begingroup
% \message{#1 の試行開始,行数 = #5, \the\dimexpr#6\relax から \the\dimexpr#7\relaxまで}%
\@tempcnta=1\relax
@@ -4200,7 +4185,7 @@
}
}
-\cs_generate_variant:Nn \__jlreq_pagestyle_applyformat:NnNN { NocN }
+\cs_generate_variant:Nn \__jlreq_pagestyle_applyformat:NnNN { NocN, NoNN }
% mark系の処理をする.
% #2: 奇数ページ柱(prop,{0,1,2}->柱の中身)
@@ -4347,9 +4332,7 @@
\tl_set:Nx \l__jlreq_tmpb_tl { \exp_args:No \exp_not:n {\use_ii:nn ##1} } % 中身
\tl_put_right:Nx \l__jlreq_result_tl {
\exp_not:N \hbox to~0pt {
- \exp_not:n {\hskip\glueexpr\headsep + \headheight}
- \legacy_if:nF { @tate } { \exp_not:n {+ \topskip - \Cht} }
- \tl_if_empty:oF \l__jlreq_tmpa_tl { + \exp_not:o \l__jlreq_tmpa_tl } \exp_not:N \relax
+ \tl_if_empty:oF \l__jlreq_tmpa_tl { \exp_not:n { \hskip\dimexpr } \exp_not:o \l__jlreq_tmpa_tl \exp_not:N \relax }
\exp_not:o \l__jlreq_tmpb_tl
\exp_not:N \hss
}
@@ -4586,51 +4569,52 @@
%#3: 左
%#4: 真ん中
%#5: 右
+% #6: フォーマット,#7: デフォルトフォーマット
% #1に返す.
-\cs_set:Nn \__jlreq_pagestyle_concat_left_center_right:Nnnnn {
+\cs_set:Nn \__jlreq_pagestyle_concat_left_center_right:NnnnnNN {
\str_if_eq:nnTF {#2} {odd} {
- \__jlreq_pagestyle_concat_left_center_right_aux:Nnnn #1 {#3} {#4} {#5}
+ \__jlreq_pagestyle_concat_left_center_right_aux:NnnnNN #1 {#3} {#4} {#5} #6 #7
}{
% evenでは左右入れ替え
- \__jlreq_pagestyle_concat_left_center_right_aux:Nnnn #1 {#5} {#4} {#3}
+ \__jlreq_pagestyle_concat_left_center_right_aux:NnnnNN #1 {#5} {#4} {#3} #6 #7
}
}
-\cs_generate_variant:Nn \__jlreq_pagestyle_concat_left_center_right:Nnnnn { Nneee }
+\cs_generate_variant:Nn \__jlreq_pagestyle_concat_left_center_right:NnnnnNN { NneeecN }
% #2: 左,#3: 真ん中,#4: 右をくっつける
+% #5: フォーマット,#6: デフォルトフォーマット
% #1に返す
-\cs_set:Nn \__jlreq_pagestyle_concat_left_center_right_aux:Nnnn {
+\cs_set:Nn \__jlreq_pagestyle_concat_left_center_right_aux:NnnnNN {
\group_begin:
- \tl_set:Nn \l__jlreq_tmpa_tl {} % 左
- \tl_set:Nn \l__jlreq_tmpb_tl {} % 右
- \tl_set:Nn \l__jlreq_tmpc_tl {} % 戻り値
+ % \l__jlreq_tmpa_tlにくっつけたモノを入れる
+ \tl_if_empty:nTF {#3} {
+ \bool_if:nF { \tl_if_empty_p:n {#2} && \tl_if_empty_p:n {#4} } {
+ \tl_set:Nn \l__jlreq_tmpa_tl { #2 \hfill #4 }
+ }
+ }{
+ % 真ん中のを完全に真ん中に配置するために左右の幅を0にしておく
+ \tl_set:Nx \l__jlreq_tmpa_tl {
+ \tl_if_empty:nF { #2 } { \exp_not:n { \hbox to~0pt { #2 \hss } } }
+ \exp_not:N \hfill \exp_not:n {#3} \exp_not:N \hfill
+ \tl_if_empty:nF { #4 } { \exp_not:n { \hbox to~0pt { \hss #4 } } }
+ }
+ }
+ % \l__jlreq_tmpa_tlにフォーマットを適用し\l__jlreq_tmpa_tlに代入
+ \__jlreq_pagestyle_applyformat:NoNN \l__jlreq_tmpa_tl \l__jlreq_tmpa_tl #5 #6
+ % 横方向の調整
\tl_if_empty:nF {#2} {
\bool_if:nT { ( !\dim_compare_p:nNn {\jlreq@headfoot@sidemargin}={0pt} ) || \legacy_if_p:n {@tate} }{
- \tl_set:Nx \l__jlreq_tmpa_tl { \exp_not:n {\hskip\dimexpr} \jlreq@expand@speciallength{\jlreq@headfoot@sidemargin} \legacy_if:nT { @tate } { \exp_not:n { -\Cdp } } \exp_not:N \relax }
+ \tl_put_left:Nx \l__jlreq_tmpa_tl { \exp_not:n {\hskip\dimexpr} \jlreq@expand@speciallength{\jlreq@headfoot@sidemargin} \legacy_if:nT { @tate } { \exp_not:n { -\Cdp } } \exp_not:N \relax }
}
- \tl_put_right:Nn \l__jlreq_tmpa_tl {#2}
}
\tl_if_empty:nF {#4} {
- \tl_set:Nn \l__jlreq_tmpb_tl {#4}
% \jlreq@headfoot@sidemargin = 0ptの時に本文の右に一致させるための補正.
\bool_if:nT { ( !\dim_compare_p:nNn {\jlreq@headfoot@sidemargin}={0pt} ) || \legacy_if_p:n {@tate} }{
- \tl_put_right:Nx \l__jlreq_tmpb_tl { \exp_not:n {\hskip\dimexpr} \jlreq@expand@speciallength{\jlreq@headfoot@sidemargin} \legacy_if:nT { @tate } { \exp_not:n { + \topskip - \Cht } } \exp_not:N \relax }
+ \tl_put_right:Nx \l__jlreq_tmpa_tl { \exp_not:n {\hskip\dimexpr} \jlreq@expand@speciallength{\jlreq@headfoot@sidemargin} \legacy_if:nT { @tate } { \exp_not:n { + \topskip - \Cht } } \exp_not:N \relax }
}
}
- \tl_if_empty:nTF {#3} {
- \bool_if:nF { \tl_if_empty_p:n {#2} && \tl_if_empty_p:n {#4} } {
- \tl_set:Nx \l__jlreq_tmpc_tl { \exp_not:o \l__jlreq_tmpa_tl \exp_not:N \hfil \exp_not:o \l__jlreq_tmpb_tl }
- }
- }{
- % 真ん中のを完全に真ん中に配置するために左右の幅を0にしておく
- \tl_if_empty:nF { #2 } { \tl_set:Nx \l__jlreq_tmpa_tl { \exp_not:N \hbox to~0pt { \exp_not:o { \l__jlreq_tmpa_tl } \exp_not:N \hss } } }
- \tl_if_empty:nF { #4 } { \tl_set:Nx \l__jlreq_tmpb_tl { \exp_not:N \hbox to~0pt { \exp_not:N \hss \exp_not:o { \l__jlreq_tmpb_tl } } } }
- \tl_set:Nx \l__jlreq_tmpc_tl {
- \exp_not:o \l__jlreq_tmpa_tl\exp_not:N \hfil \exp_not:n {#3} \exp_not:N \hfil \exp_not:o \l__jlreq_tmpb_tl
- }
- }
- \tl_set:Nx \l__jlreq_do_tl { \exp_not:n {\tl_set:Nn #1 } { \exp_not:o \l__jlreq_tmpc_tl } }
+ \tl_set:Nx \l__jlreq_do_tl { \exp_not:n {\tl_set:Nn #1 } { \exp_not:o \l__jlreq_tmpa_tl } }
\exp_after:wN \group_end:
\l__jlreq_do_tl
}
@@ -4885,16 +4869,24 @@
% ノンブル→\l__jlreq_tmpb_tl
\__jlreq_pagestyle_maketate_nombre:NNNNo \l__jlreq_tmpb_tl \l__jlreq_pagestyle_nombre_prop \l__jlreq_pagestyle_nombre_font_prop \l__jlreq_pagestyle_nombre_position_prop \l__jlreq_pagestyle_nombre_gap_tl
% 柱とノンブルを結合→\l__jlreq_tmpa_tl
- \tl_set:Nx \l__jlreq_tmpa_tl { \exp_not:o \l__jlreq_tmpa_tl \exp_not:N \hfil \exp_not:o \l__jlreq_tmpb_tl }
+ \tl_set:Nx \l__jlreq_tmpa_tl { \exp_not:o \l__jlreq_tmpa_tl \exp_not:N \hfill \exp_not:o \l__jlreq_tmpb_tl }
% formatを適用.
\tl_set:Nn \l__jlreq_tmpb_tl {####1} % デフォルトフォーマット
\__jlreq_pagestyle_applyformat:NocN \l__jlreq_tmpa_tl \l__jlreq_tmpa_tl { l__jlreq_pagestyle_##1_top_format_tl } \l__jlreq_tmpb_tl
% 周りのボックスをつける.結果は\l__jlreq_tmpa_propにいれる.
+ % \topskip > 最初のボックスの高さを仮定する.
\prop_put:Nnx \l__jlreq_tmpa_prop { ##1-top } {
\exp_not:n {\setbox\@tempboxa=\hbox to \dimexpr\headsep + \headheight + \textheight}
- \legacy_if:nF { @tate } { \exp_not:n { - \topskip + 1\jlreq@zh } }
+ \legacy_if:nF { @tate } { \exp_not:n { + \Cdp } }
\exp_not:N \relax
- { \exp_not:n { \tate\adjustbaseline } \exp_not:o \l__jlreq_tmpa_tl }
+ { \exp_not:n { \tate\adjustbaseline \hskip \dimexpr \headsep + \headheight }
+ \legacy_if:nF { @tate } { \exp_not:n { + \topskip - \Cht } }
+ \exp_not:N \relax
+ \hbox to \legacy_if:nF { @tate } { \exp_not:N \dimexpr }
+ \textheight
+ \legacy_if:nF { @tate } { \exp_not:n { - \topskip + 1\jlreq@zh \relax } }
+ { \exp_not:o \l__jlreq_tmpa_tl }
+ }
% Underful対策
\ifx l\jlreq@engine
\unexpanded{\wd\@tempboxa=\headheight}%
@@ -4905,13 +4897,17 @@
}
% 位置調整,左側に柱+ノンブルがある場合
\tl_set:Nx \l__jlreq_tmpa_tl {
- \exp_not:n { \hskip\dimexpr } \legacy_if:nT { @tate } { \exp_not:n { - \Cdp } } \exp_not:n { - \headsep - 1\jlreq@zw\relax }
- \exp_not:n { \box\@tempboxa\hfil }
+ \exp_not:n { \hskip\dimexpr - \headsep - 1\jlreq@zw }
+ \legacy_if:nTF { @tate } { \exp_not:n { - \Cdp } }
+ { \dim_compare:nNnF { \jlreq@sidenote@length + \jlreq@sidenote@sep } {=} { 0pt } { - \the\dimexpr\jlreq@sidenote@length + \jlreq@sidenote@sep\relax } }
+ \exp_not:n { \relax\box\@tempboxa\hfill }
}
% 位置調整,右側に柱+ノンブルがある場合
\tl_set:Nx \l__jlreq_tmpb_tl {
- \exp_not:n { \hskip\dimexpr\textwidth } \legacy_if:nT { @tate } { \exp_not:n { - \topskip + \Cht } } \exp_not:n { + \headsep\relax }
- \exp_not:n { \box\@tempboxa\hss }
+ \exp_not:n { \hskip\dimexpr\textwidth + \headsep }
+ \legacy_if:nTF { @tate } { \exp_not:n { - \topskip + \Cht } }
+ { \dim_compare:nNnF { \jlreq@sidenote@length + \jlreq@sidenote@sep } {=} { 0pt } { + \the\dimexpr\jlreq@sidenote@length + \jlreq@sidenote@sep\relax } }
+ \exp_not:n { \relax\box\@tempboxa\hss }
}
% 位置調整とすでに構築したブロックをくっつける.
\legacy_if:nTF { @tate } {
@@ -4978,14 +4974,13 @@
\prop_put:Nno \l__jlreq_tmpb_prop {########1} \l__jlreq_tmpa_tl
}
% 左,中央,右を結合し\l__jlreq_tmpa_tlへ
- \__jlreq_pagestyle_concat_left_center_right:Nneee \l__jlreq_tmpa_tl {##1} {\prop_item:Nn \l__jlreq_tmpb_prop {left} } {\prop_item:Nn \l__jlreq_tmpb_prop {center} } {\prop_item:Nn \l__jlreq_tmpb_prop {right} }
% デフォルトのフォーマットの設定
\bool_if:nTF { \dim_compare_p:n { \jlreq@sidenote@length > 0pt } && (! \legacy_if_p:n { @tate } ) }{
\tl_set:Nn \l__jlreq_tmpb_tl {\hss\hbox to \jlreqyokoheadlength{########1}\hss}
}{
\tl_set:Nn \l__jlreq_tmpb_tl {########1}
}
- \__jlreq_pagestyle_applyformat:NocN \l__jlreq_tmpa_tl \l__jlreq_tmpa_tl { l__jlreq_pagestyle_##1_####1_format_tl } \l__jlreq_tmpb_tl
+ \__jlreq_pagestyle_concat_left_center_right:NneeecN \l__jlreq_tmpa_tl {##1} {\prop_item:Nn \l__jlreq_tmpb_prop {left} } {\prop_item:Nn \l__jlreq_tmpb_prop {center} } {\prop_item:Nn \l__jlreq_tmpb_prop {right} } { l__jlreq_pagestyle_##1_####1_format_tl } \l__jlreq_tmpb_tl
% 傍注用調整
\dim_compare:nNnT {\jlreq@sidenote@length}>{0pt} {
\legacy_if:nF { @tate } {
@@ -5029,7 +5024,7 @@
}
\if@tate
- \def\jlreqyokoheadlength{\textheight}
+ \def\jlreqyokoheadlength{\textwidth}
\else
\ifdim\jlreq@sidenote@length>0pt
\if@twocolumn
@@ -5041,7 +5036,7 @@
\def\jlreqyokoheadlength{\dimexpr\textwidth\relax}
\fi
\fi
-\edef\jlreqtateheadlength{\unexpanded{\dimexpr\headsep + \headheight + \textheight}\if@tate\else\unexpanded{- \topskip + 1\jlreq@zh}\fi\noexpand\relax}
+\edef\jlreqtateheadlength{\unexpanded{\dimexpr\textheight}\if@tate\else\unexpanded{- \topskip + 1\jlreq@zh}\fi\noexpand\relax}
\NewDocumentCommand{\NewPageStyle} { m +m } {%
\expandafter\@ifdefinable\csname ps@#1\endcsname{\DeclarePageStyle{#1}{#2}}%
@@ -5258,11 +5253,20 @@
%.. figure環境
\newcounter{figure}
-\str_if_eq:VnTF \jlreq@article@type { article } {
- \renewcommand{\thefigure}{\@arabic\c@figure}
-}{%
- \@addtoreset{figure}{chapter}
- \renewcommand{\thefigure}{\ifnum\c@chapter>\z@\thechapter.\fi \@arabic\c@figure}
+\legacy_if:nTF { @tate } {
+ \str_if_eq:VnTF \jlreq@article@type { article } {
+ \renewcommand{\thefigure}{\tatechuyoko*{\@arabic\c@figure}}
+ }{%
+ \@addtoreset{table}{chapter}
+ \renewcommand{\thefigure}{\tatechuyoko*{\ifnum\c@chapter>\z@\thechapter.\fi \@arabic\c@figure}}
+ }
+}{
+ \str_if_eq:VnTF \jlreq@article@type { article } {
+ \renewcommand{\thefigure}{\@arabic\c@figure}
+ }{%
+ \@addtoreset{figure}{chapter}
+ \renewcommand{\thefigure}{\ifnum\c@chapter>\z@\thechapter.\fi \@arabic\c@figure}
+ }
}
\newcommand*{\fps@figure}{h}
\newcommand*{\ftype@figure}{1}
@@ -5273,11 +5277,20 @@
%.. table環境
\newcounter{table}
-\str_if_eq:VnTF \jlreq@article@type { article } {
- \renewcommand{\thetable}{\@arabic\c@table}
-}{%
- \@addtoreset{table}{chapter}
- \renewcommand{\thetable}{\ifnum\c@chapter>\z@\thechapter.\fi \@arabic\c@table}
+\legacy_if:nTF { @tate } {
+ \str_if_eq:VnTF \jlreq@article@type { article } {
+ \renewcommand{\thetable}{\tatechuyoko*{\@arabic\c@table}}
+ }{%
+ \@addtoreset{table}{chapter}
+ \renewcommand{\thetable}{\tatechuyoko*{\ifnum\c@chapter>\z@\thechapter.\fi \@arabic\c@table}}
+ }
+}{
+ \str_if_eq:VnTF \jlreq@article@type { article } {
+ \renewcommand{\thetable}{\@arabic\c@table}
+ }{%
+ \@addtoreset{table}{chapter}
+ \renewcommand{\thetable}{\ifnum\c@chapter>\z@\thechapter.\fi \@arabic\c@table}
+ }
}
\newcommand*{\fps@table}{h}
\newcommand*{\ftype@table}{2}
@@ -5302,6 +5315,9 @@
\fi
}
+\bool_new:N \g__jlreq_beforemaketitle_bool
+\bool_gset_true:N \g__jlreq_beforemaketitle_bool
+
\if@titlepage
\newcommand{\maketitle}{%
% jarticleとかからあまり変更していない
@@ -5379,6 +5395,7 @@
\global\let\author\relax
\global\let\date\relax
\global\let\and\relax
+ \bool_gset_false:N \g__jlreq_beforemaketitle_bool
}%
% \vskipを\baselineskipにしてみた.
\def\@maketitle{%
@@ -5410,8 +5427,11 @@
}
%.. abstract
-\def\jlreq@parhook@abstract{}
\str_if_eq:VnF \jlreq@article@type { book } {
+ \def\jlreq@parhook@abstract{}
+ \bool_new:N \g__jlreq_abstract_with_maketitle_bool
+ \keys_define:nn { jlreqsetup } { abstract_with_maketitle .bool_set:N = \g__jlreq_abstract_with_maketitle_bool }
+ \jlreqsetup { abstract_with_maketitle = false }
\newbox\jlreq@abstractbox
\newcommand*{\abstractname}{概要}
\if@titlepage
@@ -5430,21 +5450,25 @@
}
\else
\newenvironment{abstract}{%
- \ifnum0\if@twocolumn\else1\fi\ifjlreq@preamble1\fi>0
- \ifjlreq@preamble
+ \bool_if:nTF {
+ (! \legacy_if_p:n { @twocolumn } ) ||
+ \g__jlreq_inpreamble_bool ||
+ ( \g__jlreq_beforemaketitle_bool && \g__jlreq_abstract_with_maketitle_bool )
+ } {
+ \bool_if:NT \g__jlreq_inpreamble_bool {
\ifx l\jlreq@engine\else
\def\jlreq@parhook@abstract{\futurelet\jlreq@nextchar\jlreq@openbracket@hook}%
\PushPostHook{par}{\jlreq@parhook@abstract}%
\fi
- \fi
+ }
% とりあえず全部ボックスに入れる.
\global\setbox\jlreq@abstractbox=\vtop\bgroup
- \ifjlreq@preamble
+ \bool_if:NT \g__jlreq_inpreamble_bool {
% preamble後っぽく振る舞う
\@noskipsecfalse
% \@nodocumentが入っているので一時的に無効化
\everypar{}%
- \fi
+ }
\if@twocolumn
\parindent=0pt
\hsize=\textwidth
@@ -5474,11 +5498,15 @@
\parsep\z@ \@plus.1\jlreq@zh
}%
\item\relax
- \else
+ }{
\section*{\abstractname}%
- \fi
+ }
}{%
- \ifnum0\if@twocolumn\else1\fi\ifjlreq@preamble1\fi>0
+ \bool_if:nT {
+ (! \legacy_if_p:n { @twocolumn } ) ||
+ \g__jlreq_inpreamble_bool ||
+ ( \g__jlreq_beforemaketitle_bool && \g__jlreq_abstract_with_maketitle_bool )
+ } {
\endlist
\egroup
\vspace{\baselineskip}%
@@ -5486,14 +5514,18 @@
\end{minipage}
\fi
\egroup
- \fi
- \ifjlreq@preamble
+ }
+ \bool_if:NT \g__jlreq_inpreamble_bool {
\ifx l\jlreq@engine\else
\def\jlreq@parhook@abstract{}%
\fi
- \else
+ }
+ \bool_if:nF {
+ \g__jlreq_inpreamble_bool ||
+ ( \g__jlreq_beforemaketitle_bool && \g__jlreq_abstract_with_maketitle_bool )
+ }{
\unvbox\jlreq@abstractbox
- \fi
+ }
}
\fi
}
@@ -5580,7 +5612,7 @@
itemization_beforeafter_space .code:n = {\jlreq@jlreqsetup@itemization{jlreq@itemization@beforeafter@space@envlist}{jlreq@itemization@beforeafter@space@setting}{#1}},
itemization_itemsep .code:n = {\jlreq@jlreqsetup@withenv{jlreq@itemization@itemsep@envlist}{jlreq@itemization@itemsep@setting}{#1}},
itemization_labelsep .code:n = {\jlreq@jlreqsetup@withenv{jlreq@itemization@labelsep@envlist}{jlreq@itemization@labelsep@setting}{#1}},
- itemization_label_length .code:n = {\jlreq@jlreqsetup@itemization{jlreq@itemization@label@length@envlist}{jlreq@itemization@label@length@setting}{#1}}
+ itemization_label_length .code:n = {\jlreq@jlreqsetup@itemization{jlreq@itemization@label@length@envlist}{jlreq@itemization@label@length@setting}{#1}},
}
% enumerate, itemize用初期化,#1 = i,ii,...
\def\jlreq@init@list#1{%
@@ -5725,25 +5757,37 @@
\newcommand{\tableofcontents}{%
\jlreq@top@contents=-100\relax
\if@twocolumn
- \@restonecoltrue\onecolumn
+ \bool_if:NTF \g__jlreq_tableofcontents_twocolumn_bool {
+ \@restonecolfalse
+ }{
+ \@restonecoltrue\onecolumn
+ }
\else
- \@restonecolfalse
+ % スイッチの流用
+ \bool_if:NTF \g__jlreq_tableofcontents_twocolumn_bool {
+ \@restonecoltrue\twocolumn
+ }{
+ \@restonecolfalse
+ }
\fi
\prop_item:Nn \g__jlreq_tableofcontents_prop { heading }
\@mkboth{\contentsname}{\contentsname}%
\@starttoc{toc}%
- \if@restonecol\twocolumn\fi
+ \if@restonecol
+ \bool_if:NTF \g__jlreq_tableofcontents_twocolumn_bool { \onecolumn } { \twocolumn }
+ \fi
}
+\bool_new:N \g__jlreq_tableofcontents_twocolumn_bool
+\bool_gset_false:N \g__jlreq_tableofcontents_twocolumn_bool
\keys_define:nn { jlreqsetup } {
- tableofcontents_heading .code:n = { \prop_gput:Nnn \g__jlreq_tableofcontents_prop { heading } {#1} }
+ tableofcontents_heading .code:n = { \prop_gput:Nnn \g__jlreq_tableofcontents_prop { heading } {#1} },
+ tableofcontents_twocolumn .bool_gset:N = \g__jlreq_tableofcontents_twocolumn_bool
}
\str_if_eq:VnTF \jlreq@article@type { article } {
\keys_set:nn { jlreqsetup } { tableofcontents_heading = { \section*{\contentsname} } }
}{
\keys_set:nn { jlreqsetup } { tableofcontents_heading = { \chapter*{\contentsname} } }
}
-
-
% JIS X 4051自身の目次に近づけようかと……なりきれてないけど.
% 文字の大きさは全て同じ(\normalsize)にする.
@@ -5753,8 +5797,8 @@
% 「トップ」というか,一番最初に現れた見出しを入れる.
% リーダーは.から・に変更しました.
\def\@dottedtocline#1#2#3#4#5{%
- \jlreq@set@top@contents{#1}%
\ifnum #1>\c@tocdepth \else
+ \jlreq@set@top@contents{#1}%
\vskip\toclineskip
{\leftskip #2\relax \rightskip \@tocrmarg \parfillskip -\rightskip
\parindent #2\relax\@afterindenttrue
@@ -5772,7 +5816,8 @@
\hfill\nobreak
\hb@xt@\@pnumwidth{\hss\normalfont\normalcolor #5}%
\par}%
- \fi}
+ \fi
+}
% listoffigures
\newcommand{\listoffigures}{%
@@ -6194,7 +6239,6 @@
\hbox_to_wd:nn {##1} {
\def#1 { }
\kanjishape{n-jidori}\selectfont
- \def\kanjishape####1{\jlreq@useoriginalcs{kanjishape}{####1-jidori}}
##2
\hskip\glueexpr 0pt~minus~1fil\relax
}
@@ -6317,7 +6361,6 @@
\renewcommand{\theparagraph}{\thesubsubsection .\arabic{paragraph}}
\renewcommand{\thesubparagraph}{\theparagraph .\arabic{subparagraph}}
\str_if_eq:VnTF \jlreq@article@type { article } {
-\def\X{}
\NewBlockHeading{part}{0}{font={\jlreq@keepbaselineskip{\LARGE\sffamily\gtfamily\bfseries}},label_format={第\thepart 部},lines=4,after_label_space=1\jlreq@zw,second_heading_text_indent={-1\jlreq@zw,1\jlreq@zw},subtitle_font={\jlreq@keepbaselineskip{\large}}}
\renewcommand{\thesection}{\arabic{section}}
}{% book, report
diff --git a/macros/jptex/latex/jlreq/jlreq.pdf b/macros/jptex/latex/jlreq/jlreq.pdf
index f07e3d6920..522e67dee5 100644
--- a/macros/jptex/latex/jlreq/jlreq.pdf
+++ b/macros/jptex/latex/jlreq/jlreq.pdf
Binary files differ
diff --git a/macros/jptex/latex/jlreq/luajfm2pl.lua b/macros/jptex/latex/jlreq/luajfm2pl.lua
index bccba0cb3d..626e91853a 100644
--- a/macros/jptex/latex/jlreq/luajfm2pl.lua
+++ b/macros/jptex/latex/jlreq/luajfm2pl.lua
@@ -1,6 +1,6 @@
kpse.set_program_name("texlua","lualatex")
-no_jis_chars = {'⦅','〘','〖','«','〝','⦆','〙','〗','»','〟','‼','⁇','⁈','⁉','〳','〴','〵','〻','ゕ','ゖ','ㇰ','ㇱ','ㇲ','ㇳ','ㇴ','ㇵ','ㇶ','ㇷ','ㇸ','ㇹ','ㇺ','ㇻ','ㇼ','ㇽ','ㇾ','ㇿ','ㇷ゚','€','№','㏋','ℓ','㌃','㌍','㌔','㌘','㌢','㌣','㌦','㌧','㌫','㌶','㌻','㍉','㍊','㍍','㍑','㍗','㎎','㎏','㎜','㎝','㎞','㎡','㏄','ゔ','か゚','き゚','く゚','け゚','こ゚','ヷ','ヸ','ヹ','ヺ','カ゚','キ゚','ク゚','ケ゚','コ゚','セ゚','ツ゚','ト゚','゠','–','ヲ', 'ァ', 'ィ', 'ゥ', 'ェ', 'ォ', 'ャ', 'ュ', 'ョ', 'ッ', 'ー', 'ア', 'イ', 'ウ', 'エ', 'オ', 'カ', 'キ', 'ク', 'ケ', 'コ', 'サ', 'シ', 'ス', 'セ', 'ソ', 'タ', 'チ', 'ツ', 'テ', 'ト', 'ナ', 'ニ', 'ヌ', 'ネ', 'ノ', 'ハ', 'ヒ', 'フ', 'ヘ', 'ホ', 'マ', 'ミ', 'ム', 'メ', 'モ', 'ヤ', 'ユ', 'ヨ', 'ラ', 'リ', 'ル', 'レ', 'ロ', 'ワ', 'ン'}
+no_jis_chars = {'⦅','〘','〖','«','〝','⦆','〙','〗','»','〟','‼','⁇','⁈','⁉','〳','〴','〵','〻','ゕ','ゖ','ㇰ','ㇱ','ㇲ','ㇳ','ㇴ','ㇵ','ㇶ','ㇷ','ㇸ','ㇹ','ㇺ','ㇻ','ㇼ','ㇽ','ㇾ','ㇿ','ㇷ゚','€','№','㏋','ℓ','㌃','㌍','㌔','㌘','㌢','㌣','㌦','㌧','㌫','㌶','㌻','㍉','㍊','㍍','㍑','㍗','㎎','㎏','㎜','㎝','㎞','㎡','㏄','ゔ','か゚','き゚','く゚','け゚','こ゚','ヷ','ヸ','ヹ','ヺ','カ゚','キ゚','ク゚','ケ゚','コ゚','セ゚','ツ゚','ト゚','゠','–','ヲ', 'ァ', 'ィ', 'ゥ', 'ェ', 'ォ', 'ャ', 'ュ', 'ョ', 'ッ', 'ー', 'ア', 'イ', 'ウ', 'エ', 'オ', 'カ', 'キ', 'ク', 'ケ', 'コ', 'サ', 'シ', 'ス', 'セ', 'ソ', 'タ', 'チ', 'ツ', 'テ', 'ト', 'ナ', 'ニ', 'ヌ', 'ネ', 'ノ', 'ハ', 'ヒ', 'フ', 'ヘ', 'ホ', 'マ', 'ミ', 'ム', 'メ', 'モ', 'ヤ', 'ユ', 'ヨ', 'ラ', 'リ', 'ル', 'レ', 'ロ', 'ワ', 'ン','。', '「', '」', '、', '・', '゙', '゚'}
if arg[1] == nil then
print('Usage: texlua luajfm2pl.lua [--noutf] <JFM for LuaTeX-ja> [<PL file name>]')