From 02511af04413bc7f56b5351bdf2fff1e883b571f Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 21 Mar 2022 20:33:48 +0000 Subject: lua-widow-control (21mar22) git-svn-id: svn://tug.org/texlive/trunk@62870 c570f23f-e606-0410-a88d-b1316a301751 --- .../doc/luatex/lua-widow-control/README.md | 2 +- .../luatex/lua-widow-control/lua-widow-control.pdf | Bin 375961 -> 376801 bytes .../luatex/lua-widow-control/lwc-documentation.tex | 2 +- .../lua-widow-control/t-lua-widow-control.mkiv | 4 ++-- .../lua-widow-control/t-lua-widow-control.mkxl | 4 ++-- .../lua-widow-control/lua-widow-control.sty | 23 +++++++++++++++++---- .../luatex/lua-widow-control/lua-widow-control.lua | 4 ++-- .../luatex/lua-widow-control/lua-widow-control.tex | 2 +- .../optex/lua-widow-control/lua-widow-control.opm | 2 +- 9 files changed, 29 insertions(+), 14 deletions(-) diff --git a/Master/texmf-dist/doc/luatex/lua-widow-control/README.md b/Master/texmf-dist/doc/luatex/lua-widow-control/README.md index e6e9ce0b295..b147c83768c 100644 --- a/Master/texmf-dist/doc/luatex/lua-widow-control/README.md +++ b/Master/texmf-dist/doc/luatex/lua-widow-control/README.md @@ -48,4 +48,4 @@ Lua-widow-control is licensed under the [_Mozilla Public License_, version 2.0]( Please note that a compiled document is absolutely **not** considered to be an "Executable Form" as defined by the MPL. The use of lua-widow-control in a document does not place **any** obligations on the document's author or distributors. The MPL and CC-BY-SA licenses **only** apply to you if you distribute the lua-widow-control source code or documentation. --- -_v2.0.1 (2022-03-18)_ +_v2.0.2 (2022-03-20)_ diff --git a/Master/texmf-dist/doc/luatex/lua-widow-control/lua-widow-control.pdf b/Master/texmf-dist/doc/luatex/lua-widow-control/lua-widow-control.pdf index 106f106a087..ac383d9618e 100644 Binary files a/Master/texmf-dist/doc/luatex/lua-widow-control/lua-widow-control.pdf and b/Master/texmf-dist/doc/luatex/lua-widow-control/lua-widow-control.pdf differ diff --git a/Master/texmf-dist/source/luatex/lua-widow-control/lwc-documentation.tex b/Master/texmf-dist/source/luatex/lua-widow-control/lwc-documentation.tex index 6e9eaacc662..24a58aecd4f 100644 --- a/Master/texmf-dist/source/luatex/lua-widow-control/lwc-documentation.tex +++ b/Master/texmf-dist/source/luatex/lua-widow-control/lwc-documentation.tex @@ -37,7 +37,7 @@ \startdocument[ title=lua-widow-control, author=Max Chernoff, - version=2.0.1, %%version + version=2.0.2, %%version github=https://github.com/gucci-on-fleek/lua-widow-control, ctan=https://www.ctan.org/pkg/lua-widow-control, ] diff --git a/Master/texmf-dist/tex/context/third/lua-widow-control/t-lua-widow-control.mkiv b/Master/texmf-dist/tex/context/third/lua-widow-control/t-lua-widow-control.mkiv index 716e45dcf5f..6b294eaa386 100644 --- a/Master/texmf-dist/tex/context/third/lua-widow-control/t-lua-widow-control.mkiv +++ b/Master/texmf-dist/tex/context/third/lua-widow-control/t-lua-widow-control.mkiv @@ -1,10 +1,10 @@ %D \module %D [ file=t-lua-widow-control, -%D version=2.0.1, %%version +%D version=2.0.2, %%version %D title=lua-widow-control, %D subtitle=\ConTeXt module for lua-widow-control, %D author=Max Chernoff, -%D date=2022-03-18, %%dashdate +%D date=2022-03-20, %%dashdate %D copyright=Max Chernoff, %D license=MPL-2.0+, %D url=https://github.com/gucci-on-fleek/lua-widow-control] diff --git a/Master/texmf-dist/tex/context/third/lua-widow-control/t-lua-widow-control.mkxl b/Master/texmf-dist/tex/context/third/lua-widow-control/t-lua-widow-control.mkxl index 716e45dcf5f..6b294eaa386 100644 --- a/Master/texmf-dist/tex/context/third/lua-widow-control/t-lua-widow-control.mkxl +++ b/Master/texmf-dist/tex/context/third/lua-widow-control/t-lua-widow-control.mkxl @@ -1,10 +1,10 @@ %D \module %D [ file=t-lua-widow-control, -%D version=2.0.1, %%version +%D version=2.0.2, %%version %D title=lua-widow-control, %D subtitle=\ConTeXt module for lua-widow-control, %D author=Max Chernoff, -%D date=2022-03-18, %%dashdate +%D date=2022-03-20, %%dashdate %D copyright=Max Chernoff, %D license=MPL-2.0+, %D url=https://github.com/gucci-on-fleek/lua-widow-control] diff --git a/Master/texmf-dist/tex/lualatex/lua-widow-control/lua-widow-control.sty b/Master/texmf-dist/tex/lualatex/lua-widow-control/lua-widow-control.sty index fc80a58cfbb..6124a13b4d6 100644 --- a/Master/texmf-dist/tex/lualatex/lua-widow-control/lua-widow-control.sty +++ b/Master/texmf-dist/tex/lualatex/lua-widow-control/lua-widow-control.sty @@ -13,7 +13,7 @@ \DeclareRelease{}{0000-00-00}{lua-widow-control-2022-02-22.sty} \DeclareRelease{v1.1.6}{2022-02-22}{lua-widow-control-2022-02-22.sty} -\DeclareCurrentRelease{v2.0.1}{2022-03-18} %%version %%dashdate +\DeclareCurrentRelease{v2.0.2}{2022-03-20} %%version %%dashdate % If this version of LaTeX doesn't support command hooks, then we load % the last v1.1.X version of the package. @@ -23,8 +23,8 @@ \ProvidesExplPackage {lua-widow-control} - {2022/03/18} %%slashdate - {v2.0.1} %%version + {2022/03/20} %%slashdate + {v2.0.2} %%version {Use Lua to remove widows and orphans} % Unconditional Package Loads @@ -93,7 +93,7 @@ brokenpenalty .int_gset:N = \tex_brokenpenalty:D, brokenpenalty .value_required:n = true, - brokenpenalty .initial:x = 1, + brokenpenalty .initial:n = 1, microtype .bool_gset:N = \g__lwc_use_microtype_bool, microtype .value_required:n = true, @@ -200,14 +200,29 @@ strict .meta:n = { emergencystretch = 0pt, max-cost = 5000, nobreak = warn, + widowpenalty = 1, + orphanpenalty = 1, + brokenpenalty = 1, }, strict .value_forbidden:n = true, default .meta:n = { emergencystretch = 3em, max-cost = \c_max_int, nobreak = keep, + widowpenalty = 1, + orphanpenalty = 1, + brokenpenalty = 1, }, default .value_forbidden:n = true, + + balanced .meta:n = { emergencystretch = 1em, + max-cost = 10000, + nobreak = keep, + widowpenalty = 500, + orphanpenalty = 500, + brokenpenalty = 500, + }, + balanced .value_forbidden:n = true, } % Add the user interface for the keys diff --git a/Master/texmf-dist/tex/luatex/lua-widow-control/lua-widow-control.lua b/Master/texmf-dist/tex/luatex/lua-widow-control/lua-widow-control.lua index be9cab16cb9..a6fd0bdc2af 100644 --- a/Master/texmf-dist/tex/luatex/lua-widow-control/lua-widow-control.lua +++ b/Master/texmf-dist/tex/luatex/lua-widow-control/lua-widow-control.lua @@ -107,8 +107,8 @@ elseif plain or latex or optex then debug_print("Plain/LaTeX") luatexbase.provides_module { name = lwc.name, - date = "2022/03/18", --%%slashdate - version = "2.0.1", --%%version + date = "2022/03/20", --%%slashdate + version = "2.0.2", --%%version description = [[ This module provides a LuaTeX-based solution to prevent diff --git a/Master/texmf-dist/tex/luatex/lua-widow-control/lua-widow-control.tex b/Master/texmf-dist/tex/luatex/lua-widow-control/lua-widow-control.tex index 6d4f0722e35..e86c9326040 100644 --- a/Master/texmf-dist/tex/luatex/lua-widow-control/lua-widow-control.tex +++ b/Master/texmf-dist/tex/luatex/lua-widow-control/lua-widow-control.tex @@ -3,7 +3,7 @@ % SPDX-License-Identifier: MPL-2.0+ % SPDX-FileCopyrightText: 2022 Max Chernoff -\wlog{lua-widow-control v2.0.1} %%version +\wlog{lua-widow-control v2.0.2} %%version \ifx\directlua\undefined \errmessage{% diff --git a/Master/texmf-dist/tex/optex/lua-widow-control/lua-widow-control.opm b/Master/texmf-dist/tex/optex/lua-widow-control/lua-widow-control.opm index 8980ca60076..b8870d992b6 100644 --- a/Master/texmf-dist/tex/optex/lua-widow-control/lua-widow-control.opm +++ b/Master/texmf-dist/tex/optex/lua-widow-control/lua-widow-control.opm @@ -3,7 +3,7 @@ % SPDX-License-Identifier: MPL-2.0+ % SPDX-FileCopyrightText: 2022 Max Chernoff -\_codedecl\lwcenable{lua-widow-control } %%version +\_codedecl\lwcenable{lua-widow-control } %%version \_clubpenalty=1 \_widowpenalty=1 -- cgit v1.2.3