From d91bb5cad66508ec34d77ea60c0a02c79308edef Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Fri, 17 Nov 2023 03:02:29 +0000 Subject: CTAN sync 202311170302 --- macros/optex/README | 8 + macros/optex/base/basic-macros.opm | 19 +- macros/optex/base/bib-iso690.opm | 51 ++- macros/optex/base/bib-simple.opm | 12 +- macros/optex/base/cite-bib.opm | 6 +- macros/optex/base/colors.opm | 4 + macros/optex/base/f-clara.opm | 24 ++ macros/optex/base/f-culmus.opm | 25 ++ macros/optex/base/f-fraunces.opm | 69 ++++ macros/optex/base/f-heuristica.opm | 5 +- macros/optex/base/f-oldstandard.opm | 22 + macros/optex/base/fams-ini.opm | 21 +- macros/optex/base/fonts-catalog.opm | 27 +- macros/optex/base/fonts-resize.opm | 2 +- macros/optex/base/fonts-select.opm | 38 +- macros/optex/base/hisyntax-python.opm | 6 +- macros/optex/base/if-macros.opm | 29 +- macros/optex/base/keyval.opm | 25 +- macros/optex/base/lang-data.opm | 32 +- macros/optex/base/lang-decl.opm | 2 +- macros/optex/base/lists.opm | 9 +- macros/optex/base/makeindex.opm | 11 +- macros/optex/base/math-macros.opm | 4 +- macros/optex/base/math-preload.opm | 2 +- macros/optex/base/optex-tricks.opm | 756 ++++++++++++++++++++++++++++++++++ macros/optex/base/optex.ini | 2 +- macros/optex/base/optex.lua | 6 +- macros/optex/base/others.opm | 43 +- macros/optex/base/parameters.opm | 14 +- macros/optex/base/references.opm | 13 +- macros/optex/base/table.opm | 5 +- macros/optex/base/unimath-macros.opm | 31 +- macros/optex/base/usebib.opm | 620 ++++++++++++++++++++-------- macros/optex/demo/op-biblist.bib | 2 +- macros/optex/demo/op-letter-he.tex | 37 ++ macros/optex/demo/op-slides.tex | 2 +- macros/optex/doc/omls.tex | 2 +- macros/optex/doc/optex-doc.pdf | Bin 1525711 -> 1585608 bytes macros/optex/doc/optex-doc.tex | 4 +- macros/optex/doc/optex-userdoc.tex | 143 ++++++- macros/optex/pkg/minim.opm | 24 +- macros/optex/pkg/vlna.opm | 7 +- 42 files changed, 1853 insertions(+), 311 deletions(-) create mode 100644 macros/optex/base/f-clara.opm create mode 100644 macros/optex/base/f-culmus.opm create mode 100644 macros/optex/base/f-fraunces.opm create mode 100644 macros/optex/base/f-oldstandard.opm create mode 100644 macros/optex/base/optex-tricks.opm create mode 100644 macros/optex/demo/op-letter-he.tex (limited to 'macros/optex') diff --git a/macros/optex/README b/macros/optex/README index 0d83e186c3..3dab8b68f1 100644 --- a/macros/optex/README +++ b/macros/optex/README @@ -22,6 +22,14 @@ doc/ ... PDF version of the OpTeX documentation and sources. History: +<1.13> Nov 2023: + \usebib completely reimplemented, libranian package not needed from now. + Selected OpTeX tricks are automatically loaded when a relevant macro is used. + Font file for variable font Fraunces added. + Clara serif and more font files added. + Hebrew data, font family and Hebrew example added. + More robust key-value scanner. + Minor improvements and minor bug fixes. <1.12> May 2023: Support for right-to-left (Hebrew) typesseting introduced. More features in math.opm style. diff --git a/macros/optex/base/basic-macros.opm b/macros/optex/base/basic-macros.opm index 9227505678..f2047cadf0 100644 --- a/macros/optex/base/basic-macros.opm +++ b/macros/optex/base/basic-macros.opm @@ -1,6 +1,6 @@ %% This is part of the OpTeX project, see http://petr.olsak.net/optex -\_codedecl \sdef {Basic macros for OpTeX <2023-01-22>} % preloaded in format +\_codedecl \sdef {Basic macros for OpTeX <2023-11-11>} % preloaded in format \_doc ------------------------------ \`\bgroup`, \`\egroup`, \`\empty`, \`\space`, and \`\null` @@ -56,12 +56,20 @@ \_public \sdef \sxdef \slet ; \_doc ------------------------------ - \`\adef` `{}{}` puts the as active character and defines it - as `{}`. You can declare a macro with parameters too. For example - `\adef @#1{...#1...}`. + \`\adef` `{}` defines active `` as and then + puts the as active character. I.e. the `` can include the + as non-active charter (if it is non-active before `\adef`). + For example `\adef ?{\,?}`. + If the character is special, you can escape it, for example `\adef\%{...}`. + The space can be declared by `\adef{ }{}`. + You can declare a macro with parameters too, for example + `\adef @#1{...#1...}`. You can use prefixes `\protected`, `\global`, + `\long` before `\adef`, they behave like prefixes before `\def`. \_cod ------------------------------ -\_def \_adef #1{\_catcode`#1=13 \_begingroup \_lccode`\~=`#1\_lowercase{\_endgroup\_def~}} +\_def\_adef#1#2#{\_adefA{#1}{#2}} +\_def\_adefA#1#2#3{\_ea\_def\_directlua{tex.cprint(13,"\_luaescapestring{\_csstring#1}")}#2{#3}% + \_catcode`#1=13 } \_public \adef ; \_doc ------------------------------ @@ -142,6 +150,7 @@ \_endcode % ------------------------------------- +2023-11-11: \adef reimplemented, \protected, \long, \global allowed before \adef 2023-01-22: \trycs: afterfi used for second parameter 2022-11-22: \_banner definition moved here 2022-11-18: \ahead introduced diff --git a/macros/optex/base/bib-iso690.opm b/macros/optex/base/bib-iso690.opm index fcdbd5d48d..5595d65877 100644 --- a/macros/optex/base/bib-iso690.opm +++ b/macros/optex/base/bib-iso690.opm @@ -1,6 +1,6 @@ % This is part of the OpTeX project, see http://petr.olsak.net/optex -\_codedecl \_undefined {BIB style (iso690) <2023-04-22>} % loaded on demand by \usebib +\_codedecl \_undefined {BIB style (iso690) <2023-09-13>} % loaded on demand by \usebib \_ifx\_optexbibstyle\_undefined \_errmessage {This file can be read by: \_string\usebib/? (iso690) bibfiles command only} @@ -116,7 +116,7 @@ \_bibmark=\_ea{\_tmp}% } \_def\_createbibmark #1;#2,#3;#4,#5\_fin{% #1=year #2=LastName #3=FirstName #4=nextAuthor - #2\_ifx^#4^\_else \_Mtext{bib.etal}\_fi, #1% + #2\_ifx^#4^\_else \_Mtext{bib.etal}\_fi \_ifx^#1^\_else, #1\_fi } \_doc ----------------------------- @@ -150,25 +150,11 @@ \_fi\_fi } - \_doc ----------------------------- - Non-standard field names. - \_cod ----------------------------- - -\_CreateField {ednote} -\_CreateField {citedate} -\_CreateField {numbering} -\_CreateField {isbn} -\_CreateField {issn} -\_CreateField {doi} -\_CreateField {url} -\_CreateField {bibmark} - \_doc ----------------------------- Sorting. \_cod ----------------------------- -\_SortingOrder{name,year}{lfvj} -\_SpecialSort {key} +\_fieldalias {key} {sortedby} \_doc ----------------------------- Supporting macros. @@ -305,9 +291,21 @@ \_bprintb [url] {\_preurl\_url{##1}. }{}% } \_sdef{_print:phdthesis}{\_def\_thesistype{\_Mtext{bib.phdthesis}}\_cs{_print:thesis}} -\_sdef{_print:mastershesis}{\_def\_thesistype{\_Mtext{bib.masthesis}}\_cs{_print:thesis}} +\_sdef{_print:mastersthesis}{\_def\_thesistype{\_Mtext{bib.masthesis}}\_cs{_print:thesis}} \_sdef{_print:bachelorsthesis}{\_def\_thesistype{\_Mtext{bib.bachthesis}}\_cs{_print:thesis}} +\_sdef{_print:online}{% + \_bprintb [!author] {\_doauthor1{##1}\:\ }{}% + \_bprintb [title] {{\_em##1}\_bprintc\_titlepost{\:\ *}\_bprintv[howpublished]{}{\:}\ }% + {\_bibwarning}% + \_bprinta [howpublished] {[*].\ }{}% + \_bprinta [ednote] {\_prepareednote*\_bprintv[citedate]{}{.}\ }{}% + \_bprinta [year] {}{}% + \_bprinta [accessed] {\_docitedate*///\_relax.\ }{\_bibwarning}% + \_bprintb [doi] {\_predoi DOI \_ulink[http://dx.doi.org/##1]{##1}.\ }{}% + \_bprintb [url] {\_preurl\_url{##1}. }{\_bibwarning}% +} + \_sdef{_print:generic}{% \_bprintb [!author] {\_doauthor1{##1}\:\ }{\_bibwarning}% \_bprintb [title] {{\_em##1}\_bprintc\_titlepost{\:\ *}\_bprintv[howpublished]{}{\:}\ }% @@ -784,6 +782,12 @@ There are nearly equivalent entries: `@BACHELORSTHESIS`, `@MASTERSTHESIS` and automatically. The type field is optional in this case. If it is used then it has precedence before the default setting. +\secccc The @ONLINE entry + +It is intended for online publications. + +Fields: author, title(!), howpublished, ednote, publisher, accessed, doi, url(!), note. + \secccc The @MISC entry It is intended for various usage. @@ -835,19 +839,20 @@ yearprint value) is also used in the text-oriented bib-marks when `\nonumcitations` is set. If you have some problems with name sorting, you can use the hidden field -`key`, which is used for sorting instead of the \"Lastname Firstname(s)" -of authors. If the `key` field is unset then the \"Lastname Firstname(s)" +`sortedby` (or `key` field with the same effect). +It can be used for sorting instead of the \"Lastname Firstname(s)" +of the first author. If the `sortedby` field is unset then the \"Lastname Firstname(s)" is used for sorting normally. Example: \begtt author = "Světla Čmejrková", -key = "Czzmejrkova Svetla", +sortedby = "Czzmejrkova Svetla", \endtt This entry is now sorted between C and D. The norm recommends placing the auto-citations at the top of the list of -references. You can do this by setting `key = "@"`, to each entry with your +references. You can do this by setting `sortedby = "@"`, to each entry with your name because the `@` character is sorted before `A`. @@ -928,6 +933,8 @@ Other options in the option field are silently ignored. \_endinput +2023-09-13 ... \_createbibmark: no comma if year is missing +2023-06-23 ... @ONLINE entry introduced 2023-04-22 ... incollection: typo corrected 2023-03-25 ... \_createbibmark introduced 2022-05-10 ... \. -> \:, collision with \oldaccents fixed. diff --git a/macros/optex/base/bib-simple.opm b/macros/optex/base/bib-simple.opm index e61e94d7e2..c70bb12be7 100644 --- a/macros/optex/base/bib-simple.opm +++ b/macros/optex/base/bib-simple.opm @@ -1,6 +1,6 @@ %% This is part of the OpTeX project, see http://petr.olsak.net/optex -\_codedecl \_undefined {BIB style (simple) <2023-04-22>} % loaded on demand by \usebib +\_codedecl \_undefined {BIB style (simple) <2023-09-13>} % loaded on demand by \usebib \_ifx\_optexbibstyle\_undefined \_errmessage {This file can be read by: \_string\usebib/? (simple) bibfiles command only} @@ -39,7 +39,7 @@ \_edef\_tmp{\_ea\_createbibmark\_expanded{\_tmp;\_authlist;,;,;,;}\_fin}\_fi \_bibmark=\_ea{\_tmp}% } -\_def\_createbibmark#1;#2,#3\_fin{#2, #1} +\_def\_createbibmark#1;#2,#3\_fin{#2\_ifx^#1^\_else, #1\_fi} \_def\_preurl{\_hfil\_break} \_def\_Inclause{In:~} @@ -156,6 +156,14 @@ \_bprinta [institution] {*.\ }{}% \_bprintb [url] {\_preurl\_url{##1}. }{}% } +\_sdef{_print:online}{% + \_bprinta [!author] {*.\ }{}% + \_bprintb [title] {{\_em##1}\:\ }{}% + \_bprinta [howpublished] {*.\ }{}% + \_bprinta [institution] {*.\ }{}% + \_bprinta [series] {*.\ }{}% + \_bprintb [url] {\_preurl\_url{##1}. }{\_bibwarning}% +} \_sdef{_print:misc}{% \_bprinta [!author] {*.\ }{}% \_bprintb [title] {{\_em##1}\:\ }{}% diff --git a/macros/optex/base/cite-bib.opm b/macros/optex/base/cite-bib.opm index 9dc32a2632..805b84de03 100644 --- a/macros/optex/base/cite-bib.opm +++ b/macros/optex/base/cite-bib.opm @@ -1,4 +1,4 @@ -%% This is part of the OpTeX project, see http://petr.olsak.net/optex +% This is part of the OpTeX project, see http://petr.olsak.net/optex \_codedecl \cite {Cite, Biblioraphy <2021-04-13>} % preloaded in format @@ -97,7 +97,7 @@ \_cod ----------------------------- \_def\_citeA #1#2,{\_if#1,\_else - \_if *#1\_addcitelist{*}\_ea\_skiptorelax \_fi + \_if *#1\_addcitelist{*}\_sxdef{_bib:\_bibp*}{}\_ea\_skiptorelax \_fi \_ifcsname _bib:\_bibp#1#2\_endcsname \_else \_addcitelist{#1#2}% \_opwarning{{\_the\_bibpart} \_noexpand\cite [#1#2] unknown. Try to TeX me again}\_openref @@ -125,7 +125,7 @@ distinguished by , the \`\_addcitelist``{