summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/hep-float
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2023-07-14 21:09:21 +0000
committerKarl Berry <karl@freefriends.org>2023-07-14 21:09:21 +0000
commitbbb03c1fc0127127c603a65b7d7bd6ee4a1ebe15 (patch)
tree5898e50cdde69ff40c4e74419b16ea4b25a852ef /Master/texmf-dist/tex/latex/hep-float
parent0c96e0274d668f42cffaf17536417a5af6a3ba48 (diff)
hep-* (14jul23)
git-svn-id: svn://tug.org/texlive/trunk@67632 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/hep-float')
-rw-r--r--Master/texmf-dist/tex/latex/hep-float/hep-float.sty79
1 files changed, 68 insertions, 11 deletions
diff --git a/Master/texmf-dist/tex/latex/hep-float/hep-float.sty b/Master/texmf-dist/tex/latex/hep-float/hep-float.sty
index f23be0f008c..99c08cb29db 100644
--- a/Master/texmf-dist/tex/latex/hep-float/hep-float.sty
+++ b/Master/texmf-dist/tex/latex/hep-float/hep-float.sty
@@ -6,7 +6,7 @@
%%
%% hep-float-implementation.dtx (with options: `package')
%% This is a generated file.
-%% Copyright (C) 2019-2020 by Jan Hajer
+%% Copyright (C) 2019-2023 by Jan Hajer
%% This file may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
%% version 1.3c of this license or (at your option) any later
@@ -16,7 +16,7 @@
%% LaTeX version 2005/12/01 or later.
\NeedsTeXFormat{LaTeX2e}[2005/12/01]
-\ProvidesPackage{hep-float}[2022/11/01 v1.1 Float adjustments ]
+\ProvidesPackage{hep-float}[2023/07/01 v1.2 Float adjustments]
\RequirePackage{kvoptions}
\SetupKeyvalOptions{
@@ -38,19 +38,75 @@
\let\end@hep@table\endtable%
\ifhepfloat@manualplacement%
\renewenvironment{figure}[1][tbp]{%
- \hep@figure[#1]\centering%
+ \hep@figure[#1]\centering\small%
}{\end@hep@figure}%
\renewenvironment{table}[1][tbp]{%
- \hep@table[#1]\centering%
+ \hep@table[#1]\centering\small%
}{\end@hep@table}%
\else%
\renewenvironment{figure}[1][]{%
- \hep@figure\centering%
+ \hep@figure\centering\small%
}{\end@hep@figure}%
\renewenvironment{table}[1][]{%
- \hep@table\centering%
+ \hep@table\centering\small%
}{\end@hep@table}
\fi%
+\newcommand{\figurehspace}{0.0333}
+\newcommand{\figurevspace}{.5\baselineskip}
+\newenvironment{figures}[2][b]{%
+ \begin{figure}
+ \let\oldcaption\caption
+ \renewcommand{\caption}[1]{%
+ \renewcommand{\caption}{\oldcaption}%
+ \captionof{figure}{##1}\vspace{\figurevspace}%
+ }
+ \ifdim#2pt>1pt%
+ \newcommand{\hep@figure@space}{\figurehspace\linewidth/#2}%
+ \renewcommand{\figure}[1][b]{%
+ \end{minipage}\hfill%
+ \begin{minipage}[##1]{\linewidth/#2-\hep@figure@space}%
+ }
+ \begin{minipage}[#1]{\linewidth/#2-\hep@figure@space}
+ \else%
+ \newcommand{\hep@figure@space}[1]{##1\linewidth*\real{\figurehspace}}
+ \renewcommand{\figure}[2][b]{%
+ \end{minipage}\hfill%
+ \begin{minipage}[##1]{##2\linewidth-\hep@figure@space{##2}}%
+ }
+ \begin{minipage}[#1]{#2\linewidth-\hep@figure@space{#2}}
+ \fi%
+}{%
+\end{minipage}\end{figure}%
+}
+\newcommand{\tablehspace}{0.0333}
+\newcommand{\tablevspace}{.5\baselineskip}
+\newenvironment{tables}[2][b]{%
+ \begin{table}
+ \let\oldcaption\caption
+ \renewcommand{\caption}[1]{%
+ \renewcommand{\caption}{\oldcaption}%
+ \captionof{table}{##1}\vspace{\tablevspace}%
+ }
+ \ifdim#2pt>1pt%
+ \newcommand{\hep@table@space}{\tablehspace\linewidth/#2}%
+ \renewcommand{\table}[1][b]{%
+ \end{minipage}\hfill%
+ \begin{minipage}[##1]{\linewidth/#2-\hep@table@space}\centering%
+ }
+ \begin{minipage}[#1]{\linewidth/#2-\hep@table@space}\centering
+ \else%
+ \newcommand{\hep@table@space}[1]{##1\linewidth*\real{\tablehspace}}
+ \renewcommand{\table}[2][b]{%
+ \end{minipage}\hfill%
+ \begin{minipage}[##1]{##2\linewidth-\hep@table@space{##2}}%
+ \centering%
+ }
+ \begin{minipage}[#1]{#2\linewidth-\hep@table@space{#2}}%
+ \centering
+ \fi%
+}{%
+\end{minipage}\end{table}%
+}
\PassOptionsToPackage{subrefformat=parens}{subcaption}
\RequirePackage{subcaption}
\captionsetup{font=small}
@@ -81,18 +137,19 @@
}%
\begin@subcaption@minipage[#1]{\linewidth/#2-\hep@panel@space}%
\else%
+ \newcommand{\hep@panel@space}[1]{##1\linewidth*\real{\panelhspace}}%
\newcommand{\panel}[2][b]{%
\endminipage\hfill\begin@subcaption@minipage[#1]{%
- ##2\linewidth-##2\linewidth*\real{\panelhspace}%
+ ##2\linewidth-\hep@panel@space{##2}%
}%
}%
\begin@subcaption@minipage[#1]{%
- #2\linewidth-#2\linewidth*\real{\panelhspace}%
+ #2\linewidth-\hep@panel@space{#2}%
}%
\fi%
-}{
-\endsubcaptionblock
-\vspace{-\panelvspace}
+}{%
+\endsubcaptionblock%
+\vspace{-\panelvspace}%
}
\RequirePackage{booktabs}
\RequirePackage{multirow}