summaryrefslogtreecommitdiff
path: root/macros
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2023-12-16 03:01:40 +0000
committerNorbert Preining <norbert@preining.info>2023-12-16 03:01:40 +0000
commitcf11d08f6fe4d61a3da648d820601e3fca67d8d4 (patch)
tree2eea226ec62bd73e49dce85df85c093393d58af3 /macros
parent9dd4909414ccbc438a2c6276bf642904d6036891 (diff)
CTAN sync 202312160301
Diffstat (limited to 'macros')
-rw-r--r--macros/latex/contrib/l3build/CHANGELOG.md10
-rw-r--r--macros/latex/contrib/l3build/README.md2
-rw-r--r--macros/latex/contrib/l3build/l3build-arguments.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-aux.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-check.lua4
-rw-r--r--macros/latex/contrib/l3build/l3build-clean.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-ctan.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-file-functions.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-help.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-install.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-manifest-setup.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-manifest.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-stdmain.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-tagging.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-typesetting.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-unpack.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-upload.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-variables.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build-zip.lua2
-rw-r--r--macros/latex/contrib/l3build/l3build.12
-rw-r--r--macros/latex/contrib/l3build/l3build.dtx4
-rw-r--r--macros/latex/contrib/l3build/l3build.ins4
-rwxr-xr-xmacros/latex/contrib/l3build/l3build.lua4
-rw-r--r--macros/latex/contrib/l3build/l3build.pdfbin747895 -> 748206 bytes
-rw-r--r--macros/latex/contrib/responsive/README37
-rw-r--r--macros/latex/contrib/responsive/responsive-doc.bib91
-rw-r--r--macros/latex/contrib/responsive/responsive-doc.pdfbin0 -> 77546 bytes
-rw-r--r--macros/latex/contrib/responsive/responsive-doc.tex543
-rw-r--r--macros/latex/contrib/responsive/responsive.sty368
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/README.md53
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-circle.tex320
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-line.tex2
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-point.tex111
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-triangle.tex6
-rw-r--r--[-rwxr-xr-x]macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-examples.tex60
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.pdfbin537824 -> 0 bytes
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.tex11
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-presentation.tex22
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-transferts.tex4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/doc/tkz-elements.pdfbin537824 -> 551541 bytes
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz-elements.sty4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_circle.lua33
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_class.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_ellipse.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_circles.lua24
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_intersections.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_lines.lua16
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_maths.lua11
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_points.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_regular.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_triangles.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_line.lua15
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_main.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_misc.lua72
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_parallelogram.lua8
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_point.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_quadrilateral.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_rectangle.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_regular.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_square.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_triangle.lua4
-rw-r--r--macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_vector.lua4
-rw-r--r--macros/latex/contrib/unbtex/README.md11
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example.pdfbin587482 -> 584318 bytes
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example.tex153
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example/anexo-a.tex2
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example/anexo-b.tex2
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example/apendice-a.tex4
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example/capitulo2.tex392
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example/capitulo3.tex251
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example/capitulo4.tex73
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example/references.bib189
-rw-r--r--macros/latex/contrib/unbtex/unbtex-example/referencias.bib185
-rw-r--r--macros/latex/contrib/unbtex/unbtex.cls147
74 files changed, 2428 insertions, 910 deletions
diff --git a/macros/latex/contrib/l3build/CHANGELOG.md b/macros/latex/contrib/l3build/CHANGELOG.md
index 71d207d19e..8d1ec76440 100644
--- a/macros/latex/contrib/l3build/CHANGELOG.md
+++ b/macros/latex/contrib/l3build/CHANGELOG.md
@@ -7,8 +7,15 @@ this project uses date-based 'snapshot' version identifiers.
## [Unreleased]
+## [2023-12-15]
+
+### Fixed
+- Test for blank `runtest_tasks()` (issue \#327)
+
## [2023-12-13-2]
+- Correct setup for script running in TeX Live
+
## [2023-12-13]
### Fixed
@@ -739,7 +746,8 @@ this project uses date-based 'snapshot' version identifiers.
- Rationalise short option names: removed `-d`, `-E`, `-r`
- Target `cmdcheck`: specific to LaTeX kernel work
-[Unreleased]: https://github.com/latex3/l3build/compare/2023-12-13-2...HEAD
+[Unreleased]: https://github.com/latex3/l3build/compare/2023-12-15..HEAD
+[2023-12-15]: https://github.com/latex3/l3build/compare/2023-12-13-2...2023-12-15
[2023-12-13-2]: https://github.com/latex3/l3build/compare/2023-12-13...2023-12-13-2
[2023-12-13]: https://github.com/latex3/l3build/compare/2023-12-12...2023-12-13
[2023-12-12]: https://github.com/latex3/l3build/compare/2023-11-01...2023-12-12
diff --git a/macros/latex/contrib/l3build/README.md b/macros/latex/contrib/l3build/README.md
index 137b87d5ac..c071c434e6 100644
--- a/macros/latex/contrib/l3build/README.md
+++ b/macros/latex/contrib/l3build/README.md
@@ -1,7 +1,7 @@
l3build: a testing and building system for LaTeX
=================================================
-Release 2023-12-13-2
+Release 2023-12-15
Overview
--------
diff --git a/macros/latex/contrib/l3build/l3build-arguments.lua b/macros/latex/contrib/l3build/l3build-arguments.lua
index c2a9263b32..95ed9f59e4 100644
--- a/macros/latex/contrib/l3build/l3build-arguments.lua
+++ b/macros/latex/contrib/l3build/l3build-arguments.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-aux.lua b/macros/latex/contrib/l3build/l3build-aux.lua
index 5511802c16..115117c40f 100644
--- a/macros/latex/contrib/l3build/l3build-aux.lua
+++ b/macros/latex/contrib/l3build/l3build-aux.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-check.lua b/macros/latex/contrib/l3build/l3build-check.lua
index 3718d172dd..65366c91ca 100644
--- a/macros/latex/contrib/l3build/l3build-check.lua
+++ b/macros/latex/contrib/l3build/l3build-check.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
@@ -824,7 +824,7 @@ function runtest(name, engine, hide, ext, test_type, breakout)
)
-- On Windows, concatenating here will suppress any non-zero errorlevel
-- from the main run, so we split into two parts.
- if errlevels[i] == 0 and runtest_tasks("X",0) ~= "" then
+ if errlevels[i] == 0 and runtest_tasks(jobname(lvtfile),i) ~= "" then
local errorlevel =
runcmd(preamble .. runtest_tasks(jobname(lvtfile),i),testdir)
if errorlevel ~= 0 then errlevels[i] = errorlevel end
diff --git a/macros/latex/contrib/l3build/l3build-clean.lua b/macros/latex/contrib/l3build/l3build-clean.lua
index 226650b478..e5d5ddec3d 100644
--- a/macros/latex/contrib/l3build/l3build-clean.lua
+++ b/macros/latex/contrib/l3build/l3build-clean.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-ctan.lua b/macros/latex/contrib/l3build/l3build-ctan.lua
index 2efdd14067..b290533b27 100644
--- a/macros/latex/contrib/l3build/l3build-ctan.lua
+++ b/macros/latex/contrib/l3build/l3build-ctan.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-file-functions.lua b/macros/latex/contrib/l3build/l3build-file-functions.lua
index 847a1d15e6..b5cd9b5f89 100644
--- a/macros/latex/contrib/l3build/l3build-file-functions.lua
+++ b/macros/latex/contrib/l3build/l3build-file-functions.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-help.lua b/macros/latex/contrib/l3build/l3build-help.lua
index 62d35de03a..3e204df0d6 100644
--- a/macros/latex/contrib/l3build/l3build-help.lua
+++ b/macros/latex/contrib/l3build/l3build-help.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-install.lua b/macros/latex/contrib/l3build/l3build-install.lua
index e96259caa3..ad5aeaaac6 100644
--- a/macros/latex/contrib/l3build/l3build-install.lua
+++ b/macros/latex/contrib/l3build/l3build-install.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-manifest-setup.lua b/macros/latex/contrib/l3build/l3build-manifest-setup.lua
index e74e667394..b5c2b31718 100644
--- a/macros/latex/contrib/l3build/l3build-manifest-setup.lua
+++ b/macros/latex/contrib/l3build/l3build-manifest-setup.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-manifest.lua b/macros/latex/contrib/l3build/l3build-manifest.lua
index 5642c91c43..12b8cdc114 100644
--- a/macros/latex/contrib/l3build/l3build-manifest.lua
+++ b/macros/latex/contrib/l3build/l3build-manifest.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-stdmain.lua b/macros/latex/contrib/l3build/l3build-stdmain.lua
index 4b6da6675e..6209dcd296 100644
--- a/macros/latex/contrib/l3build/l3build-stdmain.lua
+++ b/macros/latex/contrib/l3build/l3build-stdmain.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-tagging.lua b/macros/latex/contrib/l3build/l3build-tagging.lua
index 9f39650598..20ef513f26 100644
--- a/macros/latex/contrib/l3build/l3build-tagging.lua
+++ b/macros/latex/contrib/l3build/l3build-tagging.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-typesetting.lua b/macros/latex/contrib/l3build/l3build-typesetting.lua
index c12c544738..d3ba3e5b6f 100644
--- a/macros/latex/contrib/l3build/l3build-typesetting.lua
+++ b/macros/latex/contrib/l3build/l3build-typesetting.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-unpack.lua b/macros/latex/contrib/l3build/l3build-unpack.lua
index a734d4c8ea..6ce4b3286b 100644
--- a/macros/latex/contrib/l3build/l3build-unpack.lua
+++ b/macros/latex/contrib/l3build/l3build-unpack.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-upload.lua b/macros/latex/contrib/l3build/l3build-upload.lua
index 85f3007146..180572baf4 100644
--- a/macros/latex/contrib/l3build/l3build-upload.lua
+++ b/macros/latex/contrib/l3build/l3build-upload.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-variables.lua b/macros/latex/contrib/l3build/l3build-variables.lua
index bbebf2fd08..9e0ed9d47a 100644
--- a/macros/latex/contrib/l3build/l3build-variables.lua
+++ b/macros/latex/contrib/l3build/l3build-variables.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build-zip.lua b/macros/latex/contrib/l3build/l3build-zip.lua
index bf03439f0d..1fab56cf4b 100644
--- a/macros/latex/contrib/l3build/l3build-zip.lua
+++ b/macros/latex/contrib/l3build/l3build-zip.lua
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build.1 b/macros/latex/contrib/l3build/l3build.1
index 9464982ab4..6b3699cf12 100644
--- a/macros/latex/contrib/l3build/l3build.1
+++ b/macros/latex/contrib/l3build/l3build.1
@@ -1,4 +1,4 @@
-.TH l3build 1 "2023-12-13-2"
+.TH l3build 1 "2023-12-15"
.SH NAME
l3build \- Checking and building packages
.SH SYNOPSIS
diff --git a/macros/latex/contrib/l3build/l3build.dtx b/macros/latex/contrib/l3build/l3build.dtx
index 9405bc4b1c..d169f49ccd 100644
--- a/macros/latex/contrib/l3build/l3build.dtx
+++ b/macros/latex/contrib/l3build/l3build.dtx
@@ -7,7 +7,7 @@
% license or (at your option) any later version. The latest version
% of this license is in the file
%
-% http://www.latex-project.org/lppl.txt
+% https://www.latex-project.org/lppl.txt
%
% This file is part of the "l3build bundle" (The Work in LPPL)
% and all files in that bundle must be distributed together.
@@ -251,7 +251,7 @@
% }^^A
% }
%
-% \date{Released 2023-12-13-2}
+% \date{Released 2023-12-15}
%
% \maketitle
% \tableofcontents
diff --git a/macros/latex/contrib/l3build/l3build.ins b/macros/latex/contrib/l3build/l3build.ins
index bdb0fb7a52..c790b35b40 100644
--- a/macros/latex/contrib/l3build/l3build.ins
+++ b/macros/latex/contrib/l3build/l3build.ins
@@ -7,7 +7,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
@@ -39,7 +39,7 @@ the LaTeX Project Public License (LPPL), either version 1.3c of
this license or (at your option) any later version. The latest
version of this license is in the file:
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
diff --git a/macros/latex/contrib/l3build/l3build.lua b/macros/latex/contrib/l3build/l3build.lua
index e0cf232aa4..0154019cb9 100755
--- a/macros/latex/contrib/l3build/l3build.lua
+++ b/macros/latex/contrib/l3build/l3build.lua
@@ -9,7 +9,7 @@ LaTeX Project Public License (LPPL), either version 1.3c of this
license or (at your option) any later version. The latest version
of this license is in the file
- http://www.latex-project.org/lppl.txt
+ https://www.latex-project.org/lppl.txt
This file is part of the "l3build bundle" (The Work in LPPL)
and all files in that bundle must be distributed together.
@@ -25,7 +25,7 @@ for those people who are interested.
--]]
-- Version information
-release_date = "2023-12-13-2"
+release_date = "2023-12-15"
-- File operations are aided by the LuaFileSystem module
local lfs = require("lfs")
diff --git a/macros/latex/contrib/l3build/l3build.pdf b/macros/latex/contrib/l3build/l3build.pdf
index 7546587a99..7214f3dcea 100644
--- a/macros/latex/contrib/l3build/l3build.pdf
+++ b/macros/latex/contrib/l3build/l3build.pdf
Binary files differ
diff --git a/macros/latex/contrib/responsive/README b/macros/latex/contrib/responsive/README
new file mode 100644
index 0000000000..dc2953cb54
--- /dev/null
+++ b/macros/latex/contrib/responsive/README
@@ -0,0 +1,37 @@
+The Responsive Package
+
+Version 0.1
+
+Change font sizes and other typographic details in LaTeX documents depending on
+the page dimensions.
+
+The Responsive package for LaTeX enables dynamic adjustment of document
+elements for various output formats and devices. Key features include:
+
+- Font Size Adjustment: Set the font size to achieve an average number of
+ characters per line, enabling suitable font size selection for various sizes
+ of page formats or devices such as tablets and e-book readers.
+
+- Typographic Scales: Choose from predefined or define custom typographic
+ scales using options such as number and ratio.
+
+- Media Queries: Test document properties using media queries, allowing
+ conditional execution of code based on test results.
+
+- Line Spacing Control: adjust line spacing determining the x-height percentage
+ for enhanced readability.
+
+Copyright: 2023-2023 Michal Hoftich
+
+This work may be distributed and/or modified under the
+conditions of the LaTeX Project Public License, either version 1.3
+of this license or (at your option) any later version.
+The latest version of this license is in
+ http://www.latex-project.org/lppl.txt
+and version 1.3 or later is part of all distributions of LaTeX
+version 2005/12/01 or later.
+
+This work has the LPPL maintenance status `maintained'.
+
+The Current Maintainer of this work is Michal Hoftich.
+
diff --git a/macros/latex/contrib/responsive/responsive-doc.bib b/macros/latex/contrib/responsive/responsive-doc.bib
new file mode 100644
index 0000000000..6c2cea1902
--- /dev/null
+++ b/macros/latex/contrib/responsive/responsive-doc.bib
@@ -0,0 +1,91 @@
+@manual{responsive,
+ title = {The Responsive package},
+ author = {Hoftich, Michal},
+ url = {https://github.com/michal-h21/responsive-latex},
+ urldate = {2023-03-30},
+ date = {2023-03-28},
+}
+
+@manual{rmodepdf,
+ title = {Rmodepdf},
+ author = {Hoftich, Michal},
+ url = {https://github.com/michal-h21/rmodepdf},
+ urldate = {2023-03-30},
+ date = {2023-03-28},
+}
+@manual{rdrview,
+ title = {Rdrview},
+ author = {Ernesto Fernández},
+ url = {https://github.com/eafer/rdrview},
+ urldate = {2023-03-30},
+ date = {2023-03-28},
+}
+@manual{luavlna,
+ title = {The Luavlna package},
+ subtitle = {Prevent line breaks after single letter words, units, or academic titles},
+ author = {Hoftich, Michal},
+ url = {https://ctan.org/pkg/luavlna},
+ urldate = {2023-03-30},
+ date = {2023-03-28},
+ version = {0.1k},
+}
+
+@manual{linebreaker,
+ title = {The Linebreaker package},
+ subtitle = {Prevent overflow boxes with LuaLaTeX},
+ author = {Hoftich, Michal},
+ url = {https://ctan.org/pkg/linebreaker},
+ urldate = {2023-03-30},
+ date = {2023-03-21},
+ version = {0.1c},
+}
+
+@manual{lua-widow-control,
+ title = {The Lua-widow-control package},
+ subtitle = {Automatically remove widows and orphans from any document},
+ author = {Chernoff, Max},
+ url = {https://ctan.org/pkg/lua-widow-control},
+ urldate = {2023-03-30},
+ date = {2022-11-22},
+ version = {3.0.0},
+}
+
+@article{chernoff,
+ doi = {10.5300/2022-1-4/49},
+ author = {Chernoff, Max},
+ title = {Automatically Removing Widows and Orphans with lua-widow-control},
+ journal = {Zpravodaj Československého sdružení uživatelů TeXu},
+ volume = {32},
+ number = {1},
+ pages = {49-76},
+ issn = {1211-6661},
+ year = {2022},
+ url = {https://dml.cz/handle/10338.dmlcz/151108}
+}
+
+@manual{luaxml,
+ title = {The Luaxml package},
+ subtitle = {Lua library for reading and serialising XML files},
+ author = {Hoftich, Michal},
+ url = {https://ctan.org/pkg/luaxml},
+ urldate = {2023-03-30},
+ date = {2021-10-06},
+ version = {0.1q},
+}
+
+@online{mortensen,
+ title = {The Typographic Scale},
+ author = {Spencer Mortensen},
+ year = {2011},
+ url = {https://spencermortensen.com/articles/typographic-scale/},
+ urldate = {2023-03-30},
+}
+
+@article{cavazza,
+ title = {Modern CSS Techniques To Improve Legibility},
+ author = {Edoardo Cavazza},
+ journal = {Smashing Magazine},
+ date = {2020-07-22},
+ url = {https://www.smashingmagazine.com/2020/07/css-techniques-legibility/},
+ urldate = {2023-03-30},
+}
diff --git a/macros/latex/contrib/responsive/responsive-doc.pdf b/macros/latex/contrib/responsive/responsive-doc.pdf
new file mode 100644
index 0000000000..1e7245c04f
--- /dev/null
+++ b/macros/latex/contrib/responsive/responsive-doc.pdf
Binary files differ
diff --git a/macros/latex/contrib/responsive/responsive-doc.tex b/macros/latex/contrib/responsive/responsive-doc.tex
new file mode 100644
index 0000000000..4272397e3e
--- /dev/null
+++ b/macros/latex/contrib/responsive/responsive-doc.tex
@@ -0,0 +1,543 @@
+\documentclass{ltxdoc}
+\newcommand\authormail[1]{\footnote{\textless\url{#1}\textgreater}}
+\ifdefined\HCode
+ \renewcommand\authormail[1]{\space\textless\Link[#1]{}{}#1\EndLink\textgreater}
+\fi
+
+\ifdefined\gitdate\else
+ \def\gitdate{\today}
+ \def\version{devel}
+\fi
+
+
+
+% \usepackage[noautomatic]{responsive}
+\usepackage[]{responsive}
+\usepackage{linebreaker}
+\usepackage{caption}
+\usepackage{subcaption}
+\usepackage{graphicx}
+\usepackage{microtype}
+\usepackage{longtable}
+\usepackage{booktabs}
+\usepackage[style=iso-authoryear]{biblatex}
+\addbibresource{responsive-doc.bib}
+\newenvironment{changelog}{\longtable{@{} l p{30em}}}{\endlongtable}
+\newcommand\change[2]{#1 & #2\\}
+\ifdefined\HCode
+ % I want to convert parts of the document to images,
+ % so I need to use Type 1 fonts for the correct conversion with Dvisvgm
+ \usepackage{ebgaramond}
+\else
+\usepackage{fontspec}
+\setmainfont{EB Garamond}[Numbers=OldStyle]
+\setmonofont{Inconsolatazi4-Regular.otf}[Scale=MatchLowercase]
+\fi
+
+\newcommand\StartDescribe[1]{%
+ \par\medskip\noindent\DescribeMacro#1
+}
+\usepackage{lipsum}
+\title{The Responsive Package}
+\author{Michal Hoftich\authormail{michal.h21@gmail.com}}
+\date{Version \version, \gitdate}
+\NewDocElement[macrolike = false ,
+toplevel = false,
+idxtype
+= key,
+idxgroup = Package keys,
+% printtype = \textit{key}
+]{Key}{key}
+
+\newcommand\printsize[1]{\csname #1\endcsname\par\noindent Sample\par}
+\newcommand\showscale[2][.5\textwidth]{%
+ \noindent\fbox{%
+ \begin{minipage}{#1}
+ \ResponsiveSetup{#2}
+ \setsizes[34]{25}
+ \printsize{huge}
+ \printsize{LARGE}
+ \printsize{Large}
+ \printsize{large}
+ \hrule
+ \printsize{normalsize}
+ \hrule
+ \printsize{small}
+ \printsize{footnotesize}
+ \end{minipage}
+ }
+ \ifx\relax#2\relax Default parameters\else\texttt{#2}\fi\hfill\null
+}
+\makeindex
+
+\begin{document}
+\maketitle
+\begin{abstract}
+Responsive design aims to display text and other design elements well on
+variety of outputs, including electronic devices or various paper sizes.
+It originated on the Web, where it uses Cascading Style Sheets to change
+design elements.
+
+This package tries to achieve similar result with \LaTeX. The main aim is to
+support output of multiple editions of one document with
+readable font sizes regardless of the physical size of the produced PDF,
+from smartphones or e-ink readers to printed A4 pages.
+\end{abstract}
+
+\clearpage
+
+\tableofcontents
+
+\section{Introduction}
+
+This package aims to facilitate the creation of documents for multiple output
+formats, such as various page sizes, e-book readers, or even mobile phones.
+
+One of the issues that needs to be addressed is setting the correct font size
+for readability. The default font size in LaTeX is 10 points, regardless of the
+page size. This is an appropriate font size for A5 format pages. For A4 format,
+the font size should be larger, while it may be smaller for smaller displays of
+e-readers and mobile phones. Similarly, we can adjust the line spacing, which
+also affects text readability depending on the font size and page size.
+
+Web browsers face a similar problem as they must display text on both large PC
+monitors and smaller displays of laptops, tablets, and mobile phones. The
+solution they use is called \textit{responsive design}.
+
+Responsive design is a method of web design that allows flexible and dynamic
+adaptation of the appearance and layout of page content to different display
+devices. One of the key elements of responsive design is a flexible structure
+that enables adjusting the size of elements on the page to the display device.
+
+Another important element is media queries. These allow defining rules based on
+the properties of the display device, such as screen width and height or output
+type (paper, display). Thanks to these rules, the same page code can be
+well-displayed on both large monitors and mobile devices or when printing.
+
+The Responsive package is inspired by these principles. Its main function
+is to set the font size based on the page size and the approximate number of
+characters that should fit on the page (see figure~\ref{fig:example}). It also adjusts the typographic scale
+(influencing font size, for example, in headings or footnotes), line height,
+and supports a simple version of media queries.
+
+
+\section{Features}
+
+
+\subsection{Fitting Font Size to the Page Size}
+
+Regardless of the width of the page, there is a certain range of the number of
+characters that should be displayed on average per line of text to ensure good
+readability. With a larger number of characters, the reader may have difficulty
+quickly moving to the next line, while shorter lines may lead to skipping
+lines.
+
+The Responsive package automatically sets the width of the text to a chosen number of characters.
+Figure~\ref{fig:example} shows a difference in the font size in two
+different text widths.
+
+
+\begin{figure}[htbp]
+ \caption{Example of changing font size based on the width of the text block:}\label{fig:example}
+\begin{subfigure}[t]{0.45\textwidth}
+ \centering
+\fbox{%
+\begin{minipage}{4cm}
+\ResponsiveSetup{}
+\setsizes{}
+
+\lipsum[1]
+
+\end{minipage}}
+\caption{Text width 4\,cm}
+\end{subfigure}
+% \hfill
+\begin{subfigure}[t]{0.45\textwidth}
+ \centering
+\fbox{%
+\begin{minipage}{6cm}
+\ResponsiveSetup{}
+\setsizes{}
+
+% \lipsum[1]
+Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit,
+vestibulum ut, placerat ac, adipiscing vitae, felis. Curabitur dictum gravida
+mauris. Nam arcu libero, nonummy eget, consectetuer id, vulputate a,
+magna. Donec vehicula augue eu neque. Pellentesque habitant morbi
+tristique senectus et netus et malesuada fames ac turpis egestas. Mauris
+ut leo. Cras viverra metus rhoncus sem. Nulla et lectus vestibulum urna
+fringilla ultrices. Phasellus eu tellus sit amet tortor gravida placerat. Integer
+sapien est, iaculis in, pretium quis, viverra ac, nunc.
+
+\end{minipage}}
+\caption{Text width 6\,cm}
+\end{subfigure}
+\end{figure}
+
+
+\subsection{Typographic Scale}
+
+The typographic scale is a set of predetermined font sizes used to establish a
+consistent visual style for a document or website. These sizes are typically
+expressed in point units and progressively increase or decrease by a specific
+interval along the scale.
+
+A typographic scale may include sizes for headings, footnotes, and body text.
+Proper use of a typographic scale helps create a visual hierarchy that enhances
+the readability and aesthetic appeal of the text.
+
+In \LaTeX, the typographic scale is accessible through commands such as \verb|\large|,
+\verb|\huge|, or \verb|\scriptsize|. Each of these commands is one interval
+away from the previous size.
+
+I drew inspiration from Spencer Mortensen's article (\citeyear{mortensen}), which defines several
+different typographic scales and provides a method for easily creating
+additional scales.
+The default scale in the Responsive package,
+which closely aligns with the scale used in \LaTeX, is referred to as \verb|tetratonic|.
+The package also offers additional scales described in the
+article, such as the golden scale based on the golden ratio.
+See Figure~\ref{fig:scale} for differences between the default scale and scale based on the
+golden ratio.
+
+The Responsive package includes several predefined typographic scales, but you
+can also define your own. All scales are defined using the options
+\verb|number| and \verb|ratio|, specifying how many steps (\verb|number|) the
+font size increases by the size of \verb|ratio|. For example scale with \verb|number| of 2
+and \verb|ratio| of 5, will double the font size over 5 steps.
+Table~\ref{tbl:scales} lists all predefined scales.
+
+\begin{table}[htbp]
+ \centering
+ \begin{tabular}{l l l}
+ \toprule
+ name & number & ratio\\
+ \midrule
+ heptatonic & 7 & 2\\
+ pentatonic & 5 & 2\\
+ tetratonic & 4 & 2\\
+ tritonic & 3 & 2\\
+ golden & 2 & 1.618\\\bottomrule
+ \end{tabular}
+ \caption{Predefined typographic scales}\label{tbl:scales}
+\end{table}
+
+
+\begin{figure}[htbp]
+ \caption{Sample of Typographic Scales (the default font size is highlighted with lines)}\label{fig:scale}
+ \begin{subfigure}[b]{0.45\textwidth}
+\fbox{%
+\begin{minipage}{5cm}
+\setsizes{45}
+
+\showscale{}
+
+\end{minipage}}
+\caption{Default scale}
+\end{subfigure}
+\begin{subfigure}[b]{0.45\textwidth}
+% \begin{verbatim}
+% \ResponsiveSetup{scale=golden}
+% \end{verbatim}
+\fbox{%
+\begin{minipage}{5cm}
+% \ResponsiveSetup{scale=golden}
+\setsizes{45}
+
+\showscale{scale=golden}
+
+\end{minipage}}
+\caption{Golden ratio scale}
+\end{subfigure}
+\end{figure}
+% % https://spencermortensen.com/articles/typographic-scale/
+
+
+
+% \showscale{}
+% \showscale{scale=heptatonic}
+% \showscale{scale=tritonic}
+% \showscale{scale=golden}
+% \showscale{scale=none,ratio=1.3,number=2}
+
+\subsection{Line height}
+
+In the default settings of \LaTeX, the line spacing is set to the font size
+multiplied by a factor of 1.2. For different fonts and page sizes, a different
+line spacing may be appropriate. Similarly, distinct values may be suitable for
+the printed and electronic versions of the document.
+
+The Responsive package provides two options which allows you to change the line spacing
+(Figure~\ref{fig:lineratio}).
+
+First is the \verb|lineratio| option, which bases the line height
+on the ratio between x-height of the current font and the desired height.
+I've found this method in article by Edoardo Cavazza in the \textit{Smashing Magazine}~(\citeyear{cavazza}).
+The value of the \verb|lineratio| option determines what percentage of the total line
+height is the \verb|x-height|. The higher this value, the lower the line will be. For
+different fonts, the same ratio may lead to different line heights because each
+font has a different \verb|x-height| value. The appropriate lineratio size needs to be
+determined experimentally. The default value should roughly correspond to a
+line height of 1.2, the default in \LaTeX.
+
+Another option is \verb|lineheight|, which
+is similar to the CSS property \verb|line-height|. Using it, we can choose the
+line height as a multiple of the font size.
+
+
+
+
+\begin{figure}[htbp]
+ \caption{Changing the line spacing by adjusting the value of \texttt{lineratio}.}\label{fig:lineratio}
+ \begin{subfigure}[b]{0.45\textwidth}
+\fbox{%
+\begin{minipage}{5cm}
+\ResponsiveSetup{lineratio=38}
+\setsizes{65}
+
+\lipsum[1]
+
+\end{minipage}}
+\caption{lineratio=38}
+\end{subfigure}
+\begin{subfigure}[b]{0.45\textwidth}
+\fbox{%
+\begin{minipage}{5cm}
+\ResponsiveSetup{lineratio=34}
+\setsizes{65}
+
+\lipsum[1]
+
+\end{minipage}}
+\caption{lineratio=34}
+\end{subfigure}
+\end{figure}
+
+% https://www.smashingmagazine.com/2020/07/css-techniques-legibility/
+
+\subsection{Media Queries}
+
+Media queries are a technique that allows web developers to dynamically adapt
+the appearance and behavior of websites based on various device properties,
+such as screen width and height, device orientation, color support, and more.
+Thanks to these conditions, responsive and flexible websites can be created
+that automatically adjust to different types and sizes of devices on which they
+are displayed.
+
+How can this technique be useful for \LaTeX\ package authors? They could, for
+example, set the font size, line spacing, and other elements for specific page
+dimensions. Once the user chooses the page size based on the device size for
+which they want to compile the document, these elements are automatically
+adjusted. For instance, a package author could define that if the width of the
+text block is smaller than a certain dimension, fewer characters will be
+displayed on each line compared to longer lines (Figure~\ref{fig:mediaquery}).
+
+The media query used for this figure looks like this:
+
+\begin{verbatim}
+\mediaquery{max-textwidth=4cm}
+{\ResponsiveSetup{lineratio=38}\setsizes{45}}
+\ResponsiveSetup{lineratio=34}\setsizes{60}}
+\end{verbatim}
+
+This media query defines that if the width of the text is smaller than or equal to 4 cm, a
+smaller number of characters will be displayed per line to prevent the font
+from being too small and difficult to read. Additionally, a smaller line
+spacing will be applied.
+
+
+
+\newcommand\mdtest{%
+ \mediaquery{max-textwidth=4cm}
+ {\ResponsiveSetup{lineratio=38}\setsizes{45}}
+ {\ResponsiveSetup{lineratio=34}\setsizes{60}}
+ \lipsum[1]
+}
+
+\begin{figure}[htbp]
+ % \centering
+ % \begin{subcaptionblock}{0.25\textwidth}
+ \caption{Change number of characters and line spacing depending on the text width using Media queries}\label{fig:mediaquery}
+ % \begin{subcaptiongroup}
+ \begin{subfigure}[t]{0.40\textwidth}
+ \centering
+ \begin{minipage}{4cm}
+ { \mdtest
+
+ }
+ \end{minipage}
+ \caption{Text width of 4\,cm with 45 characters}
+ \end{subfigure}
+ \hfill
+ % \hspace{2em}
+ \begin{subfigure}[t]{0.55\textwidth}
+ \centering
+ \begin{minipage}{6cm}
+ { \mdtest
+
+ }
+ \end{minipage}
+ \caption{Text width of 6\,cm with 60 characters}
+ \end{subfigure}
+
+\end{figure}
+
+The tests available in media queries are listed in Table~\ref{tbl:mediaqueries}.
+Those expecting dimensional units also have variants using \texttt{min-} and \texttt{max-}, which
+do not test exact values but rather whether the provided value is less than,
+greater than, or equal to the tested parameter. Tests without these variants evaluate for an exact match.
+The test for a two-column layout is special in that it does not expect any
+testing values. It evaluates to true if the document uses the \texttt{twocolumn} option.
+
+
+
+\begin{table}[htbp]
+ \centering
+ \begin{tabular}{ll}
+ \toprule
+ test & possible values \\
+ \midrule
+ textwidth & dimensional unit \\
+ textheight & dimensional unit \\
+ paperwidth & dimensional unit\\
+ paperheight & dimensional unit\\
+ orientation & landscape, portrait\\
+ twocolumn & none \\
+ \bottomrule
+ \end{tabular}
+ \caption{Tests available in media queries}\label{tbl:mediaqueries}
+\end{table}
+
+
+
+
+\section{Package Options}
+
+The following options can be passed as package options used in \cmd{\usepackage},
+or later in the document using the \cmd{\ResponsiveSetup} command.
+
+\medskip
+
+\noindent \DescribeKey{characters} Approximate number of characters that should fit to a text line. Default value is 66.
+
+\noindent \DescribeKey{noautomatic} Disable automatic setting of font sizes, line spacing and typographic scale in the document. You can set them
+later using the \cmd{\setsizes} and \cmd{\ResponsiveSetup} commands.
+
+\noindent \DescribeKey{scale} Select named typographic scale. Default scale is
+\texttt{tetratonic}, which is the most similar to the default scale used by
+\LaTeX.
+
+\noindent \DescribeKey{number} The number of steps during which the text size is multiplied by the amount specified in the \texttt{ratio} option.
+
+\noindent \DescribeKey{ratio} The amount by which the font size will increase over a given number of steps.
+
+\noindent \DescribeKey{lineratio} The ratio used in calculating the line spacing. Default value is 33.3333, which should produce similar line spacing as the default \LaTeX\ setting.
+
+\noindent \DescribeKey{lineheight} Calculate line spacing by a fixed ratio, similarly to the CSS \texttt{lineheight} property.
+
+\noindent \DescribeKey{boxwidth} Width of line that is used for font size calculations in the \cmd{\setsizes} command. Default value is \cmd{\textwidth}.
+
+
+
+
+\section{Commands}
+
+\StartDescribe\ResponsiveSetup
+\cmd\ResponsiveSetup\marg{options}
+
+\noindent It allows you to reset the package options later in the document. You
+need to call the \cmd{\setsizes} command to reset font sizes explicitly if you use this command
+outside of the document preamble, or when using the \texttt{noautomatic} option.
+
+\StartDescribe\setsizes
+\cmd\setsizes\oarg{line height ratio}\marg{number of characters per line}
+
+\noindent It sets the text size so that the specified average number of
+characters fit on a line. If you do not provide the number of characters, the
+package option \texttt{characters} will be used.
+
+
+\StartDescribe\fonttobox
+\cmd\fonttobox\oarg{line height ratio}\marg{text width}\marg{text}
+
+\noindent Set the text size so that the specified text in the second parameter has
+the specified size in the first parameter. Optionally, you can set the line
+height ratio.
+
+\StartDescribe\mediaquery
+\cmd\mediaquery\marg{media query test}\marg{true code}\marg{false code}
+
+\noindent
+It tests the document's properties using media queries and executes code based on the test results.
+The code can typically use \cmd\ResponsiveSetup, but you can also execute any other commands.
+
+\StartDescribe\DeclareMediaQueryMatcher
+\cmd\DeclareMediaQueryMatcher\marg{test name}\marg{\LaTeX\ 3 boolean query test}
+
+\noindent Declares a new test for a media query. The tests can use LaTeX 3 boolean tests,
+and in case of a positive result, it must execute the command
+\cmd\mediaquerytrue.
+
+\StartDescribe\fixtextheight
+\cmd\fixtextheight
+
+\noindent It adjusts the page height, header, and footer to prevent underflow
+\cmd{\vbox} warnings in the output routine.
+
+
+
+\section{Troubleshooting}
+
+Occasionally, you can run into issues caused by the change of font sizes. \LaTeX\ sets lot of parameters
+depending on the base font size. We try to recalculate them according to the new font size, but you can still
+experience some issues, described in following subsections.
+
+\subsection{Underfull \texttt{\textbackslash vbox} warning}
+
+Occasionally, you can get the following warning:
+
+\begin{verbatim}
+Underfull \vbox (badness 6412) has occurred while \output is active []
+\end{verbatim}
+
+We calculate the page height that suits for the font size, but often,
+we would get error when a bigger font is used on the page,
+for example in chapters. When you set font sizes in the document preamble,
+text height should be changed automatically. If you reset font sizes later in the
+document, you need to use the \cmd{\fixtextheight} command. It should help in
+most cases. If not, you can try the following hack.
+This trick should fix \cmd{\vbox} errors in the output routine, but it can lead
+to an irregular number of lines on pages.
+
+
+\begin{verbatim}
+\ExplSyntaxOn
+\def\@textbottom{\vskip \z@ \@plus \resp_font_size \@minus \resp_font_size}
+\ExplSyntaxOff
+\end{verbatim}
+
+\section{License}
+
+Permission is granted to copy, distribute and/or modify this software
+under the terms of the \LaTeX\ Project Public License, version 1.3.
+
+
+\section{Changes}
+
+\begin{changelog}
+ \change{2023-12-13}{Version 0.1 released.}
+ \change{}{Finished documentation.}
+ \change{2023-12-07}{Added the \texttt{lineheight} property.}
+ \change{}{Use floating point numbers for the lineratio.}
+ \change{2023-12-06}{ChangeLog started.}
+\end{changelog}
+% \section{Examples}
+% \PrintIndex
+
+\printbibliography[heading=bibintoc]
+
+
+
+
+
+\end{document}
diff --git a/macros/latex/contrib/responsive/responsive.sty b/macros/latex/contrib/responsive/responsive.sty
new file mode 100644
index 0000000000..65e5061f45
--- /dev/null
+++ b/macros/latex/contrib/responsive/responsive.sty
@@ -0,0 +1,368 @@
+% support for responsive font size, based on the document dimensions
+\ProvidesPackage{responsive}
+\RequirePackage{expl3,l3keys2e}
+\RequirePackage{kvoptions}
+\ProvidesExplPackage{responsive}
+{2023-12-15}{0.1}{Responsive design for LaTeX}
+
+%%%%%%%%%%%%%%%%%%%%%%
+% keyval processing %
+%%%%%%%%%%%%%%%%%%%%%%
+
+% numbers of characters that should fit on the line
+\int_new:N\l_resp_charlines_int
+\l_resp_charlines_int = 66
+
+% line height ratio
+% see https://www.smashingmagazine.com/2020/07/css-techniques-legibility/
+% for more details
+\fp_new:N\l_resp_lineheight_ratio
+% this value corresponds to lineheight with 1.2
+\fp_set:Nn\l_resp_lineheight_ratio{33.33333}
+
+% alternatively, we can use lineheight
+\fp_new:N\l_resp_lineheight
+
+% this is used in line spacing, the idea is to make larger spacing
+% for larger font sizes, but I need to find a better calculation method,
+% as it doesn't work well for now
+\fp_new:N\l_resp_lineheight_multiplier
+\fp_set:Nn\l_resp_lineheight_multiplier{1}
+
+
+% type of typograhic scale
+\tl_new:N\l_resp_scaletype_str
+\tl_set:Nn\l_resp_scaletype_str {tetratonic}
+
+% these numbers are used in the typo scale calculation
+\fp_new:N\l_resp_scalen_fp
+\fp_new:N\l_resp_scaler_fp
+
+\bool_new:N\l_resp_no_execute
+\bool_set_false:N\l_resp_no_execute
+
+\tl_new:N\l_resp_boxwidth
+\tl_set:Nn \l_resp_boxwidth \textwidth
+
+\keys_define:nn {responsive} {
+ characters .int_set:N = \l_resp_charlines_int,
+ noautomatic .bool_set:N = \l_resp_no_execute,
+ number .fp_set:N = \l_resp_scalen_fp,
+ ratio .fp_set:N =\l_resp_scaler_fp,
+ scale .tl_set:N = \l_resp_scaletype_str,
+ lineratio .fp_set:N = \l_resp_lineheight_ratio,
+ lineheight .fp_set:N = \l_resp_lineheight,
+ lineheight .default:n = 0,
+ boxwidth .tl_set:N = \l_resp_boxwidth,
+}
+
+
+\ProcessKeysOptions{responsive}
+
+% the \l_resp_charlist_tl is used to construct string used for line length measurement
+\str_new:N\l_resp_alphabet_tl
+\str_new:N\l_resp_charlist_tl
+% construct really long string that will enable to measure wide number of characters
+% on a text line
+\str_set:Nn\l_resp_alphabet_tl{abcdefghijklmnopqrstuvwxyz}
+\str_set:NV\l_resp_charlist_tl{
+ \l_resp_alphabet_tl\l_resp_alphabet_tl\l_resp_alphabet_tl
+ \l_resp_alphabet_tl\l_resp_alphabet_tl\l_resp_alphabet_tl
+ \l_resp_alphabet_tl\l_resp_alphabet_tl\l_resp_alphabet_tl
+ \l_resp_alphabet_tl\l_resp_alphabet_tl\l_resp_alphabet_tl
+}
+
+
+
+
+\NewDocumentCommand\ResponsiveScale{O{\l_resp_scaletype_str}}{
+ % decide which typographic scale should be used in \setfontsize
+ \str_case_e:nn{\l_resp_scaletype_str}{
+ {heptatonic}{
+ \fp_set:Nn\l_resp_scaler_fp{2}
+ \fp_set:Nn\l_resp_scalen_fp{7}
+ }
+ {pentatonic}{
+ \fp_set:Nn\l_resp_scaler_fp{2}
+ \fp_set:Nn\l_resp_scalen_fp{5}
+ }
+ {tetratonic}{
+ \fp_set:Nn\l_resp_scaler_fp{2}
+ \fp_set:Nn\l_resp_scalen_fp{4}
+ }
+ {tritonic}{
+ \fp_set:Nn\l_resp_scaler_fp{2}
+ \fp_set:Nn\l_resp_scalen_fp{3}
+ }
+ {golden}{
+ \fp_set:Nn\l_resp_scaler_fp{1.618}
+ \fp_set:Nn\l_resp_scalen_fp{2}
+ }
+ {none}{}
+ }
+}
+
+% set default scale
+\ResponsiveScale
+
+% enable setting of the keys also in the document
+\NewDocumentCommand\ResponsiveSetup{m}{%
+ \keys_set:nn {responsive} {#1}
+ \ResponsiveScale
+}
+
+\dim_new:N\resp_font_size
+\dim_new:N\resp_line_skip
+
+% change font size to fix text to a given width
+% usage \fonttobox{\textwidth}{hello world}
+% optional parameter changes line spacing, smaller the value, bigger the spacing
+% details about the value are in the following article:
+% https://www.smashingmagazine.com/2020/07/css-techniques-legibility/
+\NewDocumentCommand\fonttobox{O{\l_resp_lineheight_ratio} m m}{
+ % set initial fontsize and typeset text in a box
+ \dimen1=#2\relax%
+ \fontsize{10}{12}\selectfont%
+ \setbox0=\hbox{#3}%
+ % calculate ratio betwen the typeset box and desired width
+ \resp_font_size=\fp_to_dim:n {\f@size * (\dim_to_fp:n{\dimen1} / \dim_to_fp:n{\wd0})}%
+ % calculate line height. inspired by https://www.smashingmagazine.com/2020/07/css-techniques-legibility/
+ \resp_line_skip=\fp_to_dim:n {\dim_to_fp:n{1ex} * (\dim_to_fp:n{\dimen1} / \dim_to_fp:n{\wd0}) / (#1/100)}
+ \fontsize{\resp_font_size}{\resp_line_skip}\selectfont%
+ \typeout{calculated~font~size: \fp_to_dim:n {\dim_to_fp:n{\dimen1} / \dim_to_fp:n{\wd0}}, \f@size, \the\baselineskip}%
+}
+
+
+% calculate typographic scale
+% based on formula from https://spencermortensen.com/articles/typographic-scale/
+% #1 - base size, #2, number of note, #3 r, #4 n
+\NewDocumentCommand\typoscale{m m m m}{%
+ \fp_to_dim:n{\dim_to_fp:n{#1} * (#3 ^ (#2/#4)) }
+}
+
+
+% calculate font size for the given note and multiply it
+% #1 base font size #2 number of note, #3 multiplication factor
+\cs_set:Npn\resp_multiply_note:nnn #1#2#3{
+ \fp_to_dim:n{\dim_to_fp:n{#1} * (\l_resp_scaler_fp ^ (#2/\l_resp_scalen_fp)) * #3 }
+}
+
+% calculate font size for the given note and multiply it
+% #1 number of note, #2 multiplication factor
+\cs_set:Npn\resp_multiply_font_size:nn #1#2{
+ % \fp_to_dim:n{\dim_to_fp:n{\resp_font_size} * (\l_resp_scaler_fp ^ (#1/\l_resp_scalen_fp)) * #2 }
+ \resp_multiply_note:nnn\resp_font_size{#1}{#2}
+}
+
+% Copy of skip setting commands from size10.clo
+% Instead of hardcoded values, we use calculations based on the font size
+\cs_set:Npn\resp_skips:n #1{
+ \abovedisplayskip \resp_multiply_font_size:nn{#1}{1} \@plus\resp_multiply_font_size:nn{#1}{0.2} \@minus\resp_multiply_font_size:nn{#1}{0.5}
+ \abovedisplayshortskip \z@ \@plus\resp_multiply_font_size:nn{#1}{0.3}
+ \belowdisplayshortskip \resp_multiply_font_size:nn{#1}{0.6} \@plus\resp_multiply_font_size:nn{#1}{0.3} \@minus\resp_multiply_font_size:nn{#1}{0.3}
+ \belowdisplayskip \abovedisplayskip
+}
+
+% #1 font command, #2 note number
+\cs_set:Npn\resp_set_font_size:Nn #1#2{%
+ \@setfontsize#1{\resp_multiply_note:nnn\resp_font_size{#2}{1}}{\resp_multiply_note:nnn\resp_line_skip{#2}{\l_resp_lineheight_multiplier}}
+}
+
+% recalculate \textheight and \headheight with the changed font size
+% this is necessary to prevent the underfull \vbox messages from the output rutine
+\cs_set:Npn\resp_textheight:n {
+ % divide original textheight by the current baseline size - this gives us the number of lines that will fit
+ % then multipy it by the baseline again, to get the new \textheight
+ \setlength\textheight{\fp_to_dim:n{floor(\textheight/\resp_line_skip) * \resp_line_skip }}
+ \setlength\topskip{\resp_line_skip}
+ % \setlength\topskip{\resp_font_size}
+ \addtolength\textheight{\topskip}
+ \setlength\maxdepth{0.5\topskip}
+ \setlength\@maxdepth{0.5\topskip}
+ \setlength\headheight{\resp_font_size}
+ \setlength\headsep {1.5\resp_font_size}
+ \setlength\footskip{\fp_to_dim:n{2*\resp_font_size+1}}
+}
+
+% the functionality to fix the textheight should be available as a document command
+\NewDocumentCommand\fixtextheight{}{%
+ \resp_textheight:n%
+}
+
+\cs_set:Npn\resp_declare_font_sizes{%
+ \DeclareRobustCommand\normalsize{\resp_set_font_size:Nn\normalsize{0}\resp_skips:n{1}}%
+ \DeclareRobustCommand\tiny{\resp_set_font_size:Nn\tiny{-3}}
+ \DeclareRobustCommand\scriptsize{\resp_set_font_size:Nn\scriptsize{-2}}
+ \DeclareRobustCommand\small{\resp_set_font_size:Nn\small{-1}\resp_skips:n{-1}}
+ \DeclareRobustCommand\footnotesize{\resp_set_font_size:Nn\footnotesize{-2}\resp_skips:n{-2}}
+ \DeclareRobustCommand\large{\resp_set_font_size:Nn\large{1}}
+ \DeclareRobustCommand\Large{\resp_set_font_size:Nn\Large{2}}
+ \DeclareRobustCommand\LARGE{\resp_set_font_size:Nn\LARGE{3}}
+ \DeclareRobustCommand\huge{\resp_set_font_size:Nn\huge{4}}
+ \DeclareRobustCommand\Huge{\resp_set_font_size:Nn\Huge{5}}
+}
+
+
+% #1 line spacing ratio
+% #2 number or characters that should fit to a text line
+\NewDocumentCommand\setsizes{O{\l_resp_lineheight_ratio} m}{%
+ \ifx\relax#2\relax
+ \int_set_eq:NN\l_tmpa_int\l_resp_charlines_int
+ \else
+ \int_set:Nn\l_tmpa_int{#2}
+ \fi
+ % if lineheight is set directly, we need to calculate lineheight_ratio,
+ % because it is used on a lot of places
+ \fp_compare:nTF{\l_resp_lineheight=0}{}{
+ % divide "x" size by desired line spacing (font size * lineheight)
+ % lineheight should be ratio, for example 1.2, which is used by default in LaTeX
+ \fp_set:Nn\l_resp_lineheight_ratio{\fp_eval:n{(\dim_to_fp:n{1ex} / (\f@size * \l_resp_lineheight))*100}}
+ }
+ \fonttobox[#1]{\l_resp_boxwidth}{\tl_range:Nnn\l_resp_charlist_tl{1}{\l_tmpa_int}}%
+ \resp_declare_font_sizes%
+ \normalsize%
+ \if@twocolumn
+ \parindent=\resp_font_size
+ \else
+ \parindent=\fp_to_dim:n{\resp_font_size * 1.5}
+ \fi
+}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%
+%% Media query support %%
+%%%%%%%%%%%%%%%%%%%%%%%%%
+
+\prop_new:N \l_responsive_media_query
+\bool_new:N \l_responsive_media_query_matched
+
+
+% define new test for a media query
+% #1 name of test
+% #2 test that can be used in LaTeX 3 boolean query
+\NewDocumentCommand\DeclareMediaQueryMatcher{m m}{
+ \cs_set:cpn{responsive_query_test:#1}##1{#2}
+}
+
+% this command should be used by media query tests to symbolize that they were successful
+\NewDocumentCommand\mediaquerytrue{}{\bool_set_true:N\l_responsive_media_query_matched}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%
+%% media query tests %%%%
+%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% tests if the passed dimension is larger than paperwidth
+\DeclareMediaQueryMatcher{max-paperwidth}{
+ \dim_compare:nT{\paperwidth<=#1}{\mediaquerytrue}
+}
+
+% tests if the passed dimension is smaller than paperwidth
+\DeclareMediaQueryMatcher{min-paperwidth}{
+ \dim_compare:nT{\paperwidth>=#1}{\mediaquerytrue}
+}
+
+% match exaxt paperwidth
+\DeclareMediaQueryMatcher{paperwidth}{
+ \dim_compare:nT{\paperwidth=#1}{\mediaquerytrue}
+}
+
+% tests if the passed dimension is larger than paperheight
+\DeclareMediaQueryMatcher{max-paperheight}{
+ \dim_compare:nT{\paperheight<=#1}{\mediaquerytrue}
+}
+
+% tests if the passed dimension is smaller than paperheight
+\DeclareMediaQueryMatcher{min-papeheight}{
+ \dim_compare:nT{\paperheight>=#1}{\mediaquerytrue}
+}
+
+% match exaxt paperheight
+\DeclareMediaQueryMatcher{paperheight}{
+ \dim_compare:nT{\paperheight=#1}{\mediaquerytrue}
+}
+
+
+% tests if the passed dimension is smaller than textwidth
+\DeclareMediaQueryMatcher{max-textwidth}{
+ \dim_compare:nT{\textwidth<=#1}{\mediaquerytrue}
+}
+
+% tests if the passed dimension is larger than textwidth
+\DeclareMediaQueryMatcher{min-textwidth}{
+ \dim_compare:nT{\textwidth>=#1}{\mediaquerytrue}
+}
+
+% match exaxt textwidth
+\DeclareMediaQueryMatcher{textwidth}{
+ \dim_compare:nT{\textwidth=#1}{\mediaquerytrue}
+}
+
+% tests if the passed dimension is larger than textheight
+\DeclareMediaQueryMatcher{max-textheight}{
+ \dim_compare:nT{\textheight<=#1}{\mediaquerytrue}
+}
+
+% tests if the passed dimension is smaller than textheight
+\DeclareMediaQueryMatcher{min-textheight}{
+ \dim_compare:nT{\textheight>=#1}{\mediaquerytrue}
+}
+
+% match exaxt textheight
+\DeclareMediaQueryMatcher{textheight}{
+ \dim_compare:nT{\textheight=#1}{\mediaquerytrue}
+}
+
+% test if the current page is in landscape mode
+% we assume that if \paperwidth / \paperheight > 1 then we are in the landscape mode
+\DeclareMediaQueryMatcher{orientation}{
+ \str_if_eq:nnTF{#1}{landscape}{
+ \fp_compare:nT{\dim_ratio:nn{\paperwidth}{\paperheight} > 1}{\mediaquerytrue}
+ }{
+ \fp_compare:nT{\dim_ratio:nn{\paperwidth}{\paperheight} < 1}{\mediaquerytrue}
+ }
+}
+
+\DeclareMediaQueryMatcher{twocolumn}{%
+ \if@twocolumn\mediaquerytrue\fi
+}
+
+
+% find if handler exists for the passed media query type and execute it
+\cs_set:Npn \l_responsive_handle_media_query#1#2{
+ \cs_if_exist_use:cTF{responsive_query_test:#1}{{#2}}{\PackageWarning{responsive}{Unknown~media~query~test:~#1=#2}}
+}
+
+% #1 - media query
+% #2 - code executed when query matches
+% #3 - code executed when query fails
+\NewDocumentCommand\mediaquery{m m m}{
+ % change the list of media queries to a property list, which we can loop over
+ \prop_set_from_keyval:Nn\l_responsive_media_query{#1}
+ % loop over all media queries
+ \prop_map_inline:Nn\l_responsive_media_query{
+ % initialize boolean condition for media queries
+ \bool_set_false:N\l_responsive_media_query_matched
+ % the media query handler must use \mediaquerytrue if the query matches
+ \l_responsive_handle_media_query{##1}{##2}
+ % escape the loop immediately if the query doesn't run \mediaquerytrue
+ \bool_if:NF\l_responsive_media_query_matched{\prop_map_break:}
+ }
+ %
+ \bool_if:NTF\l_responsive_media_query_matched{#2}{#3}
+
+}
+
+
+
+% setup font sizes at the begin document, in order to support Geometry etc.
+\AtBeginDocument{
+ % set the default font size, based on numbers of characters we want to show on a line of text
+ % \fonttobox[32]\textwidth{\tl_range:Nnn\l_resp_charlist_tl{1}{\l_resp_charlines_int}}%
+ \bool_if:NTF\l_resp_no_execute {}{
+ \setsizes{\l_resp_charlines_int}
+ \fixtextheight
+ }
+}
+
+
+
+\endinput
diff --git a/macros/latex/contrib/tkz/tkz-elements/README.md b/macros/latex/contrib/tkz/tkz-elements/README.md
index 93bf219100..2ece035621 100644
--- a/macros/latex/contrib/tkz/tkz-elements/README.md
+++ b/macros/latex/contrib/tkz/tkz-elements/README.md
@@ -1,10 +1,10 @@
# tkz-elements — for euclidean geometry
-Release 1.50c 2023/12/08
+Release 1.60c 2023/12/14
## Description
-`tkz-elements v.1.50c` is the new version of a library written in lua, allowing to make all the necessary calculations to define the objects of a Euclidean geometry figure. You need to compile with `LuaLaTeX`. With `tkz-elements`, the definitions and calculations are only done with `Lua`.
+`tkz-elements v.1.60c` is the new version of a library written in lua, allowing to make all the necessary calculations to define the objects of a Euclidean geometry figure. You need to compile with `LuaLaTeX`. With `tkz-elements`, the definitions and calculations are only done with `Lua`.
The main possibility of programmation proposed is oriented "object programming" with object classes like point, line, triangle, circle and ellipse. For the moment, once the calculations are done, it is `tkz-euclide` or `TikZ` which allows the drawings.
@@ -56,31 +56,38 @@ package conflicts.
## Examples
Some examples will be stored on my site : [http://altermundus.fr](http://altermundus.fr).
+An important example `Golden Arbelos` using the package is on the site.
## History
- - version 1.50c Correction of the documentation
-
- Added "swap" option to create triangles from the "line" object.
-
- "iscyclic" is a new method to know if a quadrilateral is inscribable in a circle.
-
- Added function "diameter" to create a circle.
-
- Added function "swap" to swap two points.
-
- Correction method "gold" of object rectangle.
+ - version 1.60c
+
+ - added Internal and external tangents common to two circles:
+ - function circle : `external_tangent`(C)
+ - function circle : `internal_tangent(C)
+ - radical_center and radical_circle are also valid for two circles
+ - function `radical_center` (C1,C2,C3)
+ - function `radical_circle` (C1,C2,C3)
+ - function `circles_position` (C1,C2)
+ - function `midcircle` (C1,C2) powerful tool for working with inversions
+ - Bug corrected in midarc now use get_angle instead of get_angle_
+ - Modification of a triangle attribute `ca` replaces `ac` to designate the line passing through the third and first points
+ - The center of symmetry of a parallelogram is named "center" instead of "i".
+ - Correction documentation
+ - Correction of examples using the circle:point (k) method, where k is now a real number rather than an angle.
- Correction method "in_circle_" of object triangle.
-
- Correction method "incentral_tr_" of object triangle.
-
- Added method "soddy_center" of object triangle.
-
- Added option "swap" for method "square" of object line.
-
- Added method "report" for object line. Transfer a defined length from a point
+ - version 1.50c Correction of the documentation
- Added option "swap" to the function "square : side"
+ - Added "swap" option to create triangles from the "line" object.
+ - "iscyclic" is a new method to know if a quadrilateral is inscribable in a circle.
+ - Added function "diameter" to create a circle.
+ - Added function "swap" to swap two points.
+ - Correction method "gold" of object rectangle.
+ - Correction method "in_circle_" of object triangle.
+ - Correction method "incentral_tr_" of object triangle.
+ - Added method "soddy_center" of object triangle.
+ - Added option "swap" for method "square" of object line.
+ - Added method "report" for object line. Transfer a defined length from a point
+ - Added option "swap" to the function "square : side"
- Version 1.40c Restructuring objects
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-circle.tex b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-circle.tex
index 6eb97c239b..1ed09078a3 100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-circle.tex
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-circle.tex
@@ -115,8 +115,8 @@ Three attributes are used (south, west, radius).
\midrule
\Imeth{circle}{orthogonal\_from (pt)} & |C = C.OA: orthogonal_from (z.P)| & \\
\Imeth{circle}{orthogonal\_through (pta,ptb)} & |C = C.OA: orthogonal_through (z.z1,z.z2)|\\
-\Imeth{circle}{inversion (circle)} & |L or C = C.AC: inversion (C.EF)|&\\
-
+\Imeth{circle}{inversion (...)} & | C.AC: inversion (pt, pts, L or C )|& see \ref{ssub:inversion}, \ref{ssub:inversion_point}, \ref{ssub:inversion_line}, \ref{ssub:inversion_circle}\\
+\Imeth{circle}{midcircle (C)} & |C.inv = C.OA: midcircle (C.EF)| & see \ref{ssub:midcircle} \\
\midrule
\textbf{Miscellaneous} &&\\
\midrule
@@ -265,7 +265,7 @@ The "inversion" method can be used on a point, a line or a circle. Depending on
\subsubsection{Inversion: point} % (fold)
\label{ssub:inversion_point}
-The "inversion" method can be used on a point, a line or a circle. Depending on the type of object, the function determines the correct algorithm to use.
+The "inversion" method can be used on a point, a group of points, a line or a circle. Depending on the type of object, the function determines the correct algorithm to use.
\begin{minipage}{.5\textwidth}
\begin{verbatim}
@@ -424,9 +424,321 @@ color = "orange"
\tkzLabelPoints(a,...,f,o,p,q)
\end{tikzpicture}
\end{minipage}
+% subsubsection inversion (end)
+\subsubsection{midcircle} % (fold)
+\label{ssub:midcircle}
-% subsubsection inversion (end)
+\begin{minipage}{0.95\linewidth }
+\emph{From Eric Danneels and Floor van Lamoen: A midcircle of two given circles is a circle that swaps the two given circles by inversion. Midcircles are in the same pencil of circles as the given circles. The center of the midcircle(s) is one or both of the centers of similitude. We can distinguish four cases:
+\begin{enumerate}[label=(\roman*)]
+ \item The two given circles intersect: there are two midcircles with centers at the centers of similitude of the given circles;
+ \item One given circle is in the interior of the other given circle. Then there is one midcircle with center of similitude at the internal center of similitude of the given circles;
+ \item One given circle is in the exterior of the other given circle. Then there is one midcircle with center at the external center of similitude of the given circles.
+Clearly the tangency cases can be seen as limit cases of the above;
+\item If the circles intersect in a single point, the unique midcircle has center at the external similitude center or at internal similitude center.
+\end{enumerate} }
+\end{minipage}
+
+
+Let's look at each of these cases:
+\begin{enumerate}[label=(\roman*)]
+\item If the two given circles intersect, then there are two circles of inversion through their common points, with centers at the centers of similitudes. The two midcircles bisect their angles and are orthogonal to each other. The centers of the midcircles are the internal center of similitude and the external center of similitude $I$ and $J$.
+
+Consider two intersecting circles $(\mathcal{A})$ and $(\mathcal{B})$.
+We can obtain the centers of similarity of these two circles by constructing $EH$ and $FG$ two diameters parallel of the circles $(\mathcal{A})$ and $(\mathcal{B})$. The line $(GE)$ intercepts the line $(AB)$ in $J$ and the line $(EF)$ intercepts the line $(AB)$ in $I$. The circles $(\mathcal{I})$ and $(\mathcal{J})$ are orthogonal and are the midcircles of $(\mathcal{A})$ and $(\mathcal{B})$. The division $(A,B;I,J)$ is harmonic.
+
+\begin{minipage}{.4\textwidth}
+\begin{verbatim}
+\begin{tkzelements}
+scale = .8
+z.A = point : new ( 1 , 0 )
+z.B = point : new ( 3 , 0 )
+z.O = point : new ( 2.1, 0 )
+z.P = point : new ( 1 ,0 )
+C.AO = circle : new (z.A,z.O)
+C.BP = circle : new (z.B,z.P)
+z.E = C.AO.south
+z.H = C.AO.north
+z.F = C.BP.north
+z.G = C.BP.south
+C.IT,C.JV = midcircle_ (C.AO,C.BP)
+z.I,z.T = get_points ( C.IT )
+z.J,z.V = get_points ( C.JV )
+z.X,z.Y = intersection (C.AO,C.BP)
+\end{tkzelements}
+\end{verbatim}
+\end{minipage}
+\begin{minipage}{.6\textwidth}
+ \begin{tkzelements}
+ scale = .8
+ z.A = point : new ( 1 , 0 )
+ z.B = point : new ( 3 , 0 )
+ z.O = point : new ( 2.1, 0 )
+ z.P = point : new ( 1 ,0 )
+ C.AO = circle : new (z.A,z.O)
+ C.BP = circle : new (z.B,z.P)
+ z.E = C.AO.south
+ z.H = C.AO.north
+ z.F = C.BP.north
+ z.G = C.BP.south
+ C.IT,C.JV = midcircle_ (C.AO,C.BP)
+ z.I,z.T = get_points ( C.IT )
+ z.J,z.V = get_points ( C.JV )
+ z.X,z.Y = intersection (C.AO,C.BP)
+ \end{tkzelements}
+ \begin{tikzpicture}
+ \tkzGetNodes
+ \tkzDrawCircles[teal,thick](A,O B,P)
+ \tkzDrawSegments[dashed,red](E,F I,B I,G I,F)
+ \tkzDrawLines[gray](I,T J,V)
+ \tkzDrawCircles[teal,thick](A,O B,P)
+ \tkzDrawCircles[red,thick](I,X J,X)
+ \tkzDrawPoints(A,B,I,J,E,F,G,H,X,Y)
+ \tkzDrawPoints[red](I,J)
+ \begin{scope}[font = \scriptsize]
+ \tkzLabelPoints(A,I,J,G)
+ \tkzLabelPoints[below left](E)
+ \tkzLabelPoints[right](B)
+ \tkzLabelPoints[above](F,H,X)
+ \tkzLabelPoints[above right](Y)
+ \end{scope}
+ \end{tikzpicture}
+\end{minipage}
+
+
+\vfill
+
+\item One given circle is in the interior of the other given circle.
+
+\begin{minipage}{.6\textwidth}
+\begin{verbatim}
+ \begin{tkzelements}
+ scale =.75
+ z.A = point : new ( 3 , 0 )
+ z.B = point : new ( 5 , 0 )
+ z.O = point : new ( 2 , 0 )
+ z.P = point : new ( 1 , 0 )
+ L.AB = line : new (z.A,z.B)
+ C.AO = circle : new (z.A,z.O)
+ C.BP = circle : new (z.B,z.P)
+ z.R,z.S = intersection (L.AB,C.BP)
+ z.U,z.V = intersection (L.AB,C.AO)
+ C.SV = circle : diameter (z.S,z.V)
+ C.UR = circle : diameter (z.U,z.R)
+ z.x = C.SV.center
+ z.y = C.UR.center
+ C.IT = midcircle_ (C.AO,C.BP)
+ z.I,z.T = get_points ( C.IT )
+\end{tkzelements}
+\end{verbatim}
+\end{minipage}
+\begin{minipage}{.6\textwidth}
+ \begin{tkzelements}
+ scale =.75
+ z.A = point : new ( 3 , 0 )
+ z.B = point : new ( 5 , 0 )
+ z.O = point : new ( 2 , 0 )
+ z.P = point : new ( 1 , 0 )
+ L.AB = line : new (z.A,z.B)
+ C.AO = circle : new (z.A,z.O)
+ C.BP = circle : new (z.B,z.P)
+ z.R,z.S = intersection (L.AB,C.BP)
+ z.U,z.V = intersection (L.AB,C.AO)
+ C.SV = circle : diameter (z.S,z.V)
+ C.UR = circle : diameter (z.U,z.R)
+ z.x = C.SV.center
+ z.y = C.UR.center
+ C.IT = midcircle_ (C.AO,C.BP)
+ z.I,z.T = get_points ( C.IT )
+ \end{tkzelements}
+ \begin{tikzpicture}
+ \tkzGetNodes
+ \tkzDrawCircles[teal,thick](A,O B,P)
+ \tkzDrawCircles[green!20!black](x,S y,R)
+ \tkzDrawPoints(A,B)
+ \tkzDrawPoints[red](I)
+ \tkzLabelPoints(A,B,I)
+ \tkzDrawCircles[red,thick](I,T)
+ \tkzLabelCircle[below](x,V)(270){$(\alpha)$}
+ \tkzLabelCircle[below](y,R)(270){$(\beta)$}
+ \tkzLabelCircle[below](I,T)(250){$\textcolor{red}{(\gamma)}$}
+ \end{tikzpicture}
+ \end{minipage}
+
+
+This case is a little more complicated. We'll construct the two circles $(\alpha)$ and $(\beta)$ tangent to the two given circles. Then we construct the radical circle orthogonal to the circles $(\alpha)$ and $(\beta)$. Its center is the radical center as well as the center of internal similtude of circles of center $A$ and $B$.
+
+\item When the two given circles are external to each other, we construct the external center of similitude of the two given circles.
+$I$ is the center of external similarity of the two given circles. To obtain the inversion circle, simply note that $H$ is such that $IH^2= IE\times IF$
+
+\begin{minipage}{.4\textwidth}
+\begin{verbatim}
+\begin{tkzelements}
+scale=.75
+local a,b,c,d
+z.A = point : new ( 0 , 0 )
+z.B = point : new ( 4 , 0 )
+z.a = point : new ( .5 , 0)
+z.b = point : new ( 1 , 0)
+C.Aa = circle : new (z.A,z.a)
+C.Bb = circle : new (z.B,z.b)
+L.AB = line : new (z.A,z.B)
+z.E = C.Aa.north
+z.F = C.Bb.north
+L.EF = line : new (z.E,z.F)
+C.IT = midcircle_ (C.Aa,C.Bb)
+z.I,z.T = get_points ( C.IT )
+L.TF = C.Bb : tangent_from (z.I)
+z.H = intersection (L.TF,C.IT)
+z.E = intersection (L.TF,C.Aa)
+z.F=L.TF.pb
+\end{tkzelements}
+\end{verbatim}
+\end{minipage}
+\begin{minipage}{.6\textwidth}
+\begin{tkzelements}
+scale=.75
+local a,b,c,d
+z.A = point : new ( 0 , 0 )
+z.B = point : new ( 4 , 0 )
+z.a = point : new ( .5 , 0)
+z.b = point : new ( 1 , 0)
+C.Aa = circle : new (z.A,z.a)
+C.Bb = circle : new (z.B,z.b)
+L.AB = line : new (z.A,z.B)
+z.E = C.Aa.north
+z.F = C.Bb.north
+L.EF = line : new (z.E,z.F)
+C.IT = midcircle_ (C.Aa,C.Bb)
+z.I,z.T = get_points ( C.IT )
+L.TF = C.Bb : tangent_from (z.I)
+z.H = intersection (L.TF,C.IT)
+z.E = intersection (L.TF,C.Aa)
+z.F=L.TF.pb
+\end{tkzelements}
+\begin{tikzpicture}
+\tkzGetNodes
+\tkzDrawCircles[teal,thick](A,a B,b)
+\tkzDrawCircles[red,thick](I,T)
+\tkzDrawSegments[gray](I,F)
+\tkzDrawPoints(A,B,E,F)
+\tkzDrawPoints[red](I,H)
+\tkzDrawLine(I,B)
+\tkzLabelPoints(A,B)
+\tkzLabelPoints[above](E,F)
+\tkzLabelPoints[above left,red](I,H)
+\end{tikzpicture}
+\end{minipage}
+
+
+\item Consider two tangent circles $(\mathcal{A})$ and $(\mathcal{B})$,
+\begin{itemize}
+
+\item $(\mathcal{B})$ being external and angent to $(\mathcal{A})$. The construction is identical to the previous one.
+
+\begin{minipage}{.4\textwidth}
+\begin{verbatim}
+\begin{tkzelements}
+scale=.75
+local a,b,c,d
+z.A = point : new ( 0 , 0 )
+z.B = point : new ( 4 , 0 )
+z.a = point : new ( 1 , 0)
+z.b = point : new ( 1 , 0)
+C.Aa = circle : new (z.A,z.a)
+C.Bb = circle : new (z.B,z.b)
+L.AB = line : new (z.A,z.B)
+z.E = C.Aa.north
+z.F = C.Bb.north
+L.EF = line : new (z.E,z.F)
+C.IT = midcircle_ (C.Aa,C.Bb)
+z.I,z.T = get_points ( C.IT )
+L.TF = C.Bb : tangent_from (z.I)
+z.H = intersection (L.TF,C.IT)
+z.E = intersection (L.TF,C.Aa)
+z.F=L.TF.pb
+\end{tkzelements}
+\end{verbatim}
+\end{minipage}
+\begin{minipage}{.6\textwidth}
+\begin{tkzelements}
+scale=.75
+local a,b,c,d
+z.A = point : new ( 0 , 0 )
+z.B = point : new ( 4 , 0 )
+z.a = point : new ( 1 , 0)
+z.b = point : new ( 1 , 0)
+C.Aa = circle : new (z.A,z.a)
+C.Bb = circle : new (z.B,z.b)
+L.AB = line : new (z.A,z.B)
+z.E = C.Aa.north
+z.F = C.Bb.north
+L.EF = line : new (z.E,z.F)
+C.IT = midcircle_ (C.Aa,C.Bb)
+z.I,z.T = get_points ( C.IT )
+L.TF = C.Bb : tangent_from (z.I)
+z.H = intersection (L.TF,C.IT)
+z.E = intersection (L.TF,C.Aa)
+z.F=L.TF.pb
+\end{tkzelements}
+\begin{tikzpicture}
+\tkzGetNodes
+\tkzDrawCircles[teal,thick](A,a B,b)
+\tkzDrawCircles[red,thick](I,T)
+\tkzDrawSegments[gray](I,F)
+\tkzDrawPoints(A,B,E,F)
+\tkzDrawPoints[red](I,H)
+\tkzDrawLine(I,B)
+\tkzLabelPoints(A,B)
+\tkzLabelPoints[above](E,F)
+\tkzLabelPoints[above left,red](I,H)
+\end{tikzpicture}
+\end{minipage}
+
+
+\item When one of the given circles is inside and tangent to the other, the construction is easy.
+
+\begin{minipage}{.4\textwidth}
+\begin{verbatim}
+\begin{tkzelements}
+z.A = point : new ( 2 , 0 )
+z.B = point : new ( 4 , 0 )
+z.a = point : new ( 1 , 0)
+z.b = point : new ( 1 , 0)
+C.Aa = circle : new (z.A,z.a)
+C.Bb = circle : new (z.B,z.b)
+C.IT = midcircle_ (C.Aa,C.Bb)
+z.I,z.T = get_points ( C.IT )
+\end{tkzelements}
+\end{verbatim}
+\end{minipage}
+\begin{minipage}{.6\textwidth}
+\begin{tkzelements}
+z.A = point : new ( 2 , 0 )
+z.B = point : new ( 4 , 0 )
+z.a = point : new ( 1 , 0)
+z.b = point : new ( 1 , 0)
+C.Aa = circle : new (z.A,z.a)
+C.Bb = circle : new (z.B,z.b)
+C.IT = midcircle_ (C.Aa,C.Bb)
+z.I,z.T = get_points ( C.IT )
+\end{tkzelements}
+
+\begin{tikzpicture}
+\tkzGetNodes
+\tkzDrawCircles[teal,thick](A,a B,b)
+\tkzDrawCircles[red,thick](I,T)
+\tkzDrawPoints(A,B)
+\tkzDrawPoints[red](I)
+\tkzLabelPoints(A,B)
+\tkzLabelPoints[above left,red](I)
+\end{tikzpicture}
+\end{minipage}
+\end{itemize}
+\end{enumerate}
+
+% subsubsection midcircle (end)
% subsection methods_of_the_class_circle (end)
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-line.tex b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-line.tex
index 1bd4b831e4..337a36f2eb 100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-line.tex
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-line.tex
@@ -397,7 +397,7 @@ z.a,z.b = L.ab.pa,L.ab.pb
\tkzGetNodes
\tkzDrawPoints(A,...,F)
\tkzLabelPoints(A,...,F)
-\tkzDrawSegments[->,red,> =latex](C,E D,F A,B) )
+\tkzDrawSegments[->,red,> =latex](C,E D,F A,B)
\end{tikzpicture}
\end{tkzexample}
\end{minipage}
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-point.tex b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-point.tex
index c9b5928ff0..ef9ddbfc76 100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-point.tex
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-point.tex
@@ -8,73 +8,70 @@ The class on which the whole edifice rests, it's the class \Iclass{point}. This
The creation of a point is done using the following method, but there are other possibilities. If a scaling factor has been given, the method takes it into account.
-\setbox\strutbox=\hbox{\vrule height6.8pt depth3.2pt width0pt}
\def\size{42mm}
\begin{tikzpicture}[remember picture]
- \node[ draw, fill=red!10] (tbl) {%
+\node[ draw, fill=red!10] (tbl) {%
\centering
- \begin{minipage}{\size}
- \hspace{\fill} \texttt{Arguments}\hspace{\fill}
-
- \tikz\node[minimum width=\size,font=\small,
- draw, fill=cyan!10,
- rectangle split, rectangle split parts=5
- ] {
- \texttt{re (real)\strutbox}
- \nodepart{two}\texttt{im (real)\strutbox}
- \nodepart{three}\texttt{type = 'point'\strutbox}
- \nodepart{four}\texttt{argument (rad)\strutbox}
- \nodepart{five}\texttt{modulus (cm)\strutbox}
- };
-
- \hspace{\fill} \texttt{Methods}\hspace{\fill}
-
- \tikz\node[minimum width=\size,font=\small,
- draw, fill=orange!20,sharp corners,
- rectangle split, rectangle split parts=4
- ] {
- \texttt{homothety(coeff,obj)\strutbox}
- \nodepart{two}\texttt{rotation (angle,object)\strutbox}
- \nodepart{three}\texttt{symmetry (object)\strutbox}
- \nodepart{four}\texttt{\ldots}
- };
-
- \end{minipage}
- };
+\begin{minipage}{\size}
+
+ \hspace{\fill} \texttt{Arguments}\hspace{\fill}
+
+ \tikz\node[minimum width=\size,font=\small,
+ draw, fill=cyan!10,
+ rectangle split, rectangle split parts=5
+ ] {
+ \texttt{re (real)}
+ \nodepart{two}\texttt{im (real)}
+ \nodepart{three}\texttt{type = 'point'}
+ \nodepart{four}\texttt{argument (rad)}
+ \nodepart{five}\texttt{modulus (cm)}
+ };
+
+ \hspace{\fill} \texttt{Methods}\hspace{\fill}
+
+ \tikz\node[minimum width=\size,font=\small,
+ draw, fill=orange!20,sharp corners,
+ rectangle split, rectangle split parts=4
+ ] {
+ \texttt{homothety(coeff,obj)}
+ \nodepart{two}\texttt{rotation (angle,object)}
+ \nodepart{three}\texttt{symmetry (object)}
+ \nodepart{four}\texttt{\ldots}
+ };
+\end{minipage}};
\node[ draw, fill=red!10,,minimum height = 2em,
rounded corners,anchor=south] (tc) at (tbl.north){Class |Point|};
\end{tikzpicture}
\hspace{5cm}\begin{tikzpicture}[remember picture]
\node[ draw, fill=red!10] (tbl) {%
\centering
- \begin{minipage}{\size}
- \hspace{\fill} \texttt{Arguments}\hspace{\fill}
-
- \tikz\node[minimum width=\size,font=\small,
- draw, fill=cyan!10,
- rectangle split, rectangle split parts=5
- ] {
- \texttt{re = 1\strutbox}
- \nodepart{two}\texttt{im = 2\strutbox}
- \nodepart{three}\texttt{type = 'point'\strutbox}
- \nodepart{four}\texttt{argument = atan(2)\strutbox}
- \nodepart{five}\texttt{modulus = $\sqrt{5}$\strutbox}
- };
-
- \hspace{\fill} \texttt{Methods}\hspace{\fill}
-
- \tikz\node[minimum width=\size,font=\small,
- draw, fill=orange!20,sharp corners,
- rectangle split, rectangle split parts=4
- ] {
- \texttt{homothety(coeff,obj)\strutbox}
- \nodepart{two}\texttt{rotation (angle,object)\strutbox}
- \nodepart{three}\texttt{symmetry (object)\strutbox}
- \nodepart{four}\texttt{\ldots\strutbox}
- };
-
- \end{minipage}
+\begin{minipage}{\size}
+ \hspace{\fill} \texttt{Arguments}\hspace{\fill}
+
+ \tikz\node[minimum width=\size,font=\small,
+ draw, fill=cyan!10,
+ rectangle split, rectangle split parts=5
+ ] {
+ \texttt{re = 1}
+ \nodepart{two}\texttt{im = 2}
+ \nodepart{three}\texttt{type = 'point'}
+ \nodepart{four}\texttt{argument = atan(2)}
+ \nodepart{five}\texttt{modulus = $\sqrt{5}$}
+ };
+
+ \hspace{\fill} \texttt{Methods}\hspace{\fill}
+
+ \tikz\node[minimum width=\size,font=\small,
+ draw, fill=orange!20,sharp corners,
+ rectangle split, rectangle split parts=4
+ ] {
+ \texttt{homothety(coeff,obj)}
+ \nodepart{two}\texttt{rotation (angle,object)}
+ \nodepart{three}\texttt{symmetry (object)}
+ \nodepart{four}\texttt{\ldots}
+ };
+\end{minipage}
};
\node[ draw, fill=red!10,remember picture,minimum height = 2em,
rounded corners,anchor=south] (to) at (tbl.north){object |z.A|};
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-triangle.tex b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-triangle.tex
index 7b051cd723..9c6e822704 100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-triangle.tex
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-classes-triangle.tex
@@ -34,8 +34,8 @@ The triangle object is created using the \Imeth{triangle}{new} method, for examp
\Iattr{triangle}{beta}& Vertex angle of the second vertex\\
\Iattr{triangle}{gamma}& Vertex angle of the third vertex\\
\Iattr{triangle}{ab}& Line defined by the first two points of the triangle\\
-\Iattr{triangle}{ac}& Line defined by the first point and the last point\\
-\Iattr{triangle}{bc}& Line defined by the last two points of the triangle\\
+\Iattr{triangle}{bc}& Line defined by the last two points \\
+\Iattr{triangle}{ca}& Line defined by the last and the first points of the triangle\\
\bottomrule %
\end{tabular}
\egroup
@@ -87,7 +87,7 @@ The triangle object is created using the \Imeth{triangle}{new} method, for examp
b = T.abc.b
c = T.abc.c
alpha = T.abc.alpha
- beta = T.abc.beta
+ beta = T.abc.beta
gamma = T.abc.gamma
\end{tkzelements}
\hspace*{\fill}
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-examples.tex b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-examples.tex
index 7a00735fd4..91923e2232 100755..100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-examples.tex
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-examples.tex
@@ -2467,7 +2467,7 @@ z.t = intersection (L.ox,L.MaS) -- through
\tkzLabelPoints(C_1,C_2)
\tkzLabelPoints[above](T)
\tkzLabelSegment[left](C_1,T){r}
- \tkzLabelSegments[right](C_2,T){\gamma}
+ \tkzLabelSegments[right](C_2,T){$\gamma$}
\tkzLabelSegment[below](C_1,C_2){d}
\tkzLabelCircle[left=10pt](C_1,T)(180){Circle 1}
\tkzLabelCircle[right=10pt](C_2,T)(180){Circle 2}
@@ -2494,7 +2494,7 @@ z.S,z.T = get_points (C: orthogonal_from (z.C_2))
\tkzLabelPoints(C_1,C_2)
\tkzLabelPoints[above](T)
\tkzLabelSegment[left](C_1,T){r}
-\tkzLabelSegments[right](C_2,T){\gamma}
+\tkzLabelSegments[right](C_2,T){$\gamma$}
\tkzLabelSegment[below](C_1,C_2){d}
\tkzLabelCircle[left=10pt](C_1,T)(180){Circle 1}
\tkzLabelCircle[right=10pt](C_2,T)(180){Circle 2}
@@ -2507,21 +2507,20 @@ z.S,z.T = get_points (C: orthogonal_from (z.C_2))
\begin{tkzexample}[latex=0cm,small,code only]
\begin{tkzelements}
- scale = .75
- z.O = point: new (2,2)
- z.Op = point: new (-4,1)
- z.P = point: polar (4,0)
- C.OP = circle: new (z.O,z.P)
- C.Oz1,C.Oz2 = C.OP : orthogonal_from (z.Op)
- z.z1 = C.Oz1.through
- z.z2 = C.Oz2.through
- L.OP = line : new (z.O,z.P)
- C.Opz1 = circle: new (z.Op,z.z1)
- L.T,L.Tp = C.Opz1 : tangent_from (z.O)
- z.T = L.T.pb
- z.Tp = L.Tp.pb
- L.OOp = line : new (z.O,z.Op)
- z.M = L.OOp.mid
+scale = .75
+z.O = point: new (2,2)
+z.Op = point: new (-4,1)
+z.P = point: polar (4,0)
+C.OP = circle: new (z.O,z.P)
+C.Oz1 = C.OP : orthogonal_from (z.Op)
+z.z1 = C.Oz1.through
+L.OP = line : new (z.O,z.P)
+C.Opz1 = circle: new (z.Op,z.z1)
+L.T,L.Tp = C.Opz1 : tangent_from (z.O)
+z.T = L.T.pb
+z.Tp = L.Tp.pb
+L.OOp = line : new (z.O,z.Op)
+z.M = L.OOp.mid
\end{tkzelements}
\begin{tikzpicture}
\tkzGetNodes
@@ -2543,20 +2542,19 @@ z.S,z.T = get_points (C: orthogonal_from (z.C_2))
\begin{tkzelements}
scale = .75
-z.O = point: new (2,2)
-z.Op = point: new (-4,1)
-z.P = point: polar (4,0)
-C.OP = circle: new (z.O,z.P)
-C.Oz1,C.Oz2 = C.OP : orthogonal_from (z.Op)
-z.z1 = C.Oz1.through
-z.z2 = C.Oz2.through
-L.OP = line : new (z.O,z.P)
-C.Opz1 = circle: new (z.Op,z.z1)
-L.T,L.Tp = C.Opz1 : tangent_from (z.O)
-z.T = L.T.pb
-z.Tp = L.Tp.pb
-L.OOp = line : new (z.O,z.Op)
-z.M = L.OOp.mid
+z.O = point: new (2,2)
+z.Op = point: new (-4,1)
+z.P = point: polar (4,0)
+C.OP = circle: new (z.O,z.P)
+C.Oz1 = C.OP : orthogonal_from (z.Op)
+z.z1 = C.Oz1.through
+L.OP = line : new (z.O,z.P)
+C.Opz1 = circle: new (z.Op,z.z1)
+L.T,L.Tp = C.Opz1 : tangent_from (z.O)
+z.T = L.T.pb
+z.Tp = L.Tp.pb
+L.OOp = line : new (z.O,z.Op)
+z.M = L.OOp.mid
\end{tkzelements}
\hspace*{\fill}
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.pdf b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.pdf
deleted file mode 100644
index d05eb7fbb9..0000000000
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.pdf
+++ /dev/null
Binary files differ
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.tex b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.tex
index 101a65ed15..e36bac1aa7 100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.tex
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-main.tex
@@ -21,10 +21,10 @@
headings = small
]{tkz-doc}
\gdef\tkznameofpack{tkz-elements}
-\gdef\tkzversionofpack{1.50c}
+\gdef\tkzversionofpack{1.60c}
\gdef\tkzdateofpack{\today}
\gdef\tkznameofdoc{tkz-elements.pdf}
-\gdef\tkzversionofdoc{1.50c}
+\gdef\tkzversionofdoc{1.60c}
\gdef\tkzdateofdoc{\today}
\gdef\tkzauthorofpack{Alain Matthes}
\gdef\tkzadressofauthor{}
@@ -97,7 +97,7 @@
\usepackage[english]{babel}
\usepackage[normalem]{ulem}
\usepackage{multirow,multido,booktabs,cellspace}
-\usepackage{shortvrb,bookmark,caption}
+\usepackage{shortvrb,bookmark,caption,enumitem}
\usepackage{makeidx}
\usepackage[most]{tcolorbox}
@@ -175,7 +175,7 @@ sharp corners
\defoffile{\lefthand\
This document brings together some notes about \tkzname{\tkznameofpack}, the first version of a library written in lua, allowing to make all the necessary calculations to define the objects of a Euclidean geometry figure. You need to compile with Lua\LaTeX.\\ With \pkg{tkz-elements}, the definitions and calculations are only done with \pkg{lua}. \\ The main possibility of programmation proposed is oriented "object programming" with object classes like point, line, triangle, circle and ellipse. For the moment, once the calculations are done, it is \pkg{tkz-euclide} or \pkg{TikZ} which allows the drawings.\\
- I discovered Lua and object-oriented programming when I created this package, so it's highly probable that I've made a few mistakes. If you'd like to participate in the development of this package or give me advice on how to proceed, please contact me via my email. \\ This version \tkzversionofpack\ is a beta version.\\
+ I discovered Lua and object-oriented programming when I created this package, so it's highly probable that I've made a few mistakes. If you'd like to participate in the development of this package or give me advice on how to proceed, please contact me via my email. \\
English is not my native language so there might be some errors.
}
@@ -183,7 +183,8 @@ English is not my native language so there might be some errors.
\vspace*{1cm}
-\lefthand\ Acknowledgements : I received much valuable advice, remarks, corrections from \\ \tkzimp{Nicolas Kisselhoff}, \tkzimp{David Carlisle}, \tkzimp{Roberto Giacomelli} and \tkzimp{Qrrbrbirlbel}.
+\lefthand\ Acknowledgements : I received much valuable advice, remarks, corrections from \\ \tkzimp{Nicolas Kisselhoff}, \tkzimp{David Carlisle}, \tkzimp{Roberto Giacomelli} and \tkzimp{Qrrbrbirlbel}.\\
+ Thanks to Wolfgang Büchel, for correcting the examples.
\vspace*{12pt}
\lefthand\ I would also like to thank \tkzimp{Eric Weisstein}, creator of
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-presentation.tex b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-presentation.tex
index 900bdef5e6..b02c8cc0ba 100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-presentation.tex
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-presentation.tex
@@ -130,25 +130,25 @@ When all the points necessary for the drawing are obtained, they must be transfo
\begin{tkzelements}
z.A = point: new (0 , 0)
-z.B = point: new (10 , 0) creation of two fixed points $A$ and $B$
+z.B = point: new (10 , 0) -- creation of two fixed points $A$ and $B$
L.AB = line: new ( z.A, z.B)
-z.C = L.AB: gold_ratio () use of a method linked to "line"
-z.O_0 = line: new ( z.A, z.B).mid midpoint of segment with an attribute of "line"
-z.O_1 = line: new ( z.A, z.C).mid objects are not stored and cannot be reused.
+z.C = L.AB: gold_ratio () -- use of a method linked to "line"
+z.O_0 = line: new ( z.A, z.B).mid -- midpoint of segment with an attribute of "line"
+z.O_1 = line: new ( z.A, z.C).mid -- objects are not stored and cannot be reused.
z.O_2 = line: new ( z.C, z.B).mid
-C.AB = circle: new ( z.O_0, z.B) new object "circle" stored and reused
+C.AB = circle: new ( z.O_0, z.B) -- new object "circle" stored and reused
C.AC = circle: new ( z.O_1, z.C)
C.CB = circle: new ( z.O_2, z.B)
-z.P = C.CB.north "north" atrributes of a circle
+z.P = C.CB.north -- "north" atrributes of a circle
z.Q = C.AC.north
z.O = C.AB.south
-z.c = z.C : north (2) "north" method of a point (needs a parameter)
+z.c = z.C : north (2) -- "north" method of a point (needs a parameter)
C.PC = circle: new ( z.P, z.C)
C.QA = circle: new ( z.Q, z.A)
-z.P_0 = intersection (C.PC,C.AB) search for intersections of two circles.
-z.P_1 = intersection (C.PC,C.AC) idem
-_,z.P_2 = intersection (C.QA,C.CB) idem
-z.O_3 = triangle: new ( z.P_0, z.P_1, z.P_2).circumcenter attribute of "triangle"
+z.P_0 = intersection (C.PC,C.AB) -- search for intersections of two circles.
+z.P_1 = intersection (C.PC,C.AC) -- idem
+_,z.P_2 = intersection (C.QA,C.CB) -- idem
+z.O_3 = triangle: new ( z.P_0, z.P_1, z.P_2) -- circumcenter attribute of "triangle"
\end{tkzelements}
\begin{tikzpicture}
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-transferts.tex b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-transferts.tex
index 8106fbd2e8..dc177d09be 100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-transferts.tex
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/latex/TKZdoc-elements-transferts.tex
@@ -134,12 +134,8 @@ The intersection of the two lines lies at
\tkzLabelPoints(a,...,d)
\end{tikzpicture}
\hspace{\fill}
-
-
-
% subsubsection other_transfers (end)
% subsubsection points_transfer (end)
-
% section transferts (end)
\endinput \ No newline at end of file
diff --git a/macros/latex/contrib/tkz/tkz-elements/doc/tkz-elements.pdf b/macros/latex/contrib/tkz/tkz-elements/doc/tkz-elements.pdf
index d05eb7fbb9..25c613e374 100644
--- a/macros/latex/contrib/tkz/tkz-elements/doc/tkz-elements.pdf
+++ b/macros/latex/contrib/tkz/tkz-elements/doc/tkz-elements.pdf
Binary files differ
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz-elements.sty b/macros/latex/contrib/tkz/tkz-elements/latex/tkz-elements.sty
index e8d633c9f6..f3dd61e9e8 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz-elements.sty
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz-elements.sty
@@ -1,5 +1,5 @@
% encoding : utf8
-% tkz-elements.sty v1.50c
+% tkz-elements.sty v1.60c
% Copyright 2023 Alain Matthes
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either version 1.3
@@ -11,7 +11,7 @@
% This work has the LPPL maintenance status “maintained”.
% The Current Maintainer of this work is Alain Matthes.
-\ProvidesPackage{tkz-elements}[23/12/08 v1.50c Graphic Object Library]
+\ProvidesPackage{tkz-elements}[23/12/14 v1.60c Graphic Object Library]
\RequirePackage{luacode}
\directlua{require "tkz_elements_main"}
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_circle.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_circle.lua
index 91ff4f659e..6329495465 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_circle.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_circle.lua
@@ -1,6 +1,6 @@
-- tkz_elements-circles.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
@@ -95,7 +95,7 @@ function circle: set_inversion (...)
end
function circle: midarc (z1,z2)
- local phi = 0.5 * get_angle_(self.center,z1,z2 )
+ local phi = 0.5 * get_angle (self.center,z1,z2 )
return rotation_ (self.center,phi,z1)
end
@@ -112,11 +112,11 @@ return point (self.center.re+self.radius*math.cos(phi),self.center.im+self.radiu
end
function circle: internal_similitude (C)
- return barycenter_ ({self.center,C.radius},{C.center,self.radius})
+ return internal_similitude_ (self.center,self.radius,C.center,C.radius)
end
function circle: external_similitude (C)
- return barycenter_ ({C.center,self.radius},{self.center,-C.radius})
+ return external_similitude_ (self.center,self.radius,C.center,C.radius)
end
-----------------------
-- lines --
@@ -136,13 +136,33 @@ function circle: tangent_from (pt)
t1,t2 = radical_axis_ (self.center,self.through,C.center,C.through)
return line : new (t1,t2)
end
+ -- version 1.60 new
+ function circle : external_tangent(C)
+ local i,t1,t2,k,T1,T2
+ i = barycenter_ ({C.center,self.radius},{self.center,-C.radius})
+ t1,t2 = tangent_from_ (self.center,self.through,i)
+ k = point.mod((C.center-i)/(self.center-i))
+ T1 = homothety_(i,k,t1)
+ T2 = homothety_(i,k,t2)
+ return line : new (t1,T1),line : new (t2,T2)
+ end
+ -- version 1.60 new
+ function circle : internal_tangent(C)
+ local i,t1,t2,k,T1,T2
+ i = barycenter_ ({C.center,self.radius},{self.center,C.radius})
+ t1,t2 = tangent_from_ (self.center,self.through,i)
+ k = -point.mod((C.center-i)/(self.center-i))
+ T1 = homothety_(i,k,t1)
+ T2 = homothety_(i,k,t2)
+ return line : new (t1,T1),line : new (t2,T2)
+ end
-----------------------
-- circles --
-----------------------
function circle: orthogonal_from (pt)
local t1,t2
t1,t2 = tangent_from_ (self.center,self.through,pt)
- return circle : new (pt,t1), circle : new (pt,t2)
+ return circle : new (pt,t1)
end
function circle: orthogonal_through (pta,ptb)
@@ -215,5 +235,6 @@ function circle: draw ()
local frmt = '\\draw (%0.3f,%0.3f) circle [radius=%0.3f];'
tex.sprint(string.format(frmt, x,y,r))
end
+
return circle \ No newline at end of file
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_class.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_class.lua
index fb15fd3b03..a79153db9e 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_class.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_class.lua
@@ -1,6 +1,6 @@
-- tkz_elements_class.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- from class.lua (Simple Lua Classes from Lua-users wiki)
-- Compatible with Lua 5.1 (not 5.0).
-- http://lua-users.org/wiki/SimpleLuaClasses DavidManura
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_ellipse.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_ellipse.lua
index dcac24758b..ecee439aa4 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_ellipse.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_ellipse.lua
@@ -1,6 +1,6 @@
-- tkz_elements-ellipses.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_circles.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_circles.lua
index a45987d1c8..510d73e485 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_circles.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_circles.lua
@@ -1,6 +1,6 @@
-- tkz_elements_functions_circles.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
@@ -29,10 +29,10 @@ function tangent_from_ (c,p,pt)
return intersection_cc_ (o,c,c,p)
end
-function tangent_at_ (a,b,p)
+function tangent_at_ (a,p)
return rotation_ (p,math.pi/2,a),rotation_ (p,-math.pi/2,a)
end
-
+
function orthogonal_from_ (a,b,p)
return tangent_from_ (a,b,p)
end
@@ -98,3 +98,19 @@ end
function antipode_ (c,pt)
return 2 * c - pt
end
+
+function internal_similitude_ (c1,r1,c2,r2)
+ return barycenter_ ({c2,r1},{c1,r2})
+end
+
+function external_similitude_ (c1,r1,c2,r2)
+ return barycenter_ ({c2,r1},{c1,-r2})
+end
+
+function circlepoint_ (c,t,k)
+ local phi = 2*k* math.pi
+ return rotation_ (c,phi,t)
+end
+
+
+ \ No newline at end of file
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_intersections.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_intersections.lua
index 5c2a754352..a25e2ce78c 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_intersections.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_intersections.lua
@@ -1,6 +1,6 @@
-- tkz_elements_intersections.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_lines.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_lines.lua
index 98f16d499b..5d1dcd99ce 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_lines.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_lines.lua
@@ -1,6 +1,6 @@
-- tkz_elements_functions_lines.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
@@ -129,4 +129,16 @@ end
function square_ (a,b)
return rotation_ (b,-math.pi/2,a), rotation_ (a,math.pi/2,b)
+end
+
+function in_segment_ (a,b,pt)
+ local sc,epsilon
+ epsilon = 10^(-12)
+ sc = point.mod (pt-a) + point.mod (pt-b) - point.mod(b-a)
+ if sc <= epsilon
+ then
+ return true
+ else
+ return false
+ end
end \ No newline at end of file
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_maths.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_maths.lua
index c0b3effa0b..ca948b4334 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_maths.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_maths.lua
@@ -1,6 +1,6 @@
-- tkz_elements_functions_maths.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
@@ -76,7 +76,6 @@ function isortho (z1,z2,z3)
end
end
-
function parabola (a,b,c)
local xa,xb,xc,ya,yb,yc
xa = a.re
@@ -101,7 +100,7 @@ function real (v)
end
function get_angle (a,b,c)
- return angle_normalize(get_angle_( a,b,c ))
+ return angle_normalize_(get_angle_( a,b,c ))
end
function get_angle_( a,b,c )
@@ -109,6 +108,10 @@ function get_angle_( a,b,c )
end
function angle_normalize (a)
+return angle_normalize_ (a)
+end
+
+function angle_normalize_ (a)
local dblpi
dblpi = 2 * math.pi
if a > dblpi
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_points.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_points.lua
index b396194148..23ee73f0c4 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_points.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_points.lua
@@ -1,6 +1,6 @@
-- tkz_elements_functions_points.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_regular.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_regular.lua
index 3beff723ad..70322a3d3f 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_regular.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_regular.lua
@@ -1,6 +1,6 @@
-- tkz_elements_functions_regular.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_triangles.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_triangles.lua
index 90781d961b..ab78d29cf2 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_triangles.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_functions_triangles.lua
@@ -1,6 +1,6 @@
-- tkz_elements_functions_triangles.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_line.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_line.lua
index f4169506fc..2ea0c1fa84 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_line.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_line.lua
@@ -1,6 +1,6 @@
-- tkz_elements_lines.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
@@ -69,6 +69,17 @@ function line: in_out (pt)
end
end
+function line: in_out_segment (pt)
+ local sc,epsilon
+ epsilon = 10^(-12)
+ sc = point.mod (pt-self.pa) + point.mod (pt-self.pb) - point.mod(self.pb-self.pa)
+ if sc <= epsilon
+ then
+ return true
+ else
+ return false
+ end
+end
-------------------
-- Result -> point
-------------------
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_main.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_main.lua
index 86239953b6..7228a3396d 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_main.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_main.lua
@@ -1,6 +1,6 @@
-- tkz_elements-main.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_misc.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_misc.lua
index f5f74a9a41..834317aae4 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_misc.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_misc.lua
@@ -1,6 +1,6 @@
-- tkz_elements_functions_maths.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
@@ -33,16 +33,78 @@ function set_lua_to_tex (t)
token.set_macro(v,_ENV[v],'global')
end
end
-
+-- version 1.60 center pour deux cercles ?
function radical_center (C1,C2,C3)
local t1,t2,t3,t4
- t1,t2 = radical_axis_ (C3.center,C3.through,C1.center,C1.through)
+ t1,t2 = radical_axis_ (C1.center,C1.through,C2.center,C2.through)
+ if C3 == nil then
+ return intersection_ll_ (t1,t2,C1.center,C2.center)
+ else
t3,t4 = radical_axis_ (C3.center,C3.through,C2.center,C2.through)
return intersection_ll_ (t1,t2,t3,t4)
end
-
+end
+-- version 1.60 modif case 2 circles
function radical_circle (C1,C2,C3)
local rc
+ if C3 == nil then
+ rc = radical_center (C1,C2)
+ return C1 : orthogonal_from (rc)
+ else
rc = radical_center (C1,C2,C3)
return C1 : orthogonal_from (rc)
end
+end
+-- version 1.60 new
+function circles_position(C1,C2)
+ local d,max,min
+ d = point.mod(C1.center-C2.center)
+ max = C1.radius + C2.radius
+ min = math.abs ( C1.radius - C2.radius)
+ if d > max then return "outside"
+ elseif d == max then return "outside tangent" -- epsilon
+ elseif d == min then return "inside tangent" -- epsilon
+ elseif d < min then return "inside"
+ else return "intersect"
+ end
+end
+-- version 1.60 new
+function midcircle_(C1,C2)
+ local state,r,s,t1,t2,T1,T2,p,a,b,c,d,Cx,Cy,i,j
+ state = circles_position(C1,C2)
+ i = barycenter_ ({C2.center,C1.radius},{C1.center,-C2.radius})
+ j = barycenter_ ({C2.center,C1.radius},{C1.center,C2.radius})
+ t1,t2 = tangent_from_ (C1.center,C1.through,i)
+ T1,T2 = tangent_from_ (C2.center,C2.through,i)
+
+ if (state == 'outside') or (state == 'outside tangent')then
+ p = math.sqrt(point.mod(i-t1)*point.mod(i-T1))
+ return circle : radius (i,p)
+ elseif state == 'intersect' then
+ r,s = intersection (C1,C2)
+ return circle : radius (i,point.mod(r-i)) , circle : radius (j,point.mod(r-j))
+ elseif (state == 'inside') or (state == 'inside tangent') then
+ a,b = intersection_lc_ (C1.center,C2.center,C1.center,C1.through)
+ c,d = intersection_lc_ (C1.center,C2.center,C2.center,C2.through)
+
+ if C1.radius < C2.radius then
+ z.u, z.v, z.r, z.s = a, b, c, d
+ else
+ z.u, z.v, z.r, z.s = c, d, a, b
+ end
+
+ if (in_segment_ (z.s,z.v,z.u) == true)
+ then
+ Cx = circle : diameter (z.r,z.v)
+ Cy = circle : diameter (z.u,z.s)
+ else
+ Cx = circle : diameter (z.s,z.v)
+ Cy = circle : diameter (z.u,z.r)
+ end
+ if (Cx.radius) < (Cy.radius) then
+ return Cy : orthogonal_from (j)
+ else
+ return Cx : orthogonal_from (j)
+ end
+ end
+end \ No newline at end of file
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_parallelogram.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_parallelogram.lua
index 4839dce030..4b5124ecc0 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_parallelogram.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_parallelogram.lua
@@ -1,6 +1,6 @@
-- tkz_elements_parallelogram.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
@@ -24,7 +24,7 @@ function parallelogram: new (za, zb, zc,zd)
if point.abs (zj-zi) < epsilon then else error ("it's not a parallelogram")
end
local type = 'parallelogram'
- local i = midpoint_ (za,zc)
+ local center = midpoint_ (za,zc)
local ab = line : new (za,zb)
local bc = line : new (zb,zc)
local cd = line : new (zc,zd)
@@ -41,7 +41,7 @@ function parallelogram: new (za, zb, zc,zd)
da = da,
cd = cd,
bd = bd,
- i = i,
+ center = center,
type = type }
setmetatable(o, self)
self.__index = self
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_point.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_point.lua
index c2a12932f7..53e662541a 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_point.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_point.lua
@@ -1,6 +1,6 @@
-- tkz_elements_point.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_quadrilateral.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_quadrilateral.lua
index 011970ef53..ff144a5e5b 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_quadrilateral.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_quadrilateral.lua
@@ -1,6 +1,6 @@
-- tkz_elements_quadrilateral.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_rectangle.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_rectangle.lua
index 7c53646978..21d227a940 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_rectangle.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_rectangle.lua
@@ -1,6 +1,6 @@
-- tkz_elements-rectangle.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_regular.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_regular.lua
index bcf899f549..d458fbe97e 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_regular.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_regular.lua
@@ -1,6 +1,6 @@
-- tkz_elements_regular.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_square.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_square.lua
index 3e3724cd33..f8cc6b14df 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_square.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_square.lua
@@ -1,6 +1,6 @@
-- tkz_elements-square.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_triangle.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_triangle.lua
index 356b4cc76a..fb70474d22 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_triangle.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_triangle.lua
@@ -1,6 +1,6 @@
-- tkz_elements_triangles.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_vector.lua b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_vector.lua
index 3ac9aa877c..17aad462ed 100644
--- a/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_vector.lua
+++ b/macros/latex/contrib/tkz/tkz-elements/latex/tkz_elements_vector.lua
@@ -1,6 +1,6 @@
-- tkz_elements_vectors.lua
--- date 23/12/08
--- version 1.50c
+-- date 23/12/14
+-- version 1.60c
-- Copyright 2023 Alain Matthes
-- This work may be distributed and/or modified under the
-- conditions of the LaTeX Project Public License, either version 1.3
diff --git a/macros/latex/contrib/unbtex/README.md b/macros/latex/contrib/unbtex/README.md
index ab1ed67dfd..a5ceb2f316 100644
--- a/macros/latex/contrib/unbtex/README.md
+++ b/macros/latex/contrib/unbtex/README.md
@@ -1,6 +1,6 @@
# UnBTeX: A class for bachelor, master, and doctoral thesis at the
-University of Brasilia (UnB), Brazil.
-Version 1.4.1 2023/11/27
+# University of Brasilia (UnB), Brazil.
+# Version 1.4.2 2023/12/15
Copyright (C) 2021-2023 by Henrique C. Ferreira <hcferreira@unb.br>
@@ -81,6 +81,13 @@ Here is a history of changes:
. Spacing between figures/tables and text has been adjusted
. Spacing between text and title of sections has been compacted
. Spacing in list environments has been adjusted
+ 1.4.2 (2023-12-15):
+ . Cross-references to the appendix and annex using the cref command
+ have been corrected
+ . The lists of abbreviations and acronyms, as well as the list of symbols,
+ have been enhanced, and page numbering has been removed
+ . The Cutter code has been removed from the copyright page
+ . The example chapters have been reorganized
## Overleaf
diff --git a/macros/latex/contrib/unbtex/unbtex-example.pdf b/macros/latex/contrib/unbtex/unbtex-example.pdf
index abfc7dd73a..fce7fa264c 100644
--- a/macros/latex/contrib/unbtex/unbtex-example.pdf
+++ b/macros/latex/contrib/unbtex/unbtex-example.pdf
Binary files differ
diff --git a/macros/latex/contrib/unbtex/unbtex-example.tex b/macros/latex/contrib/unbtex/unbtex-example.tex
index 1df03f03e0..39bab94b58 100644
--- a/macros/latex/contrib/unbtex/unbtex-example.tex
+++ b/macros/latex/contrib/unbtex/unbtex-example.tex
@@ -1,7 +1,7 @@
%%
%% UnBTeX: A class for bachelor, master, and doctoral thesis at the
%% University of Brasilia (UnB), Brazil
-%% Version 1.4.1 2023/11/27
+%% Version 1.4.2 2023/12/15
%% Copyright (C) 2021-2023 by Henrique C. Ferreira <hcferreira@unb.br>
%%
%% This class file may be distributed and/or modified under the conditions
@@ -21,8 +21,6 @@
\documentclass[
% -- opções da classe memoir -- https://www.ctan.org/pkg/memoir
12pt, % tamanho da fonte
- openright, % capítulos começam em página ímpar
- % (insere página vazia caso preciso)
oneside, % caso queira imprimir em frente e verso, use twoside,
a4paper, % tamanho do papel.
sumario=tradicional,
@@ -36,10 +34,11 @@
% ---
% Lista na bibliografia o número das páginas que cada referência é citada
-\RequirePackage[english,brazilian,hyperpageref]{backref}
+\RequirePackage[hyperpageref]{backref}
% Bibliografia nas normas da ABNT, formato autor-data
\RequirePackage[alf,abnt-etal-list=0,abnt-etal-cite=3,abnt-emphasize=bf,bibjustif]{abntex2cite}
\addtociteoptionlist{abnt-url-package=url}
+% retira os limitadores < e > dos hiperlinks
\def\UrlLeft{}
\def\UrlRight{}
\urlstyle{same}
@@ -51,41 +50,50 @@
% ---
% ---
-% Compila lista de siglas de siglas e abreviaturas e lista de símbolos
+% Lista de siglas e abreviaturas e lista de símbolos
% ---
-\RequirePackage[refpage]{nomencl} % Para gerar lista de siglas e abreviações e lista de símbolos
-\newcommand{\makenomencl}{
-\makenomenclature
+\RequirePackage{nomencl}
+%\RequirePackage[refpage]{nomencl} % Para imprimir página onde o símbolo foi registrado
\renewcommand{\nomname}{\listadesiglasname}
-\def\pagedeclaration##1{\dotfill\hyperlink{page.##1}{\nobreakspace##1}\par}
-\renewcommand{\nomgroup}[1]{%
- % A primeira lista é a de abreviaturas e siglas
- \ifstrequal{##1}{A}{\vspace{-36pt}
- \item[]%
- }{%
- \ifstrequal{##1}{B}{
- % Força a criação de uma nova lista, a lista de símbolos
- \cleardoublepage\chapter*{\hspace{-\leftmargin}\listadesimbolosname}
- % Cria o grupo de símbolos romanos
- \item[{\bfseries\color{verdeunb}\sffamily\large Símbolos romanos}]}{}
- }{%
- \ifstrequal{##1}{C}{\vspace{20pt}
- % Cria o grupo de símbolos gregos
- \item[{\bfseries\color{verdeunb}\sffamily\large Símbolos gregos}]
- }{}
- }{%
- \ifstrequal{##1}{D}{\vspace{20pt} \item[{\bfseries\color{verdeunb}\sffamily\large Nome do grupo}]}{}}%
- \hspace*{-\leftmargin}\vspace{12pt}%
-} % Os nomes (e quantidade) dos subgrupos da lista de símbolos pode ser customizados
-% https://tex.stackexchange.com/questions/257076/customize-vertical-space-of-entries-and-subgroup-names-in-nomenclature
+% Imprime a página onde o símbolo foi registrado
+%\def\pagedeclaration#1{\dotfill\hyperlink{page.#1}{\nobreakspace#1}\par}
+% Espaço entre os itens das listas
+\setlength{\nomitemsep}{-\parsep}
+% Separa os grupos das listas e imprime
+\newcommand{\nomenclheader}[1]{\section*{\hspace*{-\leftmargin}#1}}
+\renewcommand\nomgroup[1]{%
+ \IfStrEqCase{#1}{%
+ {A}{\vspace{-42pt}\nomenclheader{}} % Lista de abreviaturas e siglas
+ {B}{\cleardoublepage % Quebra de página
+ \PRIVATEbookmarkthis{\listadesimbolosname}
+ \chapter*{\hspace*{-\leftmargin}\listadesimbolosname} % Lista de símbolos
+ \vspace{-12pt}\nomenclheader{\nomBname}} % Símbolos romanos
+ {C}{\nomenclheader{\nomCname}} % Símbolos gregos
+ {X}{\nomenclheader{\nomXname}} % Sobrescritos
+ {Z}{\nomenclheader{\nomZname}} % Subscritos
+ }%
}
-
-% ---
-% Compila a nomenclatura
-% ---
-\makenomencl
+% Compila as listas
+\makenomenclature
+% Ajusta largura da margem da descrição
+\RequirePackage{xpatch}
+\makeatletter
+\xapptocmd\thenomenclature{\let\@item\nomencl@item\def\nomencl@width{0pt}}{}{}
+\let\nomencl@item\@item
+\xpretocmd\nomencl@item{\nomencl@measure{#1}}{}{}
+\def\nomencl@measure#1{%
+ \sbox0{#1}%
+ \ifdim\wd0>\nomencl@width\relax
+ \edef\nomencl@width{\the\wd0}%
+ \fi
+}
+\xapptocmd\endthenomenclature{%
+ \immediate\write\@mainaux{\global\nomlabelwidth\nomencl@width\relax}%
+}{}{}
+\makeatother
% ---
+% ---
% Diretório das figuras
\graphicspath{{unbtex-example/figuras/}}
% ---
@@ -125,8 +133,8 @@
% Local e data
\local{Brasília}
-\dia{27}
-\mes{novembro}
+\dia{15}
+\mes{dezembro}
\ano{2023}
% Palavras-chave (pelo menos três devem ser informadas)
@@ -140,9 +148,7 @@
\kwordiv{Keyword 4} % deixar vazio se não tiver
% Código Cutter para a ficha catalográfica:
-% A ficha catalográfica deve conter o código Cutter, que pode ser obtido com a ajuda de alguns sites da internet (por exemplo, https://www.tabelacutter.com/). O sobrenome do primeiro autor é associado a um número com dois ou três dígitos, que deve ser utilizado como argumento do comando \numerocutter presente no arquivo *.tex principal do relatório. No caso de nomes como Carlos de Souza, utilize 'Souza, Carlos de' (e não 'de Souza, Carlos') para gerar o código.
-% Quando compilar o arquivo, a ficha catalográfica gerada terá antes e depois do número de dois ou três dígitos, a primeira letra do sobrenome (em maiúsculo) e a primeira letra do título do trabalho (em minúscula), respectivamente.
-\numerocutter{000} % Correspondente ao seu nome (encontre, por exemplo, no site https://www.tabelacutter.com/)
+%\numerocutter{000} % Correspondente ao seu nome (encontre, por exemplo, no site https://www.tabelacutter.com/)
% Membros da banca
\membrodabancai{Prof. Dr. Lourenço Nassib Chehab, UnB/FT/ENE} % Membro 1 - Geralmente é o orientador
@@ -164,7 +170,9 @@
% ------------------------------------------------------------------------
\begin{document}
-% Alterar para o idioma no qual o trabalho será escrito
+% ---
+% Selecionar o idioma no qual o trabalho será escrito
+% ---
\selectlanguage{brazil}
%\selectlanguage{english} % Para trabalhos escritos em inglês, é obrigatório conter um apêndice com resumo estendido em língua portuguesa.
@@ -173,45 +181,52 @@
\renewcommand{\bibname}{Referências}
\renewcommand{\orientadorname}{Orientador} % O gênero pode ser alterado para Orientadora
\renewcommand{\coorientadorname}{Coorientador} % O gênero pode ser alterado para Coorientadora
-\renewcommand{\anexoname}{Anexo}
\renewcommand{\apendicename}{Apêndice}
+\renewcommand{\anexoname}{anexo}
+\renewcommand{\anexosname}{anexos}
+\newcommand{\Anexoname}{Anexo}
+\newcommand{\Anexosname}{Anexos}
\renewcommand{\listfigurename}{Lista de figuras}
+\newcommand{\nomBname}{Símbolos romanos}
+\newcommand{\nomCname}{Símbolos gregos}
+\renewcommand{\nomXname}{Sobrescritos}
+\renewcommand{\nomZname}{Subscritos}
+\newcommand{\nocitation}{Nenhuma citação no texto.}
+\newcommand{\citedp}{Citado na p.}
+\newcommand{\citedpp}{Citado nas pp.}
}{
\thmnameen
\renewcommand{\bibname}{References}
\renewcommand{\orientadorname}{Orientador} % Não alterar para Supervisor/Advisor, mesmo que o trabalho seja em inglês
\renewcommand{\coorientadorname}{Coorientador} % Não alterar para Co-Supervisor/Co-Advisor, mesmo que o trabalho seja em inglês
\renewcommand{\agradecimentosname}{Agradecimentos} % Comente esta linha caso queira escrever os agradecimentos em inglês
-\renewcommand{\anexoname}{Annex}
\renewcommand{\apendicename}{Appendix}
+\renewcommand{\anexoname}{annex}
+\renewcommand{\anexosname}{annexes}
+\newcommand{\Anexoname}{Annex}
+\newcommand{\Anexosname}{Annexes}
\renewcommand{\listfigurename}{List of figures}
\renewcommand{\listtablename}{List of tables}
+\newcommand{\nomBname}{Roman letters}
+\newcommand{\nomCname}{Greek letters}
+\renewcommand{\nomXname}{Superscripts}
+\renewcommand{\nomZname}{Subscripts}
+\newcommand{\nocitation}{No citations.}
+\newcommand{\citedp}{Cit. on p.}
+\newcommand{\citedpp}{Cit. on pp.}
}
+% ---
+% ---
% Configurações do pacote backref
-% Usado sem a opção hyperpageref de backref
-\IfStrEq*{\languagename}{brazil}{
-\renewcommand{\backrefpagesname}{Citado na(s) página(s):~}
-% Texto padrão antes do número das páginas
-\renewcommand{\backref}{}
+% ---
% Define os textos da citação
+\renewcommand*{\backref}[1]{}
\renewcommand*{\backrefalt}[4]{
- \ifcase #1 %
- Nenhuma citação no texto.%
- \or
- Citado na p. #2.%
- \else
- Citado nas pp. #2.%
- \fi}%
-}{
-\renewcommand*{\backrefalt}[4]{%
- \ifcase #1 %
- No citations.%
- \or
- Cit. on p. #2.%
- \else
- Cit. on pp. #2.%
- \fi}
+ \ifcase #1 \nocitation
+ \or \citedp~#2.
+ \else \citedpp~#2.
+ \fi
}
% ---
@@ -369,10 +384,8 @@ This is the english abstract.
% ---
% Insere as listas de abreviaturas e siglas e de símbolos
% ---
-%{\SingleSpacing
-\setlength{\nomitemsep}{-\parsep}
-\printnomenclature[1.2cm]
-% A opção do comando \printnomenclature define a largura da primeira coluna das listas
+\PRIVATEbookmarkthis{\listadesiglasname}
+\printnomenclature
\cleardoublepage
% ---
@@ -435,13 +448,12 @@ This is the english abstract.
}{
\bibliographystyle{unbtexcite-en}
}
-% Arquivos com as referências bibliográficas
-\bibliography{unbtex-example/referencias,unbtex-example/references}
+% Arquivo com as referências bibliográficas
+\bibliography{unbtex-example/referencias}
% ---
% Apêndices
% ---
-
\begin{apendicesenv}
% Imprime uma página indicando o início dos apêndices
@@ -457,7 +469,6 @@ This is the english abstract.
% ---
% Anexos
% ---
-
\begin{anexosenv}
% Imprime uma página indicando o início dos anexos
diff --git a/macros/latex/contrib/unbtex/unbtex-example/anexo-a.tex b/macros/latex/contrib/unbtex/unbtex-example/anexo-a.tex
index ab842bb745..ecb054d1a1 100644
--- a/macros/latex/contrib/unbtex/unbtex-example/anexo-a.tex
+++ b/macros/latex/contrib/unbtex/unbtex-example/anexo-a.tex
@@ -1,5 +1,5 @@
% ----------------------------------------------------------
-\chapter{Figuras de exemplo}
+\chapter{Figuras de exemplo}\label{anx:fig}
% ----------------------------------------------------------
% Fonte: https://tex.stackexchange.com/a/231741/91816 (Gonzalo Medina)
diff --git a/macros/latex/contrib/unbtex/unbtex-example/anexo-b.tex b/macros/latex/contrib/unbtex/unbtex-example/anexo-b.tex
index b04806faa1..b74fa71981 100644
--- a/macros/latex/contrib/unbtex/unbtex-example/anexo-b.tex
+++ b/macros/latex/contrib/unbtex/unbtex-example/anexo-b.tex
@@ -1,5 +1,5 @@
% ----------------------------------------------------------
-\chapter{Logo LaTeX}
+\chapter{Logo LaTeX}\label{anx:logo}
% ----------------------------------------------------------
\vfill
diff --git a/macros/latex/contrib/unbtex/unbtex-example/apendice-a.tex b/macros/latex/contrib/unbtex/unbtex-example/apendice-a.tex
index fa08776445..d0c5396ae7 100644
--- a/macros/latex/contrib/unbtex/unbtex-example/apendice-a.tex
+++ b/macros/latex/contrib/unbtex/unbtex-example/apendice-a.tex
@@ -1,8 +1,8 @@
% ----------------------------------------------------------
-\chapter{Citações}
+\chapter{Citações}\label{apd:cit}
% ----------------------------------------------------------
-Este modelo usa Bib\TeX\ para configurar as referências. Os arquivo referencias.bib e references.bib contêm várias entradas de bibliografia como modelos \cite{article,book,booklet,inbook}. Esses modelos podem ser utilizados para incluir outras entradas e citá-las por meio do seguinte comando:
+Este modelo usa o Bib\TeX\ para configurar as referências. Os arquivo \texttt{referencias.bib} e \texttt{references.bib} contêm várias entradas de bibliografia como modelos \cite{article,book,booklet,inbook}. Esses modelos podem ser utilizados para incluir outras entradas e citá-las por meio do seguinte comando:
\begin{verbatim}
\cite{nome_da_entrada}
\end{verbatim}
diff --git a/macros/latex/contrib/unbtex/unbtex-example/capitulo2.tex b/macros/latex/contrib/unbtex/unbtex-example/capitulo2.tex
index 7616e974ab..ceb9ceaea5 100644
--- a/macros/latex/contrib/unbtex/unbtex-example/capitulo2.tex
+++ b/macros/latex/contrib/unbtex/unbtex-example/capitulo2.tex
@@ -12,43 +12,6 @@ Este capítulo ilustra o uso de comandos do \LaTeX, do \abnTeX\ e do UnB\TeX.
A codificação de todos os arquivos do \abnTeX\ é \texttt{UTF8}. É necessário que você utilize a mesma codificação nos documentos que escrever, inclusive nos arquivos de base bibliográficas \texttt{bib}.
% ---
-\section{Citações diretas}\label{sec:citacao}
-% ---
-
-Utilize o ambiente \texttt{citacao} para incluir citações diretas com mais de três linhas:
-\begin{citacao}
-As citações diretas, no texto, com mais de três linhas, devem ser destacadas com recuo de 4 cm da margem esquerda, com letra menor que a do texto utilizado e sem as aspas. No caso de documentos datilografados, deve-se observar apenas o recuo \cite[seção 5.3]{NBR10520:2002}.
-\end{citacao}
-
-Use o ambiente assim:
-\begin{verbatim}
-\begin{citacao}
-As citações diretas, no texto, com mais de três linhas [...] deve-se observar
-apenas o recuo \cite[seção 5.3]{NBR10520:2002}.
-\end{citacao}
-\end{verbatim}
-
-O ambiente \texttt{citacao} pode receber como parâmetro opcional um nome de idioma previamente carregado nas opções da classe (\cref{sec:hifenizacao}). Nesse caso, o texto da citação é automaticamente escrito em itálico e a hifenização é ajustada para o idioma selecionado na opção do ambiente. Por exemplo:
-\begin{verbatim}
-\begin{citacao}[english]
-Text in English language in italic with correct hyphenation.
-\end{citacao}
-\end{verbatim}
-
-Tem como resultado:
-\begin{citacao}[english]
-Text in English language in italic with correct hyphenation.
-\end{citacao}
-
-Citações simples, com até três linhas, devem ser incluídas com aspas. Observe que em \LaTeX\ as aspas iniciais são diferentes das finais: ``Amor é fogo que arde sem se ver''.
-
-% ---
-\section{Notas de rodapé}
-% ---
-
-As notas de rodapé são detalhadas pela NBR 14724:2011 na seção 5.2.1\footnote{As notas devem ser digitadas ou datilografadas dentro das margens, ficando separadas do texto por um espaço simples de entre as linhas e por filete de 5 cm, a partir da margem esquerda. Devem ser alinhadas, a partir da segunda linha da mesma nota, abaixo da primeira letra da primeira palavra, de forma a destacar o expoente, sem espaço entre elas e com fonte menor \citeonline[seção 5.2.1]{NBR14724:2011}.}\footnote{Caso uma série de notas sejam criadas sequencialmente, o \abnTeX\ instrui o \LaTeX\ para que uma vírgula seja colocada após cada número do expoente que indica a nota de rodapé no corpo do texto.}\footnote{Verifique se os números do expoente possuem uma vírgula para dividi-los no corpo do texto.}.
-
-% ---
\section{Expressões matemáticas}
\label{sec:mat}
% ---
@@ -75,9 +38,9 @@ Consulte mais informações sobre expressões matemáticas em \url{https://githu
Muitos cientistas gostam de usar \LaTeX\ porque essa ferramenta possibilita escrever facilmente equações como a seguinte:
\begin{equation}
p+\frac{1}{2}{\rho}v^2+{\rho}gh = \text{constante},
-\label{eq:Bernoulli}
+\label{eq:bernoulli}
\end{equation}
-em que $p$ é a pressão, $v$ é a velocidade e $h$ é a elevação, ou seja, a ``altura do tubo''. A \cref{eq:Bernoulli} pode ser deduzida a partir do \textit{Teorema Trabalho-Energia}.
+em que $p$ é a pressão, $v$ é a velocidade e $h$ é a elevação, ou seja, a ``altura do tubo''. A \cref{eq:bernoulli} pode ser deduzida a partir do \textit{Teorema Trabalho-Energia}.
% Definição da nomenclatura que irá para a lista de símbolos
\nomenclature[B]{$p$}{Pressão}
@@ -131,196 +94,113 @@ u_{li}(t) &= - \textrm{sign}(s_{li}(t))\eta. \label{eq:u_xbi}
\nomenclature[C]{$\psi$}{Ângulo de guinada}
% ---
-\section{Tabelas}
+\section{Listas}
% ---
-A \cref{tab:nivinv} é um exemplo de tabela construída em
-\LaTeX.
+As listas de ilustrações (figuras) e de tabelas utilizadas ao longo do trabalho são geradas automaticamente e incluídas entre o \emph{Abstract} e o Sumário.
-\begin{table}[htb]
-\footnotesize
-\caption[Níveis de investigação]{Níveis de investigação}
-\label{tab:nivinv}
-{\renewcommand{\arraystretch}{1.2} % espaçamento entre as linhas da tabela
-\begin{tabular}{p{2.6cm}|p{6.0cm}|p{2.25cm}|p{3.40cm}} %\hline
- \textbf{Nível de Investigação} & \textbf{Insumos} & \textbf{Sistemas de Investigação} & \textbf{Produtos} \\ \hline
- Meta-nível & Filosofia da Ciência & Epistemologia & Paradigma \\ \hline
- Nível do objeto & Paradigmas do metanível e evidências do nível inferior & Ciência & Teorias e modelos \\ \hline
- Nível inferior & Modelos e métodos do nível do objeto e problemas do nível inferior & Prática & Solução de problemas \\ %\hline
-\end{tabular}}
-\fonte{\citeonline{van86}}
-\end{table}
+Para definir um elemento que deverá aparecer na lista de abreviatura e siglas, próximo do texto onde a sigla ou abreviatura aparece, utilize o comando \verb|\nomenclature|. Por exemplo, para definir as siglas que aparecem no primeiro parágrafo do \cref{cap:intr}, foram utilizados os seguintes comandos:
+\begin{verbatim}
+\nomenclature[A]{ABNT}{Associação Brasileira de Normas Técnicas}
+\nomenclature[A]{UnB}{Universidade de Brasília}
+\end{verbatim}
-Já a \cref{tab:ibge} apresenta uma tabela criada conforme o padrão do \citeonline{ibge1993} requerido pelas normas da ABNT para documentos técnicos e acadêmicos.
+Para definir um elemento da lista de símbolos, próximo da equação onde o símbolo aparece, utilize também o comando \verb|\nomenclature|. Por exemplo, para definir os símbolos das equações da \cref{sec:mat}, foram utilizados os comandos:
+\begin{verbatim}
+\nomenclature[B]{$p$}{Pressão}
+\nomenclature[B]{$v$}{Velocidade}
+\nomenclature[B]{$h$}{Elevação}
+\nomenclature[C]{$\theta$}{Ângulo de arfagem}
+\nomenclature[C]{$\phi$}{Ângulo de rolamento}
+\nomenclature[C]{$\psi$}{Ângulo de guinada}
+\end{verbatim}
-\begin{table}[htb]
-\IBGEtab{%
- \caption{Um Exemplo de tabela alinhada que pode ser longa ou curta, conforme padrão IBGE}%
- \label{tab:ibge}
-}{%
- \begin{tabular}{ccc}
- \toprule
- Nome & Nascimento & Documento \\ \midrule \midrule
- Maria da Silva & 11/11/1111 & 111.111.111-11 \\ \midrule
- João Souza & 11/11/2111 & 211.111.111-11 \\ \midrule
- Laura Vicuña & 05/04/1891 & 3111.111.111-11 \\ \bottomrule
-\end{tabular}%
-}{%
- \fonte{Produzido pelos autores.}%
- \nota{Esta é uma nota, que diz que os dados são baseados na regressão linear.}%
- \nota[Anotações]{Uma anotação adicional, que pode ser seguida de várias outras.}%
-}
-\end{table}
+Note que a letra \verb|[A]| de \verb|\nomenclature[A]| indica que o item pertence à lista de abreviaturas e siglas. Já as letras \verb|[B]| em \verb|\nomenclature[B]| e \verb|[C]| em \verb|\nomenclature[C]| referem-se, respectivamente, aos grupos de símbolos romanos e gregos, que compõem a lista de símbolos. As listas e seus grupos estão definidos no arquivo \texttt{unbtex-example.tex}. A ordem de apresentação dos grupos em uma lista segue a ordem alfabética das letras que os designam.
-Na \cref{tab:lvlii} são mostrados os componentes curriculares obrigatórios do 2º nível da nova estrutura curricular do curso de engenharia mecatrônica da UnB.
+% ---
+\section{Remissões internas}
+% ---
-\begin{table}[htb]
-\small
-\begin{center}%
-\caption{Componentes curriculares do segundo nível}
-\label{tab:lvlii}
-{\renewcommand{\arraystretch}{1.2} % espaçamento entre as linhas da tabela
-\begin{tabular}{|m{1.5cm}|m{4.3cm}|m{.7cm}|m{.7cm}|m{.7cm}|m{.7cm}|m{.7cm}|m{2.1cm}|}
-\hline%
-\multicolumn{8}{|l|}{\textbf{2º Nível}} \\\hline%
-\multirow{2}{*}{Código} &
-\multirow{2}{*}{Componente curricular} &
-\multicolumn{5}{c|}{Quantidade de horas} &
-\multirow{2}{*}{Pré-requisito} \\
-\cline{3-7} & & Teo. & Pr. & Ext. & EaD & Tot. & \\\hline\hline%
-MAT0026 & Cálculo 2 & 60 & 30 & 0 & 0 & 90 & MAT0025 \\\hline%
-IFD0171 & Física 1 & 60 & 0 & 0 & 0 & 60 & \\\hline%
-IFD0173 & Física 1 Experimental & 0 & 30 & 0 & 0 & 30 & \\\hline%
-EST0023 & Probabilidade e Estatística & 30 & 30 & 0 & 0 & 60 & MAT0025 \\\hline%
-ENM0190 & Desenho Mecânico para Engenharia & 30 & 30 & 0 & 0 & 60 & \\\hline%
-CIC0090 & Estruturas de Dados & 30 & 30 & 0 & 0 & 60 & CIC0004 \\\hline%
-\multicolumn{6}{|l|}{Componentes optativos ou eletivos} & 60 & \multicolumn{1}{r}{} \\\cline{1-7}%
-\multicolumn{6}{|l|}{Total de horas do 2º Nível} & 420 & \multicolumn{1}{r}{} \\\cline{1-7}%
-\end{tabular}}
-\end{center}%
-\end{table}
+Ao nomear a \cref{sec:mat} e a \cref{eq:bernoulli}, apresentamos um exemplo de remissão interna, que também pode ser feita quando indicamos o \cref{cap:exemplos}, que tem o nome \emph{\nameref{cap:exemplos}}. O número do capítulo indicado é \ref{cap:exemplos}, que se inicia à \cpageref{cap:exemplos}\footnote{O número da página de uma remissão pode ser obtida também assim: \pageref{cap:exemplos}.}.
-É uma boa ideia usar o pacote \textsf{longtable} para criar tabelas, pois assim uma mesma tabela pode ocupar várias páginas. Também há pacotes que rotacionam tabelas, para que fiquem em uma página em formato paisagem. Faça as tabelas usando como base qualquer um dos exemplos aqui apresentados ou outros que considerar mais adequados e que podem ser facilmente encontrados na internet.
+O código usado para produzir o texto desta seção é:
+\begin{verbatim}
+Ao nomear a \cref{sec:mat} e a \cref{eq:bernoulli}, apresentamos um
+exemplo de remissão interna, que também pode ser feita quando indicamos
+o \cref{cap:exemplos}, que tem o nome \emph{\nameref{cap:exemplos}}.
+O número do capítulo indicado é \ref{cap:exemplos}, que se inicia à
+\cpageref{cap:exemplos}\footnote{O número da página de uma remissão
+pode ser obtida também assim: \pageref{cap:exemplos}.}.
+\end{verbatim}
% ---
-\section{Figuras}
+\section{Referências bibliográficas}
% ---
-Existem pacotes que permitem criar figuras e gráficos no próprio código \LaTeX. Por exemplo, temos
+A formatação das referências bibliográficas conforme as regras da ABNT são um dos principais objetivos do \abnTeX. Para obter informações sobre como criar entradas em arquivos \texttt{bib} para diferentes tipos de referências (artigos em periódicos, artigos em anais de eventos, livros, capítulos de livros, etc.) e como utilizá-las, recomenda-se consultar os manuais \citeonline{abntex2cite} e \citeonline{abntex2cite-alf}, disponíveis nos links:
\begin{itemize}
- \item \textsf{PGFPlots}: \url{http://pgfplots.sourceforge.net/}
- \item \textsf{TikZ}: \url{http://www.texample.net/tikz/examples/all/}
- \item \textsf{Metapost}: \url{http://tex.loria.fr/prod-graph/zoonekynd/metapost/metapost.html}
- \item \textsf{PSTricks}: \url{https://tug.org/PSTricks/main.cgi?file=examples}
+\item \url{https://linorg.usp.br/CTAN/macros/latex/contrib/abntex2/doc/abntex2cite.pdf},
+\item \url{https://linorg.usp.br/CTAN/macros/latex/contrib/abntex2/doc/abntex2cite-alf.pdf}.
\end{itemize}
-Figuras também podem ser incorporadas de arquivos externos, como é o caso das \cref{fig:blockdiagram,fig:grafico}. Se a figura que for incluída se tratar de um diagrama, um gráfico ou uma ilustração que você mesmo produza, priorize o uso de imagens vetoriais no formato \texttt{pdf}. Com isso, o tamanho do arquivo final do trabalho será menor, e as imagens terão uma apresentação melhor, principalmente quando impressas, uma vez que imagens vetoriais são perfeitamente escaláveis para qualquer dimensão.
-
-\begin{figure}[tb]
- \centering
- \caption{Sistema de controle em malha fechada}
- \label{fig:blockdiagram}
- \includegraphics[scale=1]{blockdiagram.pdf}
-\end{figure}
+Note que a classe UnB\TeX\ contempla atualizações mais recentes das normas NBR 6023 \cite{NBR6023:2018} e NBR 10520 \cite{NBR10520:2023} da ABNT, não consideradas no \abnTeX. Os arquivos de estilo \texttt{unbtexcite-en.bst} e \texttt{unbtexcite-pt.bst}, ambos para sistema autor-ano, implementam as alterações nas normas, além de customizar as citações para textos escritos em inglês. O estilo da referências bibliográficas é selecionado por meio do comando \verb|\bibliographystyle|.
-\begin{figure}[tb]
- \centering
- \caption{Resposta em frequência de malha aberta}
- \label{fig:grafico}
- \includegraphics[scale=1]{bodediagram.pdf}
-\end{figure}
+Embora as normas da ABNT permitam citações utilizando o formato numérico, é recomendado o uso do sistema autor-ano em trabalhos acadêmicos. A razão é que a leitura por parte do avaliador fica mais simples. Basta ver o nome e o ano para se lembrar rapidamente da referência, sem precisar recorrer frequentemente à lista de referências, que fica no final do texto, tornando a leitura mais agradável.
-Para manter a coerência no uso de software livre (já que você está usando \LaTeX\ e \abnTeX), teste a ferramenta \textsf{InkScape} (\url{http://inkscape.org/}). Ela é uma excelente opção de código-livre para produzir ilustrações vetoriais, similar ao CorelDraw ou ao Adobe Illustrator.
+No formato autor-data, considere chamar as referências usando o comando \verb|\citeonline| com maior frequência que o comando \verb|\cite|. Desse modo, a citação fica melhor incorporada ao texto, outra vantagem do formato autor-data.
-De todo modo, caso não seja possível utilizar arquivos de imagens como \texttt{pdf}, utilize qualquer outro formato, como \texttt{jpeg}, \texttt{gif}, \texttt{bmp}, etc. Nesse caso, você pode tentar aprimorar as imagens incorporadas com o software livre \textsf{Gimp} (\url{http://www.gimp.org/}). Ele é uma alternativa livre ao Adobe Photoshop.
+Para mais detalhes sobre como criar as entradas para cada referência bibliográfica, consulte o \cref{apd:cit}.
-De acordo com as normas da ABNT, numeração e título das figuras e tabelas devem aparecer na parte superior. Na parte inferior deve ser informada a fonte.
+%-
+\subsection{Acentuação de referências bibliográficas}
+%-
-% ---
-\subsection{Figuras em \emph{minipages}}
-% ---
+Normalmente não há problemas em usar caracteres acentuados em arquivos bibliográficos (\texttt{bib}). Porém, como as regras da ABNT fazem uso quase abusivo da conversão para letras maiúsculas, é preciso observar o modo como se escreve os nomes dos autores. Na \cref{tab:acentos} você encontra alguns exemplos das conversões mais importantes. Preste atenção especial para `ç' e `í' que devem estar envoltos em chaves. A regra geral é sempre usar a acentuação neste modo quando houver conversão para letras maiúsculas.
-\emph{Minipages} são usadas para inserir textos ou outros elementos em quadros com tamanhos e posições controladas. Veja os exemplos das \cref{fig:minipage_circuito,fig:minipage_grafico}.
-
-\begin{figure}[htb]
- \label{fig:teste}
- \centering
- \begin{minipage}[t]{0.46\textwidth}
- \centering
- \caption{Imagem da minipage}
- \label{fig:minipage_circuito}
- \includegraphics[scale=1]{circuito.pdf}
- \end{minipage}
- \hfill
- \begin{minipage}[t]{0.52\textwidth}
- \centering
- \caption{Gráfico da minipage}
- \label{fig:minipage_grafico}
- \includegraphics[scale=1.2]{diodocurva.pdf}
- \end{minipage}
-\end{figure}
-
-\subsection{Subfiguras}
-
-O pacote \textsf{subfig} foi utilizado para inserir as \cref{fig:subfigura_circuito,fig:subfigura_grafico}. Subfiguras também podem ser inseridas no texto com o pacote \textsf{subcaption}.
-
-% utiliza o pacote subfig
-\begin{figure}[htb]
- \centering
- \caption{Figura com subfiguras}
- \label{fig:subfiguras}
- \subfloat[Primeira subfigura]{\label{fig:subfigura_circuito} \centering
- \includegraphics[scale=1]{circuito.pdf}}
- \subfloat[Segunda subfigura]{\label{fig:subfigura_grafico} \hspace{0.4em}
- \centering \includegraphics[scale=1.2]{diodocurva.pdf}}
-\end{figure}
-
-% utiliza o pacote subcaption
-%\begin{figure}[htb]
-% \centering
-% \caption{Figura com subfiguras}
-% \label{fig:subfiguras}
-% \begin{subfigure}[t]{0.47\textwidth}
-% \caption{Primeira subfigura}
-% \label{fig:subfigura_circuito}
-% \includegraphics[scale=1]{circuito.pdf}
-% \end{subfigure}%
-% \hfill
-% \begin{subfigure}[t]{0.52\textwidth}
-% \caption{Segunda subfigura}
-% \label{fig:subfigura_grafico}
-% \includegraphics[scale=1.2]{diodocurva.pdf}
-% \end{subfigure}
-%\end{figure}
+\begin{table}[htb]
+\begin{center}
+\caption{Tabela de conversão de acentuação}
+\label{tab:acentos}
+\begin{tabular}{ll} \toprule
+acento & bibtex\\ \midrule\midrule
+à á ã & \verb|\`a| \verb|\'a| \verb|\~a|\\ \midrule
+í & \verb|{\'\i}|\\ \midrule
+ç & \verb|{\c c}|\\ \bottomrule
+\end{tabular}
+\end{center}
+\end{table}
% ---
-\subsection{Obtenção de figuras com texto e equações que usam as mesmas fontes do documento}
+\section{Citações diretas}\label{sec:citacao}
% ---
-Caso queira utilizar a mesma fonte do texto para escrever dentro de figuras, como é o caso da \cref{fig:psfrag1} (arquivo \texttt{blockdiagram.pdf}), produza uma figura como a da \cref{fig:psfrag2} e a salve no formato \texttt{eps} (arquivo \texttt{blockdiagram.eps}). Softwares como InkScape, CorelDraw ou Adobe Ilustrator podem ser utilizados para este fim.
-
-\begin{figure}[htb]
- \centering
- \caption{Uso do pacote \textsf{psfrag}}
- \subfloat[Arquivo \texttt{blockdiagram.pdf}]{\label{fig:psfrag1} \centering
- \includegraphics[scale=1]{blockdiagram.pdf}} \\
- \subfloat[Arquivo \texttt{blockdiagram.eps}]{\label{fig:psfrag2}
- \centering \includegraphics[scale=1]{blockdiagramfrag.eps}}
- \label{fig:psgrag}
-\end{figure}
-
-Crie no Overleaf um projeto nomeado \texttt{blockdiagram} e que tenha, dentro de um arquivo nomeado \texttt{blockdiagram.tex}, o conteúdo mostrado no \cref{cod:tex}.
-
-\lstinputlisting[numbers=none,float,caption={\texttt{blockdiagram.tex}},label={cod:tex}]{unbtex-example/codigos/blockdiagram.tex}
+Utilize o ambiente \texttt{citacao} para incluir citações diretas com mais de três linhas:
+\begin{citacao}
+As citações diretas, no texto, com mais de três linhas, devem ser destacadas com recuo de 4 cm da margem esquerda, com letra menor que a do texto utilizado e sem as aspas. No caso de documentos datilografados, deve-se observar apenas o recuo \cite[seção 5.3]{NBR10520:2002}.
+\end{citacao}
-No menu do Overleaf, defina \texttt{LaTeX} como compilador e o arquivo \texttt{blockdiagram.tex} como principal. Coloque dentro do projeto o arquivo \texttt{blockdiagram.eps} e compile o projeto. A saída gerada corresponde à \cref{fig:psfrag1} e deverá ser salva como \texttt{blockdiagram.pdf}. Este arquivo poderá ser carregado no projeto do texto do trabalho (TCC, dissertação ou tese) que você estiver escrevendo com o UnB\TeX\ (que usa o \texttt{pdfLaTeX} como compilador).
+Use o ambiente assim:
+\begin{verbatim}
+\begin{citacao}
+As citações diretas, no texto, com mais de três linhas [...] deve-se observar
+apenas o recuo \cite[seção 5.3]{NBR10520:2002}.
+\end{citacao}
+\end{verbatim}
-Note no \cref{cod:tex} que o pacote \textsf{psfrag} substitui, por meio do comando
+O ambiente \texttt{citacao} pode receber como parâmetro opcional um nome de idioma previamente carregado nas opções da classe (\cref{sec:hifenizacao}). Nesse caso, o texto da citação é automaticamente escrito em itálico e a hifenização é ajustada para o idioma selecionado na opção do ambiente. Por exemplo:
\begin{verbatim}
-\psfrag{r}[c][c]{\footnotesize $R(s)$}
+\begin{citacao}[english]
+Text in English language in italic with correct hyphenation.
+\end{citacao}
\end{verbatim}
-o ``\texttt{r}'' da figura \texttt{eps} por ``\verb|$R(s)$|'', produzindo ``$R(s)$'' na figura \texttt{pdf}. O pacote \textsf{psfrag} funciona apenas com o compilador \texttt{LaTeX}, o que torna a criação de um novo projeto no Overleaf uma boa solução. Este projeto poderá ser aproveitado para gerar outras figuras do seu trabalho.
+
+Tem como resultado:
+\begin{citacao}[english]
+Text in English language in italic with correct hyphenation.
+\end{citacao}
+
+Citações simples, com até três linhas, devem ser incluídas com aspas. Observe que em \LaTeX\ as aspas iniciais são diferentes das finais: ``Amor é fogo que arde sem se ver''.
% ---
\section{Enumerações: alíneas e subalíneas}
@@ -365,34 +245,10 @@ subdividida em alíneas \cite[seção 4.2]{NBR6024:2012}:
\end{alineas}
% ---
-\section{Inclusão de outros arquivos}\label{sec:include}
-% ---
-
-É uma boa prática dividir o seu documento em diversos arquivos, e não apenas escrever tudo em um único. Esse recurso foi utilizado neste documento. Para incluir diferentes arquivos em um arquivo principal, de modo que cada arquivo incluído fique em uma página diferente, utilize o comando:
-\begin{verbatim}
-\include{documento-a-ser-incluido} % sem a extensão .tex
-\end{verbatim}
-
-Para incluir documentos sem quebra de páginas, utilize:
-\begin{verbatim}
-\input{documento-a-ser-incluido} % sem a extensão .tex
-\end{verbatim}
-
-% ---
-\section{Remissões internas}
+\section{Notas de rodapé}
% ---
-Ao nomear a \cref{tab:nivinv} e a \cref{fig:blockdiagram}, apresentamos um exemplo de remissão interna, que também pode ser feita quando indicamos o \cref{cap:exemplos}, que tem o nome \emph{\nameref{cap:exemplos}}. O número do capítulo indicado é \ref{cap:exemplos}, que se inicia à \cpageref{cap:exemplos}\footnote{O número da página de uma remissão pode ser obtida também assim: \pageref{cap:exemplos}.}.
-
-O código usado para produzir o texto desta seção é:
-\begin{verbatim}
-Ao nomear a \cref{tab:nivinv} e a \cref{fig:syscl}, apresentamos um
-exemplo de remissão interna, que também pode ser feita quando indicamos
-o \cref{cap:exemplos}, que tem o nome \emph{\nameref{cap:exemplos}}.
-O número do capítulo indicado é \ref{cap:exemplos}, que se inicia à
-\cpageref{cap:exemplos}\footnote{O número da página de uma remissão
-pode ser obtida também assim: \pageref{cap:exemplos}.}.
-\end{verbatim}
+As notas de rodapé são detalhadas pela NBR 14724:2011 na seção 5.2.1\footnote{Caso uma série de notas sejam criadas sequencialmente, o \abnTeX\ instrui o \LaTeX\ para que uma vírgula seja colocada após cada número do expoente que indica a nota de rodapé no corpo do texto.}\footnote{Verifique se os números do expoente possuem uma vírgula para dividi-los no corpo do texto.}.
% ---
\section{Diferentes idiomas e hifenizações}
@@ -421,83 +277,37 @@ Isso altera automaticamente a hifenização e todos os nomes constantes de refer
A \cref{sec:citacao} descreve o ambiente \texttt{citacao} que pode receber como parâmetro um idioma a ser usado na citação.
% ---
-\section{Consulte o manual da classe \textsf{abntex2}}
-% ---
-
-Consulte o manual da classe \textsf{abntex2} \cite{abntex2classe} para uma referência completa das macros e ambientes disponíveis.
-
-Além disso, o manual possui informações adicionais sobre as normas ABNT observadas pelo \abnTeX\ e considerações sobre eventuais requisitos específicos não atendidos, como o caso da \citeonline[seção 5.2.2]{NBR14724:2011}, que especifica o espaçamento entre os capítulos e o início do texto, regra propositalmente não atendida pelo presente modelo.
-
-% ---
-\section{Referências bibliográficas}
+\section{Inclusão de outros arquivos}\label{sec:include}
% ---
-A formatação das referências bibliográficas conforme as regras da ABNT são um dos principais objetivos do \abnTeX. Para obter informações sobre como criar entradas em arquivos \texttt{bib} para diferentes tipos de referências (artigos em periódicos, artigos em anais de eventos, livros, capítulos de livros, etc.) e como utilizá-las, recomenda-se consultar os manuais \citeonline{abntex2cite} e \citeonline{abntex2cite-alf}, disponíveis nos links:
-
-\begin{itemize}
-\item \url{https://tug.ctan.org/macros/latex/contrib/abntex2/doc/abntex2cite.pdf},
-\item \url{https://mirrors.ibiblio.org/CTAN/macros/latex/contrib/abntex2/doc/abntex2cite-alf.pdf}.
-\end{itemize}
-
-Note que a classe UnB\TeX\ contempla atualizações mais recentes das normas NBR 6023 \cite{NBR6023:2018} e NBR 10520 \cite{NBR10520:2023} da ABNT, não consideradas no \abnTeX. Os arquivos de estilo \texttt{unbtexcite-en.bst} e \texttt{unbtexcite-pt.bst}, ambos para sistema autor-ano, implementam as alterações nas normas, além de customizar as citações para textos escritos em inglês. O estilo da referências bibliográficas é selecionado por meio do comando \verb|\bibliographystyle|.
-
-Embora as normas da ABNT permitam citações utilizando o formato numérico, é recomendado o uso do sistema autor-ano em trabalhos acadêmicos. A razão é que a leitura por parte do avaliador fica mais simples. Basta ver o nome e o ano para se lembrar rapidamente da referência, sem precisar recorrer frequentemente à lista de referências, que fica no final do texto, tornando a leitura mais agradável.
-
-No formato autor-data, considere chamar as referências usando o comando \verb|\citeonline| com maior frequência que o comando \verb|\cite|. Desse modo, a citação fica melhor incorporada ao texto, outra vantagem do formato autor-data.
-
-%-
-\subsection{Acentuação de referências bibliográficas}
-%-
-
-Normalmente não há problemas em usar caracteres acentuados em arquivos bibliográficos (\texttt{bib}). Porém, como as regras da ABNT fazem uso quase abusivo da conversão para letras maiúsculas, é preciso observar o modo como se escreve os nomes dos autores. Na \cref{tab:acentos} você encontra alguns exemplos das conversões mais importantes. Preste atenção especial para `ç' e `í' que devem estar envoltos em chaves. A regra geral é sempre usar a acentuação neste modo quando houver conversão para letras maiúsculas.
+É uma boa prática dividir o seu documento em diversos arquivos, e não apenas escrever tudo em um único. Esse recurso foi utilizado neste documento. Para incluir diferentes arquivos em um arquivo principal, de modo que cada arquivo incluído fique em uma página diferente, utilize o comando:
+\begin{verbatim}
+\include{documento-a-ser-incluido} % sem a extensão .tex
+\end{verbatim}
-\begin{table}[htbp]
-\begin{center}
-\caption{Tabela de conversão de acentuação}
-\label{tab:acentos}
-\begin{tabular}{ll} \toprule
-acento & bibtex\\ \midrule\midrule
-à á ã & \verb|\`a| \verb|\'a| \verb|\~a|\\ \midrule
-í & \verb|{\'\i}|\\ \midrule
-ç & \verb|{\c c}|\\ \bottomrule
-\end{tabular}
-\end{center}
-\end{table}
+Para incluir documentos sem quebra de páginas, utilize:
+\begin{verbatim}
+\input{documento-a-ser-incluido} % sem a extensão .tex
+\end{verbatim}
% ---
-\section{Listas}
+%\section{Ficha catalográfica com código Cutter-Sanborn}
% ---
+%A Tabela Cutter-Sanborn é uma codificação elaborada por Charles Ammi Cutter e, posteriormente, expandida por Kate F. Sanborn. Na Tabela Cutter-Sanborn, é possível consultar qual sequência numérica representa a sequência do sobrenome do autor.
-As listas de ilustrações (figuras) e de tabelas utilizadas ao longo do trabalho são geradas automaticamente e incluídas entre o \emph{Abstract} e o Sumário.
+%Em vários sites da internet\footnote{\url{https://www.tabelacutter.com/}}\footnote{\url{https://cuttersonline.com.br/registrador-gratuito}} há ferramentas online para obtenção do código. Se o nome do primeiro autor do trabalho for, digamos, Carlos Lisboa, a entrada da ferramenta online deverá ser: \textbf{Lisboa, Carlos}. Nenhuma outra informação é necessária para gerar o código que, no caso desse autor, é \textbf{769}. Considere apenas esses três números. Eventuais letras devem ser ignoradas. No arquivo \texttt{tex} principal do relatório, na linha que tem o comando \verb|\numerocutter| troque por
+%\begin{verbatim}
+%\numerocutter{769}
+%\end{verbatim}
-Para definir um elemento que deverá aparecer na lista de abreviatura e siglas, próximo do texto onde a sigla ou abreviatura aparece, utilize o comando \verb|\nomenclature|. Por exemplo, para definir as siglas que aparecem no primeiro parágrafo do \cref{cap:intr}, foram utilizados os seguintes comandos:
-\begin{verbatim}
-\nomenclature[A]{ABNT}{Associação Brasileira de Normas Técnicas}
-\nomenclature[A]{UnB}{Universidade de Brasília}
-\end{verbatim}
-
-Para definir um elemento da lista de símbolos, próximo da equação onde o símbolo aparece, utilize também o comando \verb|\nomenclature|. Por exemplo, para definir os símbolos das equações da \cref{sec:mat}, foram utilizados os comandos:
-\begin{verbatim}
-\nomenclature[B]{$p$}{Pressão}
-\nomenclature[B]{$v$}{Velocidade}
-\nomenclature[B]{$h$}{Elevação}
-\nomenclature[C]{$\theta$}{Ângulo de arfagem}
-\nomenclature[C]{$\phi$}{Ângulo de rolamento}
-\nomenclature[C]{$\psi$}{Ângulo de guinada}
-\end{verbatim}
+%Esse número aparecerá na ficha catalográfica gerada. Automaticamente será adicionado na frente do número, a letra \textbf{L} maiúscula, que é a primeira letra do sobrenome \textbf{Lisboa}. Será também adicionado, ao final do número, a letra \textbf{m} minúscula, correspondente à primeira letra do título do trabalho (o título desse relatório de exemplo é ``Modelo de trabalho acadêmico com UnB\TeX''). Se seu nome for, por exemplo, Carlos da Silva, utilize como entrada da ferramenta que gera o código: \textbf{Silva, Carlos da}.
-Note que a letra \verb|[A]| de \verb|\nomenclature[A]| indica que o item pertence à lista de abreviaturas e siglas. Já as letras \verb|[B]| em \verb|\nomenclature[B]| e \verb|[C]| em \verb|\nomenclature[C]| referem-se, respectivamente, aos grupos de símbolos romanos e gregos, que compõem a lista de símbolos. As listas e seus grupos estão definidos no arquivo \texttt{unbtex-example.tex}. A ordem de apresentação dos grupos em uma lista segue a ordem alfabética das letras que os designam.
+%A ficha catalográfica é um elemento pré-textual obrigatório para todos os trabalhos acadêmicos (teses, dissertações e trabalhos de conclusão de curso: graduação e especialização).
% ---
-\section{Ficha catalográfica com código Cutter-Sanborn}
+\section{Consulte o manual da classe \textsf{abntex2}}
% ---
-A Tabela Cutter-Sanborn é uma codificação elaborada por Charles Ammi Cutter e, posteriormente, expandida por Kate F. Sanborn. Na Tabela Cutter-Sanborn, é possível consultar qual sequência numérica representa a sequência do sobrenome do autor.
-
-Em vários sites da internet\footnote{\url{https://www.tabelacutter.com/}}\footnote{\url{https://cuttersonline.com.br/registrador-gratuito}} há ferramentas online para obtenção do código. Se o nome do primeiro autor do trabalho for, digamos, Carlos Lisboa, a entrada da ferramenta online deverá ser: \textbf{Lisboa, Carlos}. Nenhuma outra informação é necessária para gerar o código que, no caso desse autor, é \textbf{769}. Considere apenas esses três números. Eventuais letras devem ser ignoradas. No arquivo \texttt{tex} principal do relatório, na linha que tem o comando \verb|\numerocutter| troque por
-\begin{verbatim}
-\numerocutter{769}
-\end{verbatim}
-Esse número aparecerá na ficha catalográfica gerada. Automaticamente será adicionado na frente do número, a letra \textbf{L} maiúscula, que é a primeira letra do sobrenome \textbf{Lisboa}. Será também adicionado, ao final do número, a letra \textbf{m} minúscula, correspondente à primeira letra do título do trabalho (o título desse relatório de exemplo é ``Modelo de trabalho acadêmico com UnB\TeX''). Se seu nome for, por exemplo, Carlos da Silva, utilize como entrada da ferramenta que gera o código: \textbf{Silva, Carlos da}.
+Consulte o manual da classe \textsf{abntex2} \cite{abntex2classe} para uma referência completa das macros e ambientes disponíveis.
-A ficha catalográfica é um elemento pré-textual obrigatório para todos os trabalhos acadêmicos (teses, dissertações e trabalhos de conclusão de curso: graduação e especialização). \ No newline at end of file
+Além disso, o manual possui informações adicionais sobre as normas ABNT observadas pelo \abnTeX\ e considerações sobre eventuais requisitos específicos não atendidos, como o caso da \citeonline[seção 5.2.2]{NBR14724:2011}, que especifica o espaçamento entre os capítulos e o início do texto, regra propositalmente não atendida pelo presente modelo. \ No newline at end of file
diff --git a/macros/latex/contrib/unbtex/unbtex-example/capitulo3.tex b/macros/latex/contrib/unbtex/unbtex-example/capitulo3.tex
index 8dd6184026..af5f00ba52 100644
--- a/macros/latex/contrib/unbtex/unbtex-example/capitulo3.tex
+++ b/macros/latex/contrib/unbtex/unbtex-example/capitulo3.tex
@@ -1,10 +1,93 @@
% ----------------------------------------------------------
-\chapter{Figuras e gráficos}
+\chapter{Tabelas e figuras}
% ----------------------------------------------------------
-\section{Introdução}
+% ---
+\section{Tabelas}
+% ---
-Sugiro que você guarde todas as figuras na pasta ``figuras'' para que seu projeto fique mais organizado. A \cref{fig:logolatex} mostra como é fácil inserir uma figura com legenda e referência à fonte.
+As \cref{tab:nivel,tab:fluxo,tab:ibge} são exemplos de tabelas construída em
+\LaTeX. Note que a \cref{tab:ibge} utiliza o padrão do \citeonline{ibge1993} para documentos técnicos e acadêmicos.
+
+\begin{table}[htb]
+\begin{center}%
+\small
+\caption[Níveis de investigação]{Níveis de investigação}
+\label{tab:nivel}
+{\renewcommand{\arraystretch}{1.3} % espaçamento entre as linhas da tabela
+\begin{tabular}{p{2.5cm}p{5.4cm}p{2.3cm}p{2.5cm}}
+ \rowcolor{verdeunb!10}\textbf{Nível de Investigação} & \textbf{Insumos} & \textbf{Sistemas de Investigação} & \textbf{Produtos} \\ \hline
+ Meta-nível & Filosofia da Ciência & Epistemologia & Paradigma \\ \hline
+ Nível do objeto & Paradigmas do metanível e evidências do nível inferior & Ciência & Teorias e modelos \\ \hline
+ Nível inferior & Modelos e métodos do nível do objeto e problemas do nível inferior & Prática & Solução de problemas \\
+\end{tabular}}
+\fonte{\citeonline{van86}}
+\end{center}%
+\end{table}
+
+\begin{table}[htb]
+\small
+\begin{center}%
+\caption{Componentes curriculares do segundo nível}
+\label{tab:fluxo}
+{\renewcommand{\arraystretch}{1.2} % espaçamento entre as linhas da tabela
+\begin{tabular}{|m{1.6cm}|m{4.3cm}|C{.7cm}|C{.7cm}|C{.7cm}|C{.75cm}|C{.7cm}|m{2.1cm}|}
+\hline%
+\multicolumn{8}{|l|}{\textbf{2º Nível}} \\\hline%
+\multirow{2}{*}{Código} &
+\multirow{2}{*}{Componente curricular} &
+\multicolumn{5}{c|}{Quantidade de horas} &
+\multirow{2}{*}{Pré-requisito} \\
+\cline{3-7} & & Teo. & Pr. & Ext. & EaD & Tot. & \\\hline\hline%
+MAT0026 & Cálculo 2 & 60 & 30 & 0 & 0 & 90 & MAT0025 \\\hline%
+IFD0171 & Física 1 & 60 & 0 & 0 & 0 & 60 & \\\hline%
+IFD0173 & Física 1 Experimental & 0 & 30 & 0 & 0 & 30 & \\\hline%
+EST0023 & Probabilidade e Estatística & 30 & 30 & 0 & 0 & 60 & MAT0025 \\\hline%
+ENM0190 & Desenho Mecânico para Engenharia & 30 & 30 & 0 & 0 & 60 & \\\hline%
+CIC0090 & Estruturas de Dados & 30 & 30 & 0 & 0 & 60 & CIC0004 \\\hline%
+\multicolumn{6}{|l|}{Componentes optativos ou eletivos} & 60 & \multicolumn{1}{r}{} \\\cline{1-7}%
+\multicolumn{6}{|l|}{Total de horas do 2º Nível} & 420 & \multicolumn{1}{r}{} \\\cline{1-7}%
+\end{tabular}}
+\end{center}%
+\end{table}
+
+\begin{table}[htb]
+\IBGEtab{%
+ \caption{Um Exemplo de tabela alinhada que pode ser longa ou curta, conforme padrão IBGE}%
+ \label{tab:ibge}
+}{%
+ \begin{tabular}{ccc}
+ \toprule
+ \textbf{Nome} & \textbf{Nascimento} & \textbf{Documento} \\ \midrule \midrule
+ Maria da Silva & 11/11/1111 & 111.111.111-11 \\ \midrule
+ João Souza & 11/11/2111 & 211.111.111-11 \\ \midrule
+ Laura Vicuña & 05/04/1891 & 3111.111.111-11 \\ \bottomrule
+\end{tabular}%
+}{%
+ \fonte{Produzido pelos autores.}%
+ \nota{Esta é uma nota, que diz que os dados são baseados na regressão linear.}%
+ \nota[Anotações]{Uma anotação adicional, que pode ser seguida de várias outras.}%
+}
+\end{table}
+
+Para tabelas que ocupam mais de uma página, é possível utilizar o pacote \textsf{longtable}. Para alterar a cor de linhas e de células de tabelas, o pacote \textsf{colortbl} pode ser utilizado. Também há pacotes que rotacionam tabelas, para que fiquem em uma página em formato paisagem. Faça as tabelas usando como base qualquer um dos exemplos aqui apresentados ou outros que considerar mais adequados e que podem ser facilmente encontrados na internet.
+
+% ---
+\section{Figuras}
+% ---
+
+Se a figura que for incluída se tratar de um diagrama, um gráfico ou uma ilustração que você mesmo produza, priorize o uso de imagens vetoriais no formato \texttt{pdf}. Com isso, o tamanho do arquivo final do trabalho será menor, e as imagens terão uma apresentação melhor, principalmente quando impressas, uma vez que imagens vetoriais são perfeitamente escaláveis para qualquer dimensão. A \cref{fig:grafico} foi inserida no texto utilizando-se um arquivo no formato \texttt{pdf}.
+
+\begin{figure}[htb]
+ \centering
+ \caption{Resposta em frequência de malha aberta}
+ \label{fig:grafico}
+ \includegraphics[scale=1]{bodediagram.pdf}
+\end{figure}
+
+Para manter a coerência no uso de software livre (já que você está usando \LaTeX\ e \abnTeX), teste a ferramenta \textsf{InkScape} (\url{http://inkscape.org/}). Ela é uma excelente opção de código-livre para produzir ilustrações vetoriais, similar ao CorelDraw ou ao Adobe Illustrator.
+
+De todo modo, caso não seja possível utilizar arquivos de imagens como \texttt{pdf}, utilize qualquer outro formato, como \texttt{jpeg}, \texttt{gif}, \texttt{bmp}, etc. Nesse caso, você pode tentar aprimorar as imagens incorporadas com o software livre \textsf{Gimp} (\url{http://www.gimp.org/}). Ele é uma alternativa livre ao Adobe Photoshop. A \cref{fig:logolatex} mostra como é fácil inserir uma figura com legenda e referência à fonte utilizando um arquivo no formato \texttt{png}.
\begin{figure}[htb]
\begin{center}
@@ -15,77 +98,91 @@ Sugiro que você guarde todas as figuras na pasta ``figuras'' para que seu proje
\end{center}
\end{figure}
-Além de figuras, é possível inserir caixas de texto de diversos tipos, como exercícios, exemplos, etc, como o \cref{exc:in} e o \cref{exp:ae}.
-
-\section{Exercício}
-
-\begin{exercise}\label{exc:in}
- Explique como Isaac Newton usaria cada um dos pacotes seguintes, se vivesse no tempo presente:
- \begin{enumerate}[label=(\alph*)]
- \item Metapost
- \item TikZ
- \item PGFPlots
- \item PSTricks
- \end{enumerate}
-\end{exercise}
-
-\section{Exemplo}
-
-\begin{example}\label{exp:ae}
- Einstein usaria um editor WYSIWYG ou \LaTeX? \\
- Einstein era físico. Portanto, usando o teorema LaTeX-WYSIWYG, concluímos que ele usaria \LaTeX.
-\end{example}
-
-\section{Algoritmo}
-
-O \cref{alg:NNMPC} é um pseudo-código para obtenção de um controlador preditivo baseado em modelo e em redes neurais.
-
-\begin{algorithm}[htb]
-%\linespread{1.0}\selectfont % espaçamento entre as linhas do algoritmo
-\caption{Pseudocódigo de MPC baseado em redes neurais para consenso}
-\label{alg:NNMPC}
-\begin{algorithmic}[1] %\opção para numerar as linhas [1]
-%\Procedure{Roy}{$a,b$} \Comment{This is a test}
- \State Inicialização do sistema em $x(0), \theta(0)$
- \State $J = V(e(0),\theta(0))$
- \State $K^{ab}_0 = 0$ $\forall (a,b)$
- \State $dataset \gets [K_0,J]$
- \For{$k = 1:k_{max}$} \Comment{Laço de simulação}
- \State $(W,Y) \gets train(dataset)$
- \State $\tilde{J} = Y\sigma(Wz)$ $\forall K^{ab}_k\pm \delta_K$
- \State $K_k^{\ast} = arg \min_{K_k}(\tilde{J})$
- \State $u(k) = \left( L(\theta(k)) \otimes K_k^{\ast} \right) x(k)$
- \State $\hat{x}(k) = x(k)$; $\hat{\theta}(k) = \theta(k)$
- \For{$t = k+1:k+h+1$} \Comment{Laço de predição}
- \State $\hat{\theta}(t) = randMarkov(\hat{\theta}(t-1),\Pi)$
- \State $p = \hat{\theta}(t)$
- \State $\hat{u}(t) = \left( L(p) \otimes K_k^{\ast} \right) \hat{x}(t)$
- \State $\hat{x}(t+1) = F_{p}(\hat{x}(t))$
- \State $x_0(t) = mean(\hat{x}(t))$
- \State $\hat{e}(t) = F_{p}(\hat{x}(t)) - \boldsymbol{1_N} f_{p0}(x(t)) $
- \State $\hat{V}_{t} = \hat{e}^T(t)P_{p}\hat{e}(t)$
- \EndFor
- \State $\hat{J} = \sum_{t = k+1}^{k+h+1} \hat{V}_{t}$
- \State $dataset \gets [K^{\ast}_k,\hat{J}]$
- \State $x(k+1) = F_{p}(x(k))$
- \EndFor
-%\EndProcedure
-\end{algorithmic}
-\end{algorithm}
-
-\section{Programa}
-
-O \cref{cod:exemplo} é um exemplo de programa. Para mais exemplos, confira o \cref{apd:cdg}.
-
-\begin{lstlisting}[caption={Exemplo de programa},label={cod:exemplo}]
-/**
-* MSO: ativa o servo cujo eixo eh descrito
-* por drive_axis; informacoes de controle
-* sao gravadas em MSO_1
-*/
- MSO(drive_axis,MSO_1);
-/* Atribui o valor 0.0 ao primeiro elemento do array speed */
- speed[0] := 0.0;
-/* Atribui 1 para dataInitialized */
- dataInitialized := 1;
-\end{lstlisting} \ No newline at end of file
+Note que de acordo com as normas da ABNT, numeração e título das figuras e tabelas devem aparecer na parte superior. Na parte inferior deve ser informada a fonte.
+
+Outros exemplos de inserção de figuras no texto podem ser encontrados nos \cref{anx:fig,anx:logo}.
+
+% ---
+\subsection{Figuras em \emph{minipages}}
+% ---
+
+\emph{Minipages} são usadas para inserir textos ou outros elementos em quadros com tamanhos e posições controladas. Veja os exemplos das \cref{fig:minipage_circuito,fig:minipage_grafico}.
+
+\begin{figure}[htb]
+ \label{fig:teste}
+ \centering
+ \begin{minipage}[t]{0.46\textwidth}
+ \centering
+ \caption{Imagem da minipage}
+ \label{fig:minipage_circuito}
+ \includegraphics[scale=1]{circuito.pdf}
+ \end{minipage}
+ \hfill
+ \begin{minipage}[t]{0.52\textwidth}
+ \centering
+ \caption{Gráfico da minipage}
+ \label{fig:minipage_grafico}
+ \includegraphics[scale=1.2]{diodocurva.pdf}
+ \end{minipage}
+\end{figure}
+
+\subsection{Subfiguras}
+
+O pacote \textsf{subfig} foi utilizado para inserir as \cref{fig:subfigura_circuito,fig:subfigura_grafico}. Subfiguras também podem ser inseridas no texto com o pacote \textsf{subcaption}.
+
+% utiliza o pacote subfig
+\begin{figure}[htb]
+ \centering
+ \caption{Figura com subfiguras}
+ \label{fig:subfiguras}
+ \subfloat[Primeira subfigura]{\label{fig:subfigura_circuito} \centering
+ \includegraphics[scale=1]{circuito.pdf}}
+ \subfloat[Segunda subfigura]{\label{fig:subfigura_grafico} \hspace{0.4em}
+ \centering \includegraphics[scale=1.2]{diodocurva.pdf}}
+\end{figure}
+
+% utiliza o pacote subcaption
+%\begin{figure}[htb]
+% \centering
+% \caption{Figura com subfiguras}
+% \label{fig:subfiguras}
+% \begin{subfigure}[t]{0.47\textwidth}
+% \caption{Primeira subfigura}
+% \label{fig:subfigura_circuito}
+% \includegraphics[scale=1]{circuito.pdf}
+% \end{subfigure}%
+% \hfill
+% \begin{subfigure}[t]{0.52\textwidth}
+% \caption{Segunda subfigura}
+% \label{fig:subfigura_grafico}
+% \includegraphics[scale=1.2]{diodocurva.pdf}
+% \end{subfigure}
+%\end{figure}
+
+% ---
+\subsection{Obtenção de figuras com texto e equações que usam as mesmas fontes do documento}
+% ---
+
+Caso queira utilizar a mesma fonte do texto para escrever dentro de figuras, como é o caso da \cref{fig:psfrag1} (arquivo \texttt{blockdiagram.pdf}), produza uma figura como a da \cref{fig:psfrag2} e a salve no formato \texttt{eps} (arquivo \texttt{blockdiagram.eps}). Softwares como InkScape, CorelDraw ou Adobe Ilustrator podem ser utilizados para este fim.
+
+\begin{figure}[htb]
+ \centering
+ \caption{Uso do pacote \textsf{psfrag}}
+ \subfloat[Arquivo \texttt{blockdiagram.pdf}]{\label{fig:psfrag1} \centering
+ \includegraphics[scale=1]{blockdiagram.pdf}} \\
+ \subfloat[Arquivo \texttt{blockdiagram.eps}]{\label{fig:psfrag2}
+ \centering \includegraphics[scale=1]{blockdiagramfrag.eps}}
+ \label{fig:psgrag}
+\end{figure}
+
+Crie no Overleaf um projeto nomeado \texttt{blockdiagram} e que tenha, dentro de um arquivo nomeado \texttt{blockdiagram.tex}, o conteúdo mostrado no \cref{cod:tex}.
+
+\lstinputlisting[numbers=none,float,caption={\texttt{blockdiagram.tex}},label={cod:tex}]{unbtex-example/codigos/blockdiagram.tex}
+
+No menu do Overleaf, defina \texttt{LaTeX} como compilador e o arquivo \texttt{blockdiagram.tex} como principal. Coloque dentro do projeto o arquivo \texttt{blockdiagram.eps} e compile o projeto. A saída gerada corresponde à \cref{fig:psfrag1} e deverá ser salva como \texttt{blockdiagram.pdf}. Este arquivo poderá ser carregado no projeto do texto do trabalho (TCC, dissertação ou tese) que você estiver escrevendo com o UnB\TeX\ (que usa o \texttt{pdfLaTeX} como compilador).
+
+Note no \cref{cod:tex} que o pacote \textsf{psfrag} substitui, por meio do comando
+\begin{verbatim}
+\psfrag{r}[c][c]{\footnotesize $R(s)$}
+\end{verbatim}
+o ``\texttt{r}'' da figura \texttt{eps} por ``\verb|$R(s)$|'', produzindo ``$R(s)$'' na figura \texttt{pdf}. O pacote \textsf{psfrag} funciona apenas com o compilador \texttt{LaTeX}, o que torna a criação de um novo projeto no Overleaf uma boa solução. Este projeto poderá ser aproveitado para gerar outras figuras do seu trabalho. \ No newline at end of file
diff --git a/macros/latex/contrib/unbtex/unbtex-example/capitulo4.tex b/macros/latex/contrib/unbtex/unbtex-example/capitulo4.tex
index ee18e6f531..d7e54d1611 100644
--- a/macros/latex/contrib/unbtex/unbtex-example/capitulo4.tex
+++ b/macros/latex/contrib/unbtex/unbtex-example/capitulo4.tex
@@ -31,5 +31,74 @@ O WYSIWYG (ou ``What You See Is What You Get - O que você vê é o formato fina
\end{corollary}
\begin{proof}
- Físicos gostam de equações bonitas. Editores What-You-See-Is-What-You-Get não são apropriados para fazer equações bonitas.\footnote{É certo que há editores WYSIWYG baseados em \LaTeX, mas eles não nos dão o mesmo nível de controle.} Logo, se algum físico preferisse usar um editor WYSIWYG no lugar de \LaTeX, não seria muito inteligente. Como todo físico é inteligente, o teorema está demonstrado \textit{ad absurdum}.
-\end{proof} \ No newline at end of file
+ Físicos gostam de equações bonitas. Editores What-You-See-Is-What-You-Get não são apropriados para fazer equações bonitas\footnote{É certo que há editores WYSIWYG baseados em \LaTeX, mas eles não nos dão o mesmo nível de controle.}. Logo, se algum físico preferisse usar um editor WYSIWYG no lugar de \LaTeX, não seria muito inteligente. Como todo físico é inteligente, o teorema está demonstrado \textit{ad absurdum}.
+\end{proof}
+
+\begin{exercise}\label{exc:in}
+ Explique como Isaac Newton usaria cada um dos pacotes seguintes, se vivesse no tempo presente:
+ \begin{enumerate}[label=(\alph*)]
+ \item Metapost
+ \item TikZ
+ \item PGFPlots
+ \item PSTricks
+ \end{enumerate}
+\end{exercise}
+
+\begin{example}\label{exp:ae}
+ Einstein usaria um editor WYSIWYG ou \LaTeX? \\
+ Einstein era físico. Portanto, usando o teorema LaTeX-WYSIWYG, concluímos que ele usaria \LaTeX.
+\end{example}
+
+\section{Algoritmo}
+
+O \cref{alg:NNMPC} é um pseudo-código para obtenção de um controlador preditivo baseado em modelo e em redes neurais.
+
+\begin{algorithm}[htb]
+%\linespread{1.0}\selectfont % espaçamento entre as linhas do algoritmo
+\caption{Pseudocódigo de MPC baseado em redes neurais para consenso}
+\label{alg:NNMPC}
+\begin{algorithmic}[1] %\opção para numerar as linhas [1]
+%\Procedure{Roy}{$a,b$} \Comment{This is a test}
+ \State Inicialização do sistema em $x(0), \theta(0)$
+ \State $J = V(e(0),\theta(0))$
+ \State $K^{ab}_0 = 0$ $\forall (a,b)$
+ \State $dataset \gets [K_0,J]$
+ \For{$k = 1:k_{max}$} \Comment{Laço de simulação}
+ \State $(W,Y) \gets train(dataset)$
+ \State $\tilde{J} = Y\sigma(Wz)$ $\forall K^{ab}_k\pm \delta_K$
+ \State $K_k^{\ast} = arg \min_{K_k}(\tilde{J})$
+ \State $u(k) = \left( L(\theta(k)) \otimes K_k^{\ast} \right) x(k)$
+ \State $\hat{x}(k) = x(k)$; $\hat{\theta}(k) = \theta(k)$
+ \For{$t = k+1:k+h+1$} \Comment{Laço de predição}
+ \State $\hat{\theta}(t) = randMarkov(\hat{\theta}(t-1),\Pi)$
+ \State $p = \hat{\theta}(t)$
+ \State $\hat{u}(t) = \left( L(p) \otimes K_k^{\ast} \right) \hat{x}(t)$
+ \State $\hat{x}(t+1) = F_{p}(\hat{x}(t))$
+ \State $x_0(t) = mean(\hat{x}(t))$
+ \State $\hat{e}(t) = F_{p}(\hat{x}(t)) - \boldsymbol{1_N} f_{p0}(x(t)) $
+ \State $\hat{V}_{t} = \hat{e}^T(t)P_{p}\hat{e}(t)$
+ \EndFor
+ \State $\hat{J} = \sum_{t = k+1}^{k+h+1} \hat{V}_{t}$
+ \State $dataset \gets [K^{\ast}_k,\hat{J}]$
+ \State $x(k+1) = F_{p}(x(k))$
+ \EndFor
+%\EndProcedure
+\end{algorithmic}
+\end{algorithm}
+
+\section{Programa}
+
+O \cref{cod:exemplo} é um exemplo de programa. Para mais exemplos, confira o \cref{apd:cdg}.
+
+\begin{lstlisting}[caption={Exemplo de programa},label={cod:exemplo}]
+/**
+* MSO: ativa o servo cujo eixo eh descrito
+* por drive_axis; informacoes de controle
+* sao gravadas em MSO_1
+*/
+ MSO(drive_axis,MSO_1);
+/* Atribui o valor 0.0 ao primeiro elemento do array speed */
+ speed[0] := 0.0;
+/* Atribui 1 para dataInitialized */
+ dataInitialized := 1;
+\end{lstlisting} \ No newline at end of file
diff --git a/macros/latex/contrib/unbtex/unbtex-example/references.bib b/macros/latex/contrib/unbtex/unbtex-example/references.bib
deleted file mode 100644
index e002ec4ac3..0000000000
--- a/macros/latex/contrib/unbtex/unbtex-example/references.bib
+++ /dev/null
@@ -1,189 +0,0 @@
-%%%
-%%% Arquivo obtido de Castro (2019)
-%%%
-
-@misc{wikimedia-latex,
- author = {{Wikimedia Commons}},
- title = {File: {\normalfont LaTeX logo.svg}},
- year = {2008},
- note = {Upload de EmilJ. Dispon\'ivel em: \url{https://upload.wikimedia.org/wikipedia/commons/9/92/LaTeX_logo.svg} -- acesso em 24 jan. 2019.}
-}
-
-@misc{Castro2019,
- author = {Leonardo Luiz e Castro},
- title = {Modelo de livro para Editora UnB},
- howpublished = {\url{https://www.overleaf.com/latex/templates/modelo-de-livro-para-editora-unb/trznrgjcsyfg}},
- month = {1},
- year = {2019},
- note = {Dispon\'ivel como template no Overleaf}
-}
-
-% Exemplo tirado de https://en.wikibooks.org/wiki/LaTeX/Bibliography_Management#BibTeX abaixo:
-
-@article{greenwade93,
- author = "George D. Greenwade",
- title = "The {C}omprehensive {T}ex {A}rchive {N}etwork ({CTAN})",
- year = "1993",
- journal = "TUGBoat",
- volume = "14",
- number = "3",
- pages = "342--351"
-}
-
-% Outros exemplos, tirados de https://verbosus.com/bibtex-style-examples.html abaixo:
-
-@article{article,
- author = {Peter Adams},
- title = {The title of the work},
- journal = {The name of the journal},
- year = 1993,
- number = 2,
- pages = {201-213},
- month = 7,
- note = {An optional note},
- volume = 4
-}
-
-@book{book,
- author = {Peter Babington},
- title = {The title of the work},
- publisher = {The name of the publisher},
- year = 1993,
- volume = 4,
- series = 10,
- address = {The address},
- edition = 3,
- month = 7,
- note = {An optional note},
- isbn = {3257227892}
-}
-
-@booklet{booklet,
- title = {The title of the work},
- author = {Peter Caxton},
- howpublished = {How it was published},
- address = {The address of the publisher},
- month = 7,
- year = 1993,
- note = {An optional note}
-}
-
-@conference{conference,
- author = {Peter Draper},
- title = {The title of the work},
- booktitle = {The title of the book},
- year = 1993,
- editor = {The editor},
- volume = 4,
- series = 5,
- pages = 213,
- address = {The address of the publisher},
- month = 7,
- organization = {The organization},
- publisher = {The publisher},
- note = {An optional note}
-}
-
-@inbook{inbook,
- author = {Peter Eston},
- title = {The title of the work},
- chapter = 8,
- pages = {201-213},
- publisher = {The name of the publisher},
- year = 1993,
- volume = 4,
- series = 5,
- address = {The address of the publisher},
- edition = 3,
- month = 7,
- note = {An optional note}
-}
-
-@incollection{incollection,
- author = {Peter Farindon},
- title = {The title of the work},
- booktitle = {The title of the book},
- publisher = {The name of the publisher},
- year = 1993,
- editor = {The editor},
- volume = 4,
- series = 5,
- chapter = 8,
- pages = {201-213},
- address = {The address of the publisher},
- edition = 3,
- month = 7,
- note = {An optional note}
-}
-
-@manual{manual,
- title = {The title of the work},
- author = {Peter Gainsford},
- organization = {The organization},
- address = {The address of the publisher},
- edition = 3,
- month = 7,
- year = 1993,
- note = {An optional note}
-}
-
-@mastersthesis{mastersthesis,
- author = {Peter Harwood},
- title = {The title of the work},
- school = {The school of the thesis},
- year = 1993,
- address = {The address of the publisher},
- month = 7,
- note = {An optional note}
-}
-
-@misc{misc,
- author = {Peter Isley},
- title = {The title of the work},
- howpublished = {How it was published},
- month = 7,
- year = 1993,
- note = {An optional note}
-}
-
-@phdthesis{phdthesis,
- author = {Peter Joslin},
- title = {The title of the work},
- school = {The school of the thesis},
- year = 1993,
- address = {The address of the publisher},
- month = 7,
- note = {An optional note}
-}
-
-@proceedings{proceedings,
- title = {The title of the work},
- year = 1993,
- editor = {Peter Kidwelly},
- volume = 4,
- series = 5,
- address = {The address of the publisher},
- month = 7,
- organization = {The organization},
- publisher = {The name of the publisher},
- note = {An optional note}
-}
-
-@techreport{techreport,
- author = {Peter Lambert},
- title = {The title of the work},
- institution = {The institution that published},
- year = 1993,
- number = 2,
- address = {The address of the publisher},
- month = 7,
- note = {An optional note}
-}
-
-@unpublished{unpublished,
- author = {Peter Marcheford},
- title = {The title of the work},
- note = {An optional note},
- month = 7,
- year = 1993
-} \ No newline at end of file
diff --git a/macros/latex/contrib/unbtex/unbtex-example/referencias.bib b/macros/latex/contrib/unbtex/unbtex-example/referencias.bib
index 2cac676cb4..6539a93470 100644
--- a/macros/latex/contrib/unbtex/unbtex-example/referencias.bib
+++ b/macros/latex/contrib/unbtex/unbtex-example/referencias.bib
@@ -1,5 +1,4 @@
%%
-%% Arquivo utilizado no projeto abnTeX
%% Utilize comandos específicos para acentuar palavras em arquivos *.bib
%%
@@ -369,4 +368,186 @@
Date-Modified = {2012-04-23 11:34:16 +0000},
Publisher = {Perigee Books},
Title = {Art as Experience},
- Year = {1980}} \ No newline at end of file
+ Year = {1980}}
+
+@misc{wikimedia-latex,
+ author = {{Wikimedia Commons}},
+ title = {File: {\normalfont LaTeX logo.svg}},
+ year = {2008},
+ note = {Upload de EmilJ. Dispon\'ivel em: \url{https://upload.wikimedia.org/wikipedia/commons/9/92/LaTeX_logo.svg} -- acesso em 24 jan. 2019.}
+}
+
+@misc{Castro2019,
+ author = {Leonardo Luiz e Castro},
+ title = {Modelo de livro para Editora UnB},
+ howpublished = {\url{https://www.overleaf.com/latex/templates/modelo-de-livro-para-editora-unb/trznrgjcsyfg}},
+ month = {1},
+ year = {2019},
+ note = {Dispon\'ivel como template no Overleaf}
+}
+
+@article{greenwade93,
+ author = "George D. Greenwade",
+ title = "The {C}omprehensive {T}ex {A}rchive {N}etwork ({CTAN})",
+ year = "1993",
+ journal = "TUGBoat",
+ volume = "14",
+ number = "3",
+ pages = "342--351"
+}
+
+@article{article,
+ author = {Peter Adams},
+ title = {The title of the work},
+ journal = {The name of the journal},
+ year = 1993,
+ number = 2,
+ pages = {201-213},
+ month = 7,
+ note = {An optional note},
+ volume = 4
+}
+
+@book{book,
+ author = {Peter Babington},
+ title = {The title of the work},
+ publisher = {The name of the publisher},
+ year = 1993,
+ volume = 4,
+ series = 10,
+ address = {The address},
+ edition = 3,
+ month = 7,
+ note = {An optional note},
+ isbn = {3257227892}
+}
+
+@booklet{booklet,
+ title = {The title of the work},
+ author = {Peter Caxton},
+ howpublished = {How it was published},
+ address = {The address of the publisher},
+ month = 7,
+ year = 1993,
+ note = {An optional note}
+}
+
+@conference{conference,
+ author = {Peter Draper},
+ title = {The title of the work},
+ booktitle = {The title of the book},
+ year = 1993,
+ editor = {The editor},
+ volume = 4,
+ series = 5,
+ pages = 213,
+ address = {The address of the publisher},
+ month = 7,
+ organization = {The organization},
+ publisher = {The publisher},
+ note = {An optional note}
+}
+
+@inbook{inbook,
+ author = {Peter Eston},
+ title = {The title of the work},
+ chapter = 8,
+ pages = {201-213},
+ publisher = {The name of the publisher},
+ year = 1993,
+ volume = 4,
+ series = 5,
+ address = {The address of the publisher},
+ edition = 3,
+ month = 7,
+ note = {An optional note}
+}
+
+@incollection{incollection,
+ author = {Peter Farindon},
+ title = {The title of the work},
+ booktitle = {The title of the book},
+ publisher = {The name of the publisher},
+ year = 1993,
+ editor = {The editor},
+ volume = 4,
+ series = 5,
+ chapter = 8,
+ pages = {201-213},
+ address = {The address of the publisher},
+ edition = 3,
+ month = 7,
+ note = {An optional note}
+}
+
+@manual{manual,
+ title = {The title of the work},
+ author = {Peter Gainsford},
+ organization = {The organization},
+ address = {The address of the publisher},
+ edition = 3,
+ month = 7,
+ year = 1993,
+ note = {An optional note}
+}
+
+@mastersthesis{mastersthesis,
+ author = {Peter Harwood},
+ title = {The title of the work},
+ school = {The school of the thesis},
+ year = 1993,
+ address = {The address of the publisher},
+ month = 7,
+ note = {An optional note}
+}
+
+@misc{misc,
+ author = {Peter Isley},
+ title = {The title of the work},
+ howpublished = {How it was published},
+ month = 7,
+ year = 1993,
+ note = {An optional note}
+}
+
+@phdthesis{phdthesis,
+ author = {Peter Joslin},
+ title = {The title of the work},
+ school = {The school of the thesis},
+ year = 1993,
+ address = {The address of the publisher},
+ month = 7,
+ note = {An optional note}
+}
+
+@proceedings{proceedings,
+ title = {The title of the work},
+ year = 1993,
+ editor = {Peter Kidwelly},
+ volume = 4,
+ series = 5,
+ address = {The address of the publisher},
+ month = 7,
+ organization = {The organization},
+ publisher = {The name of the publisher},
+ note = {An optional note}
+}
+
+@techreport{techreport,
+ author = {Peter Lambert},
+ title = {The title of the work},
+ institution = {The institution that published},
+ year = 1993,
+ number = 2,
+ address = {The address of the publisher},
+ month = 7,
+ note = {An optional note}
+}
+
+@unpublished{unpublished,
+ author = {Peter Marcheford},
+ title = {The title of the work},
+ note = {An optional note},
+ month = 7,
+ year = 1993
+} \ No newline at end of file
diff --git a/macros/latex/contrib/unbtex/unbtex.cls b/macros/latex/contrib/unbtex/unbtex.cls
index 7c88458859..aec90b8169 100644
--- a/macros/latex/contrib/unbtex/unbtex.cls
+++ b/macros/latex/contrib/unbtex/unbtex.cls
@@ -1,7 +1,7 @@
%%
%% UnBTeX: A class for bachelor, master, and doctoral thesis at the
%% University of Brasilia (UnB), Brazil
-%% Version 1.4.1 2023/11/27
+%% Version 1.4.2 2023/12/15
%% Copyright (C) 2021-2023 by Henrique C. Ferreira <hcferreira@unb.br>
%%
%% This class file may be distributed and/or modified under the conditions
@@ -22,7 +22,7 @@
%%
\NeedsTeXFormat{LaTeX2e}
-\ProvidesClass{unbtex}[2023/11/27 v1.4.1 Modelo da Universidade de Brasília baseado em abnTeX2]
+\ProvidesClass{unbtex}[2023/12/15 v1.4.2 Modelo da Universidade de Brasília baseado em abnTeX2]
% ---
% Repassa todos os parâmetros a classe abntex2,
@@ -40,15 +40,6 @@
% ------------------------------------------------------------------------
% ---
-% Pacotes básicos
-% ---
-\RequirePackage{graphicx} % Inclusão de gráficos
-%\RequirePackage[skip=8pt]{subcaption} % Permite fazer subfiguras
-\RequirePackage[captionskip=8pt]{subfig} % Permite fazer subfiguras
-\RequirePackage{multirow} % Para combinar linhas nas tabelas
-% ---
-
-% ---
% Pacotes matemáticos
% ---
\RequirePackage{amsmath}
@@ -67,12 +58,21 @@
\RequirePackage[stickstoo,vvarbb]{newtxmath}
\RequirePackage[scaled=0.88]{helvet} % Fonte sans serif
\RequirePackage[scaled=1.03]{inconsolata} % Fonte monoespaçada
+% ---
+
+% ---
+% Pacotes para figuras
+% ---
+\RequirePackage{graphicx} % Inclusão de figuras
+%\RequirePackage[skip=8pt]{subcaption} % Permite fazer subfiguras
+\RequirePackage[captionskip=8pt]{subfig} % Permite fazer subfiguras
+% ---
% ---
% Cores verde e azul UnB
% http://www.marca.unb.br/arquivosdigitais/files/guia_pratico/guia_pratico.pdf
% ---
-\RequirePackage[dvipsnames,table]{xcolor} % Para cores da UnB
+\RequirePackage[dvipsnames]{xcolor} % Para cores da UnB
\definecolor{verdeunb}{cmyk}{1,0,1,0.2}
\definecolor{azulunb}{cmyk}{1,0.65,0,0.35}
@@ -80,9 +80,21 @@
\renewcommand{\tocheadstart}{}
\renewcommand{\ABNTEXchapterfont}{\bfseries\color{verdeunb}\sffamily}
\renewcommand{\ABNTEXsubsectionfont}{}
+% ---
+
+% ---
+% Configurações para tabelas
+% ---
+\RequirePackage{multirow} % Para combinar linhas nas tabelas
+\RequirePackage{colortbl} % Permite alterar cores de linhas e células das tabelas
+\arrayrulecolor{verdeunb} % Define a cor das linhas das tabelas
+\setlength\arrayrulewidth{0.6pt} % Define a espessura das linhas das tabelas
-% Cores das linhas de todas as tabelas:
-\arrayrulecolor{verdeunb}
+% Alinhamento em colunas com especificação de largura
+\newcolumntype{L}[1]{>{\raggedright\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
+\newcolumntype{C}[1]{>{\centering\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
+\newcolumntype{R}[1]{>{\raggedleft\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
+% ---
% ---
% ---
@@ -101,7 +113,7 @@
% Ajusta espaço entre texto e figuras/tabelas
\setlength{\textfloatsep}{18.0pt plus 2.0pt minus 2.0pt} % espaçamento entre texto e floats no topo/base da página
\setlength{\floatsep}{12.0pt plus 2.0pt minus 2.0pt} % espaçamento entre floats
-\setlength{\intextsep}{16pt plus 2pt minus 2pt} % espaçamento entre texto e floats no meio da página
+\setlength{\intextsep}{14pt plus 2pt minus 2pt} % espaçamento entre texto e floats no meio da página
% Ajusta espaçamento nos ambientes itemize, enumerate, description e alineas
\setlist[itemize]{topsep=0pt,itemsep=0pt,leftmargin=\parindent}
@@ -118,7 +130,7 @@
%\setlength{\normalrulethickness}{0pt} % retira a linha do cabeçalho
% Modifica o tamanho da fonte e espaçamento entre linhas no ambiente verbatim
-\usepackage{fvextra}
+\RequirePackage{fvextra}
\renewenvironment{verbatim}{%
\VerbatimEnvironment
\begin{Verbatim}[fontsize=\small,baselinestretch=1.1]%
@@ -138,8 +150,11 @@
}{%
\end{SingleSpace}%
\endlist}%
+% ---
+% ---
% Personalização do Sumário
+% ---
\settocdepth{subsection}
\renewcommand{\cftchapterfont}{\normalsize\bfseries\sffamily}
\setlength{\cftbeforechapterskip}{8pt}
@@ -158,6 +173,27 @@
\renewcommand*{\cftappendixname}{#1 \space}
}
\renewcommand{\cftpartpagefont}{\normalsize\bfseries}
+
+% Anexos - comando
+\renewcommand{\anexos}{%
+ \cftinserthook{toc}{AAA}
+ \PRIVATEapendiceconfig{\Anexoname}{\Anexosname}
+ \appendix
+ \renewcommand\theHchapter{anexochapback.\arabic{chapter}}
+}
+
+% Anexos - ambiente
+\renewenvironment{anexosenv}{%
+ \cftinserthook{toc}{AAA}
+ \PRIVATEapendiceconfig{\Anexoname}{\Anexosname}
+ \crefalias{appendix}{annex}
+ \begin{appendix}
+ \renewcommand\theHchapter{anexochapback.\arabic{chapter}}
+}{
+ \end{appendix}
+ \setboolean{abntex@apendiceousecao}{false}
+ \bookmarksetup{startatroot}
+}
% ---
% ---
@@ -271,9 +307,15 @@
showstringspaces=false,%without this there will be a symbol in the places where there is a space
literate={á}{{\'a}}1 {ã}{{\~a}}1 {é}{{\'e}}1 {ç}{{\c{c}}}1 {â}{{\^a}}1 {õ}{{\~o}}1 {ú}{{\'u}}1 {ó}{{\'o}}1 {í}{{\'i}}1 {Í}{{\'I}}1
}
+% ---
+% ---
% Referências cruzadas automáticas, dependendo do tipo de referência (figuras, tabelas, equações, etc.)
+% ---
\RequirePackage[nameinlink,noabbrev,english,brazilian]{cleveref}
+\crefname{annex}{\anexoname}{\anexosname}
+\Crefname{annex}{\Anexoname}{\Anexosname}
+% ---
% ---
% Definição de ambientes definição, teorema, exemplo, demonstração, etc.
@@ -299,13 +341,13 @@
\theoremstyle{remark}
\let\proof\relax
\let\endproof\relax
-\newmdtheoremenv[linecolor=azulunb,linewidth=0.5mm,hidealllines=false]{remark}{\rmname}[chapter]
+\newmdtheoremenv[linecolor=azulunb,linewidth=1pt,hidealllines=false]{remark}{\rmname}[chapter]
\newtheoremstyle{myproof}{\topsep}{\topsep}{}{}{\bfseries}{}{ }{\thmname{#1} \thmnote{#3}}
\theoremstyle{myproof}
\let\proof\relax
\let\endproof\relax
-\newmdtheoremenv[linecolor=verdeunb,linewidth=0.5mm,hidealllines=false]{proof}{\proofname.}
+\newmdtheoremenv[linecolor=verdeunb,linewidth=1pt,hidealllines=false]{proof}{\proofname.}
\AtEndEnvironment{proof}{\hfill$\square$}
\newcommand{\thmnameen}{
@@ -321,9 +363,9 @@
\newcommand{\rmname}{Remark}
\renewcommand{\proofname}{Proof}
\renewcommand{\lstlistingname}{Code}
+\renewcommand{\ALG@name}{Algorithm}
\crefname{listing}{code}{codes}
\Crefname{listing}{Code}{Codes}
-\renewcommand{\ALG@name}{Algorithm}
}
\newcommand{\thmnamebr}{
@@ -339,9 +381,9 @@
\newcommand{\rmname}{Observação}
\renewcommand{\proofname}{Demonstração}
\renewcommand{\lstlistingname}{Código}
+\renewcommand{\ALG@name}{Algoritmo}
\crefname{listing}{código}{códigos}
\Crefname{listing}{Código}{Códigos}
-\renewcommand{\ALG@name}{Algoritmo}
}
% ---
@@ -391,7 +433,8 @@
\newcommand{\kwordiv}[1]{\def\kwordivnome{#1}}
% Código da ficha catalográfica
-\newcommand{\numerocutter}[1]{\def\imprimircutter{#1}}
+%\newcommand{\numerocutter}[1]{\def\imprimircutter{#1}}
+% ---
% ---
% Imprime capa
@@ -401,7 +444,7 @@
\center
\AddToShipoutPicture*{\BackgroundPic}
\vspace*{7.5cm}
- {\bfseries\sffamily\LARGE \instituicaoi \par \instituicaoii} \par
+ {\bfseries\sffamily\LARGE \instituicaoi \\[12pt] \instituicaoii} \\[12pt]
\abntex@ifnotempty{\instituicaoiii}{{\bfseries\sffamily\LARGE\instituicaoiii}}
\begin{center}
\vfill
@@ -409,11 +452,11 @@
\end{center}
\vfill
{\Large\autorinome\ \autorisobrenome
- \par
+ \\[12pt]
\abntex@ifnotempty{\autoriinome}{\autoriinome\ \autoriisobrenome}}
\vfill
\begin{center}
- \color{white}{\sffamily\Large\expandafter\MakeUppercase\expandafter \imprimirtipotrabalho \par \expandafter\MakeUppercase\expandafter\imprimircurso \\ \vspace{0.2cm} \imprimirlocal \par \imprimirano}
+ \color{white}{\sffamily\Large\expandafter\MakeUppercase\expandafter \imprimirtipotrabalho \\[4pt] \expandafter\MakeUppercase\expandafter\imprimircurso \\[6pt] \imprimirlocal \\[6pt] \imprimirano}
\end{center}
\end{capa}
}
@@ -440,7 +483,7 @@
\renewcommand{\folhaderostocontent}{
\begin{center}
- {\bfseries\sffamily\LARGE \instituicaoi \par \instituicaoii} \par
+ {\bfseries\sffamily\LARGE \instituicaoi \\[12pt] \instituicaoii} \\[12pt]
\abntex@ifnotempty{\instituicaoiii}{{\bfseries\sffamily\LARGE\instituicaoiii}}
\vfill\vfill\vfill
@@ -450,8 +493,8 @@
\vfill
-{\large\autorinome\ \autorisobrenome
- \par
+{\Large\autorinome\ \autorisobrenome
+ \\[12pt]
\abntex@ifnotempty{\autoriinome}{\autoriinome\ \autoriisobrenome}}
\vfill\vfill
@@ -470,7 +513,7 @@
\vfill
}%
-{\large \orientadorname: \orienttitulo\ \orientnome\ \orientsobrenome\par}
+{\large \orientadorname: \orienttitulo\ \orientnome\ \orientsobrenome\\[6pt]}
\abntex@ifnotempty{\coorientnome}{%
{\large\coorientadorname: \coorienttitulo\ \coorientnome\ \coorientsobrenome}%
@@ -478,7 +521,7 @@
\vfill\vfill
-{\sffamily\large\imprimirlocal \par\imprimirano}
+{\sffamily\large\imprimirlocal \\[6pt] \imprimirano}
\end{center}
}
@@ -488,26 +531,27 @@
% ---
% Imprime ficha catalográfica
% ---
-\RequirePackage{xstring}
-
+% https://bce.unb.br/servicos/elaboracao-de-fichas-catalograficas/
+% Para imprimir o código Cutter, remova os comentários
\renewcommand{\fichacatalografica}{
\thispagestyle{empty}{
-\setlength{\fboxsep}{10pt}
+\setlength{\fboxsep}{18pt}
\vspace*{\fill}
{\small
{\SingleSpacing
\begin{center}
+{\sffamily\large FICHA CATALOGRÁFICA} \\ \vspace{18pt}
\fbox{\begin{minipage}[t][7.5cm]{12.5cm}
-\begin{tabular}{p{1.25cm} p{10.25cm}}
-& \autorisobrenome, \autorinome. \\
-\StrChar{\autorisobrenome}{1}\imprimircutter\StrChar{\imprimirtitulo}{1}[\SUBtemp]\MakeLowercase{\SUBtemp}
-& \hspace{0.5cm} \StrDel{\imprimirtitulo}{\\} ~/ \autorinome\ \autorisobrenome; \ifthenelse{\equal{\autoriinome}{}}{}{\autoriinome\ \autoriisobrenome;} \MakeLowercase\orientadorname\ \orientnome\ \orientsobrenome \ifthenelse{\equal{\coorientnome}{}}{.}{;~\MakeLowercase\coorientadorname\ \coorientnome\ \coorientsobrenome.} \texttt{-{}-} \imprimirlocal, \imprimirano. \\
-& \hspace{0.5cm}\thelastpage~p. \\
-& \\
-& \hspace{0.5cm} \imprimirtipotrabalho\ (\imprimircurso)\ \texttt{-{}-} \instituicaoi, \imprimirano. \\
-& \\
-& \hspace{0.5cm} 1. \pchaveinome. 2. \pchaveiinome. 3. \pchaveiiinome. \ifthenelse{\equal{\pchaveivnome}{}}{}{4. \pchaveivnome.} \ifthenelse{\equal{\autoriinome}{}}{\ifthenelse{\equal{\coorientnome}{}}{I. \orientsobrenome, \orientnome, orient. II. Título}{I. \orientsobrenome, \orientnome, orient. II. \coorientsobrenome, \coorientnome, coorient. III. Título}}{\ifthenelse{\equal{\coorientnome}{}}{I. \autoriisobrenome, \autoriinome. II. \orientsobrenome, \orientnome, orient. III. Título}{I. \autoriisobrenome, \autoriinome. II. \orientsobrenome, \orientnome, orient. III. \coorientsobrenome, \coorientnome, coorient. IV. Título}}
-\end{tabular}
+%\begin{tabular}{p{1.25cm} p{10.25cm}} &
+\autorisobrenome, \autorinome. \\
+%\StrChar{\autorisobrenome}{1}\imprimircutter\StrChar{\imprimirtitulo}{1}[\SUBtemp]\MakeLowercase{\SUBtemp} &
+\hspace*{2em}\noindent \StrDel{\imprimirtitulo}{\\ } ~/ \autorinome\ \autorisobrenome; \ifthenelse{\equal{\autoriinome}{}}{}{\autoriinome\ \autoriisobrenome;} \MakeLowercase\orientadorname\ \orientnome\ \orientsobrenome \ifthenelse{\equal{\coorientnome}{}}{.}{;~\MakeLowercase\coorientadorname\ \coorientnome\ \coorientsobrenome.} \texttt{-{}-} \imprimirlocal, \imprimirano. \\ % &
+\hspace*{2em}\noindent \thelastpage~p. \\ % &
+\\ % &
+\hspace*{2em}\noindent \imprimirtipotrabalho\ (\imprimircurso)\ \texttt{-{}-} \instituicaoi, \imprimirano. \\ % &
+\\ % &
+\hspace*{2em}\noindent 1. \pchaveinome. 2. \pchaveiinome. 3. \pchaveiiinome. \ifthenelse{\equal{\pchaveivnome}{}}{}{4. \pchaveivnome.} \ifthenelse{\equal{\autoriinome}{}}{\ifthenelse{\equal{\coorientnome}{}}{I. \orientsobrenome, \orientnome, orient. II. Título}{I. \orientsobrenome, \orientnome, orient. II. \coorientsobrenome, \coorientnome, coorient. III. Título}}{\ifthenelse{\equal{\coorientnome}{}}{I. \autoriisobrenome, \autoriinome. II. \orientsobrenome, \orientnome, orient. III. Título}{I. \autoriisobrenome, \autoriinome. II. \orientsobrenome, \orientnome, orient. III. \coorientsobrenome, \coorientnome, coorient. IV. Título}}
+%\end{tabular}
\end{minipage}}
\end{center}
}}
@@ -523,17 +567,17 @@
\newcommand{\imprimirfolhadeaprovacao}{
\begin{folhadeaprovacao}
\begin{center}
- {\bfseries\sffamily\Large \instituicaoi \par\vspace{0.5mm} \instituicaoii} \par
+ {\bfseries\sffamily\Large \instituicaoi \\[7.5pt] \instituicaoii} \\[6pt]
\abntex@ifnotempty{\instituicaoiii}{{\bfseries\sffamily\Large\instituicaoiii}}
- \vfill\vfill
+ \vfill
\begin{center}
- \color{verdeunb}\bfseries\sffamily\LARGE\imprimirtitulo
+ \color{verdeunb}\bfseries\sffamily\LARGE\StrDel{\imprimirtitulo}{\\ }
\end{center}
\vfill
{\large\autorinome\ \autorisobrenome
- \par
+ \\[6pt]
\abntex@ifnotempty{\autoriinome}{\autoriinome\ \autoriisobrenome}}
\vfill
@@ -563,7 +607,7 @@
\vfill
\begin{center}
{\sffamily\large\imprimirlocal
- \par \imprimirano}
+ \\[6pt] \imprimirano}
\end{center}
\end{center}
\end{folhadeaprovacao}
@@ -572,7 +616,9 @@
\makeatother
% ---
+% ---
% Correção para o pacote microtype
+% ---
\makeatletter
\long\def\MT@prot@l#1{%
\MT@get@prot{#1}{left}%
@@ -580,8 +626,11 @@
#1}
\def\MT@prot@group#{\bgroup\afterassignment\MT@prot@get@firstchar\let\MT@temp= }
\makeatother
+% ---
+% ---
% Ajusta a indentação das listas de figuras e de tabelas
+% ---
\RequirePackage{tocbasic}
\DeclareTOCStyleEntry[
indent=0pt,
@@ -589,7 +638,6 @@
dynnumwidth,
%numsep=0em
]{tocline}{figure}
-%\newcommand\entrynumberwithprefix[2]{#1\enspace#2:\hfill}
\DeclareTOCStyleEntry[
indent=0pt,
@@ -597,4 +645,5 @@
dynnumwidth,
%numsep=0em
]{tocline}{table}
-\newcommand\entrynumberwithprefix[2]{#1~#2~\hfill} \ No newline at end of file
+\newcommand\entrynumberwithprefix[2]{#1~#2~\hfill}
+% --- \ No newline at end of file