summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/fadingimage/tex/fadingimage.sty
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2024-03-18 03:01:30 +0000
committerNorbert Preining <norbert@preining.info>2024-03-18 03:01:30 +0000
commit9c8677e09c2c9b0d9593f26ed226411d68160a4e (patch)
tree1c5464d3dc4dbe0ad27d69bec29b581f4b0d1fdd /macros/latex/contrib/fadingimage/tex/fadingimage.sty
parent55140d5421e1ad0024c9acbfa72bd06402c2aa9f (diff)
CTAN sync 202403180301
Diffstat (limited to 'macros/latex/contrib/fadingimage/tex/fadingimage.sty')
-rw-r--r--macros/latex/contrib/fadingimage/tex/fadingimage.sty24
1 files changed, 21 insertions, 3 deletions
diff --git a/macros/latex/contrib/fadingimage/tex/fadingimage.sty b/macros/latex/contrib/fadingimage/tex/fadingimage.sty
index bde2e592cc..2b63cf0cbe 100644
--- a/macros/latex/contrib/fadingimage/tex/fadingimage.sty
+++ b/macros/latex/contrib/fadingimage/tex/fadingimage.sty
@@ -18,12 +18,13 @@
%% available at https://github.com/xiamyphys/FadingImage *
%% ****************************************************************************************************
\NeedsTeXFormat{LaTeX2e}[2020/10/01]
-\ProvidesPackage{fadingimage}[2024/03/11/ v0.1c Package for adding fading full width picture at the top or bottom of a page.]
+\ProvidesPackage{fadingimage}[2024/03/17/ v0.1d Package for adding fading full width picture at the top or bottom of a page.]
\RequirePackage{tikz,xcolor}
\usetikzlibrary{fadings}
\NewDocumentCommand{\UPFadingImage}{ s O{} m }{
- \IfBooleanTF{#1}{
+ \IfBooleanTF{#1}
+ {
\tikz[remember picture,overlay]
\node[below,inner sep=0pt,outer sep=auto] at (current page.north) {\includegraphics[width=\paperwidth,#2]{#3}};
}{
@@ -31,12 +32,29 @@
\node[scope fading=south,below,inner sep=0pt,outer sep=auto] at (current page.north) {\includegraphics[width=\paperwidth,#2]{#3}};
}
}
+
\NewDocumentCommand{\LOWFadingImage}{ s O{} m }{
- \IfBooleanTF{#1}{
+ \IfBooleanTF{#1}
+ {
\tikz[remember picture,overlay]
\node[above,inner sep=0pt,outer sep=auto] at (current page.south) {\includegraphics[width=\paperwidth,#2]{#3}};
}{
\tikz[remember picture,overlay]
\node[scope fading=north,above,inner sep=0pt,outer sep=auto] at (current page.south) {\includegraphics[width=\paperwidth,#2]{#3}};
}
+}
+
+\NewDocumentCommand{\UPLOWFadingImage}{ s O{} m O{} m }{
+ \IfBooleanTF{#1}
+ {
+ \tikz[remember picture,overlay]{
+ \node[below,inner sep=0pt,outer sep=auto] at (current page.north) {\includegraphics[width=\paperwidth,#2]{#3}};
+ \node[above,inner sep=0pt,outer sep=auto] at (current page.south) {\includegraphics[width=\paperwidth,#4]{#5}};
+ }
+ }{
+ \tikz[remember picture,overlay]{
+ \node[scope fading=south,below,inner sep=0pt,outer sep=auto] at (current page.north) {\includegraphics[width=\paperwidth,#2]{#3}};
+ \node[scope fading=north,above,inner sep=0pt,outer sep=auto] at (current page.south) {\includegraphics[width=\paperwidth,#4]{#5}};
+ }
+ }
} \ No newline at end of file