summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-03-27 21:13:10 +0000
committerKarl Berry <karl@freefriends.org>2020-03-27 21:13:10 +0000
commitc85e812b46bdb585d381d44dbd26165213eee5ea (patch)
treea5896e08bad9ed81d244d6075fe22d2bb222ed66
parentc3e265947d2886420e007290f119e91bce7c5921 (diff)
kvmap (27mar20)
git-svn-id: svn://tug.org/texlive/trunk@54585 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/kvmap/kvmap.pdfbin108264 -> 109392 bytes
-rw-r--r--Master/texmf-dist/source/latex/kvmap/kvmap.dtx27
-rw-r--r--Master/texmf-dist/source/latex/kvmap/kvmap.ins2
-rw-r--r--Master/texmf-dist/tex/latex/kvmap/kvmap.sty12
4 files changed, 34 insertions, 7 deletions
diff --git a/Master/texmf-dist/doc/latex/kvmap/kvmap.pdf b/Master/texmf-dist/doc/latex/kvmap/kvmap.pdf
index 2325b051146..ca8a7b82c41 100644
--- a/Master/texmf-dist/doc/latex/kvmap/kvmap.pdf
+++ b/Master/texmf-dist/doc/latex/kvmap/kvmap.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/kvmap/kvmap.dtx b/Master/texmf-dist/source/latex/kvmap/kvmap.dtx
index efa6b2e481d..b5fa08b04f4 100644
--- a/Master/texmf-dist/source/latex/kvmap/kvmap.dtx
+++ b/Master/texmf-dist/source/latex/kvmap/kvmap.dtx
@@ -1,5 +1,5 @@
% \iffalse meta-comment
-% This is kvmap, (c) 2019 Ben Frank
+% This is kvmap, (c) 2020 Ben Frank
%
% It may be distributed and/or modified under the conditions of the
% LaTeX Project Public License (LPPL), either version 1.3c of this
@@ -15,7 +15,7 @@
\input l3docstrip.tex
\askforoverwritefalse
\preamble
-Copyright (C) 2019 Ben Frank
+Copyright (C) 2020 Ben Frank
It may be distributed and/or modified under the conditions of
the LaTeX Project Public License (LPPL), either version 1.3c of
@@ -102,7 +102,7 @@ End of file
%<*pkg>
%<@@=kvmap>
\RequirePackage{expl3}
-\ProvidesExplPackage{kvmap}{2019/12/26}{0.3.2}{Drawing karnaugh maps with LaTeX}
+\ProvidesExplPackage{kvmap}{2020/03/27}{0.3.3}{Drawing karnaugh maps with LaTeX}
%</pkg>
% \fi
%
@@ -212,6 +212,10 @@ End of file
% With |color| you may change the color of the border and |reducespace|
% allows you to specify whether you want the package to be narrower or wider.
% \par
+% When using |invert|, the package tries to determine where to invert
+% automatically. Sometimes it fails with the guesswork. You can manually
+% disable the horizontal inversion part with |hinvert=false| (idem for the
+% vertical inversion part with |vinvert=false|).\par
% Warning: This package is unable to draw a bundle including all four corners
% this way. If you need this specific edge case, please use TikZ to draw it
% yourself (see the last example in \autoref{sec:examples}).
@@ -447,7 +451,8 @@ End of file
% \subsection{Implicant-related code}
% \begin{macro}[updated=2018-03-17]{\bundle}
% \changes{v0.1.1}{2018/03/17}{Correct dimensions}
-% \changes{v0.2.1}{2018/09/20}{Fix inversion}
+% \changes{v0.2.1}{2018/09/20}{Fix inversion}
+% \changes{v0.3.3}{2020/03/27}{Introduce hinvert and vinvert}
% Draw a bundle with given corners.
% \begin{arguments}
% \item key-value pairs
@@ -476,6 +481,18 @@ End of file
invert .default:n = true,
invert .initial:n = false,
% \end{macrocode}
+% |vinvert|: perform inversion vertically
+% \begin{macrocode}
+ vinvert .bool_set:N = \l_@@_bundle_vinvert_bool,
+ vinvert .default:n = true,
+ vinvert .initial:n = true,
+% \end{macrocode}
+% |hinvert|: perform inversion horizontally
+% \begin{macrocode}
+ hinvert .bool_set:N = \l_@@_bundle_hinvert_bool,
+ hinvert .default:n = true,
+ hinvert .initial:n = true,
+% \end{macrocode}
% |overlapmargins|: intrude into margin (when inverted)
% \begin{macrocode}
overlapmargins .dim_set:N = \l_@@_bundle_overlapmargins_dim,
@@ -525,6 +542,7 @@ End of file
{
\int_compare_p:n { \l_@@_matrix_height_int - 1 = \l_@@_bundle_maxy_int }
&& \int_compare_p:n { 0 = \l_@@_bundle_miny_int }
+ && \l_@@_bundle_vinvert_bool
}
{
\draw[draw=\l_@@_bundle_color_tl,kvbundle] ~
@@ -569,6 +587,7 @@ End of file
{
\int_compare_p:n { \l_@@_matrix_width_int - 1 = \l_@@_bundle_maxx_int }
&& \int_compare_p:n { 0 = \l_@@_bundle_minx_int }
+ && \l_@@_bundle_hinvert_bool
}
{
\draw[draw=\l_@@_bundle_color_tl,kvbundle] ~
diff --git a/Master/texmf-dist/source/latex/kvmap/kvmap.ins b/Master/texmf-dist/source/latex/kvmap/kvmap.ins
index 57689e0fce1..17c7f53e834 100644
--- a/Master/texmf-dist/source/latex/kvmap/kvmap.ins
+++ b/Master/texmf-dist/source/latex/kvmap/kvmap.ins
@@ -1,7 +1,7 @@
\input l3docstrip.tex
\askforoverwritefalse
\preamble
-Copyright (C) 2019 Ben Frank
+Copyright (C) 2020 Ben Frank
It may be distributed and/or modified under the conditions of
the LaTeX Project Public License (LPPL), either version 1.3c of
diff --git a/Master/texmf-dist/tex/latex/kvmap/kvmap.sty b/Master/texmf-dist/tex/latex/kvmap/kvmap.sty
index 4a736e96c11..f0dd8880570 100644
--- a/Master/texmf-dist/tex/latex/kvmap/kvmap.sty
+++ b/Master/texmf-dist/tex/latex/kvmap/kvmap.sty
@@ -5,7 +5,7 @@
%% The original source files were:
%%
%% kvmap.dtx (with options: `pkg,cfg')
-%% Copyright (C) 2019 Ben Frank
+%% Copyright (C) 2020 Ben Frank
%%
%% It may be distributed and/or modified under the conditions of
%% the LaTeX Project Public License (LPPL), either version 1.3c of
@@ -15,7 +15,7 @@
%% http://www.latex-project.org/lppl.txt
%%
\RequirePackage{expl3}
-\ProvidesExplPackage{kvmap}{2019/12/26}{0.3.2}{Drawing karnaugh maps with LaTeX}
+\ProvidesExplPackage{kvmap}{2020/03/27}{0.3.3}{Drawing karnaugh maps with LaTeX}
\RequirePackage{xparse}
\RequirePackage{tikz}
\RequirePackage{environ}
@@ -94,6 +94,12 @@ color .initial:n = { black },
invert .bool_set:N = \l__kvmap_bundle_invert_bool,
invert .default:n = true,
invert .initial:n = false,
+vinvert .bool_set:N = \l__kvmap_bundle_vinvert_bool,
+vinvert .default:n = true,
+vinvert .initial:n = true,
+hinvert .bool_set:N = \l__kvmap_bundle_hinvert_bool,
+hinvert .default:n = true,
+hinvert .initial:n = true,
overlapmargins .dim_set:N = \l__kvmap_bundle_overlapmargins_dim,
overlapmargins .initial:n = { 0pt },
}
@@ -116,6 +122,7 @@ overlapmargins .initial:n = { 0pt },
{
\int_compare_p:n { \l__kvmap_matrix_height_int - 1 = \l__kvmap_bundle_maxy_int }
&& \int_compare_p:n { 0 = \l__kvmap_bundle_miny_int }
+ && \l__kvmap_bundle_vinvert_bool
}
{
\draw[draw=\l__kvmap_bundle_color_tl,kvbundle] ~
@@ -157,6 +164,7 @@ yshift=-\l__kvmap_bundle_overlapmargins_dim]
{
\int_compare_p:n { \l__kvmap_matrix_width_int - 1 = \l__kvmap_bundle_maxx_int }
&& \int_compare_p:n { 0 = \l__kvmap_bundle_minx_int }
+ && \l__kvmap_bundle_hinvert_bool
}
{
\draw[draw=\l__kvmap_bundle_color_tl,kvbundle] ~