Add indented lines override to \wrapfig.
This commit is contained in:
@@ -142,15 +142,6 @@
|
|||||||
\keys_define:nn{}{
|
\keys_define:nn{}{
|
||||||
BigFig .inherit:n = BigFloat,
|
BigFig .inherit:n = BigFloat,
|
||||||
}
|
}
|
||||||
% \keys_define:nn{BigFig}{
|
|
||||||
% overhang .dim_set:N = \l_BigFig_overhang_dim,
|
|
||||||
% overhang .initial:e = {\c_BigFloat_overhang_dim},
|
|
||||||
|
|
||||||
% placement .clist_set:N= \l_BigFig_placement_clist,
|
|
||||||
|
|
||||||
% offset .fp_set:N = \l_BigFig_offset_fp,
|
|
||||||
% offset .initial:e = {\c_BigFloat_offset_fp},
|
|
||||||
% }
|
|
||||||
|
|
||||||
\NewDocumentCommand{\BigFig}{
|
\NewDocumentCommand{\BigFig}{
|
||||||
% Key=value options.
|
% Key=value options.
|
||||||
|
|||||||
@@ -57,6 +57,8 @@
|
|||||||
ItalicFont = NotoEmoji/NotoEmoji-Light,
|
ItalicFont = NotoEmoji/NotoEmoji-Light,
|
||||||
]
|
]
|
||||||
|
|
||||||
|
\RequirePackage{amssymb}
|
||||||
|
|
||||||
\NewDocumentCommand{\serif}{m}{\textrm{#1}}
|
\NewDocumentCommand{\serif}{m}{\textrm{#1}}
|
||||||
\NewDocumentCommand{\sans}{m}{\textsf{#1}}
|
\NewDocumentCommand{\sans}{m}{\textsf{#1}}
|
||||||
\NewDocumentCommand{\mono}{m}{\texttt{#1}}
|
\NewDocumentCommand{\mono}{m}{\texttt{#1}}
|
||||||
@@ -64,8 +66,6 @@
|
|||||||
\NewDocumentCommand{\code}{m}{\mono{\small{}#1}}
|
\NewDocumentCommand{\code}{m}{\mono{\small{}#1}}
|
||||||
\NewDocumentCommand{\emoji}{m}{{\emfamily{}#1}}
|
\NewDocumentCommand{\emoji}{m}{{\emfamily{}#1}}
|
||||||
|
|
||||||
\RequirePackage{amssymb}
|
|
||||||
|
|
||||||
\RequirePackage[os=win]{menukeys}
|
\RequirePackage[os=win]{menukeys}
|
||||||
|
|
||||||
\renewmenumacro{\directory}[/]{hyphenatepaths}
|
\renewmenumacro{\directory}[/]{hyphenatepaths}
|
||||||
|
|||||||
@@ -44,28 +44,40 @@
|
|||||||
\includegraphics[keepaspectratio,#1]{#2}%
|
\includegraphics[keepaspectratio,#1]{#2}%
|
||||||
}
|
}
|
||||||
|
|
||||||
\NewDocumentCommand{\wrapfig}{
|
\NewDocumentCommand{\@wrapfigbody}{m m m m}{
|
||||||
% alignment [l,r,i,o]
|
|
||||||
O{O}
|
|
||||||
% horizontal_offset
|
|
||||||
O{\marparwidth}
|
|
||||||
% graphic_file
|
|
||||||
m
|
|
||||||
% (width|height)=lengthvalue
|
|
||||||
O{}
|
|
||||||
% label
|
|
||||||
>{\TrimSpaces}m
|
|
||||||
% caption
|
|
||||||
m%
|
|
||||||
}{%
|
|
||||||
\begin{wrapfigure}{#1}[#2]%
|
|
||||||
\captionsetup{type=figure}%
|
\captionsetup{type=figure}%
|
||||||
\capstart%
|
\capstart%
|
||||||
\includegraphics[%
|
\includegraphics[%
|
||||||
keepaspectratio,%
|
keepaspectratio,%
|
||||||
#4%
|
#2%
|
||||||
]{#3}%
|
]{#1}%
|
||||||
\Centering\captionof{figure}{#6}%
|
\Centering\captionof{figure}{#4}%
|
||||||
\label{fig:#5}%
|
\label{fig:#3}%
|
||||||
\end{wrapfigure}%
|
}
|
||||||
|
|
||||||
|
\NewDocumentCommand{\wrapfig}{
|
||||||
|
% #1: alignment [l,r,i,o]
|
||||||
|
O{O}
|
||||||
|
% #2: horizontal_offset
|
||||||
|
O{\marparwidth}
|
||||||
|
% #3: graphic_file
|
||||||
|
m
|
||||||
|
% #4: (width|height)=lengthvalue
|
||||||
|
O{}
|
||||||
|
% #5: label
|
||||||
|
>{\TrimSpaces}m
|
||||||
|
% #6: caption
|
||||||
|
m%
|
||||||
|
% #7: indented lines override
|
||||||
|
o
|
||||||
|
}{%
|
||||||
|
\IfNoValueTF{#7}{%
|
||||||
|
\begin{wrapfigure}{#1}[#2]%
|
||||||
|
\@wrapfigbody{#3}{#4}{#5}{#6}%
|
||||||
|
\end{wrapfigure}%
|
||||||
|
}{%
|
||||||
|
\begin{wrapfigure}[#7]{#1}[#2]%
|
||||||
|
\@wrapfigbody{#3}{#4}{#5}{#6}%
|
||||||
|
\end{wrapfigure}%
|
||||||
|
}%
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user