Add indented lines override to \wrapfig.
This commit is contained in:
@@ -142,15 +142,6 @@
|
||||
\keys_define:nn{}{
|
||||
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}{
|
||||
% Key=value options.
|
||||
|
||||
@@ -2,42 +2,42 @@
|
||||
\ProvidesPackage{PrimeTeX/packages/Fonts}[2025-06-24]
|
||||
|
||||
% Specify Fonts
|
||||
\RequirePackage{fontspec}
|
||||
\RequirePackage{fontspec}
|
||||
|
||||
\NewDocumentCommand{\fontpath}{}{PrimeTeX/fonts}
|
||||
\NewDocumentCommand{\fontpath}{}{PrimeTeX/fonts}
|
||||
|
||||
% Main font: Roboto Serif
|
||||
\setmainfont{RobotoSerif}[
|
||||
% Main font: Roboto Serif
|
||||
\setmainfont{RobotoSerif}[
|
||||
Path = {\fontpath/RobotoSerif/},
|
||||
Extension = .ttf,
|
||||
UprightFont = *-Light,
|
||||
BoldFont = *-SemiBold,
|
||||
ItalicFont = *-LightItalic,
|
||||
BoldItalicFont = *-SemiBoldItalic,
|
||||
]
|
||||
]
|
||||
|
||||
% Sans serif font: Roboto
|
||||
\setsansfont{Roboto}[
|
||||
% Sans serif font: Roboto
|
||||
\setsansfont{Roboto}[
|
||||
Path = {\fontpath/Roboto/},
|
||||
Extension = .ttf,
|
||||
UprightFont = *-Regular,
|
||||
BoldFont = *-Bold,
|
||||
ItalicFont = *-Italic,
|
||||
BoldItalicFont = *-BoldItalic,
|
||||
]
|
||||
]
|
||||
|
||||
% Monospace font: Roboto Mono
|
||||
\setmonofont{RobotoMono}[
|
||||
% Monospace font: Roboto Mono
|
||||
\setmonofont{RobotoMono}[
|
||||
Path = {\fontpath/RobotoMono/},
|
||||
Extension = .ttf,
|
||||
UprightFont = *-Regular,
|
||||
BoldFont = *-Bold,
|
||||
ItalicFont = *-Italic,
|
||||
BoldItalicFont = *-BoldItalic,
|
||||
]
|
||||
]
|
||||
|
||||
% Headings & Titles font: Roboto Slab
|
||||
\newfontfamily{\sbfamily}{RobotoSlab}[
|
||||
% Headings & Titles font: Roboto Slab
|
||||
\newfontfamily{\sbfamily}{RobotoSlab}[
|
||||
Path = {\fontpath/},
|
||||
Extension = .ttf,
|
||||
UprightFont = RobotoSlab/RobotoSlab-SemiBold,
|
||||
@@ -46,16 +46,18 @@
|
||||
% the Roboto Serif version.
|
||||
ItalicFont = RobotoSerif/RobotoSerif-SemiBoldItalic,
|
||||
BoldItalicFont = RobotoSerif/RobotoSerif-ExtraBoldItalic,
|
||||
]
|
||||
]
|
||||
|
||||
% Emoji font: Noto Emoji
|
||||
\newfontfamily{\emfamily}{NotoEmoji}[
|
||||
% Emoji font: Noto Emoji
|
||||
\newfontfamily{\emfamily}{NotoEmoji}[
|
||||
Path = {\fontpath/},
|
||||
Extension = .ttf,
|
||||
UprightFont = NotoEmoji/NotoEmoji-Regular,
|
||||
BoldFont = NotoEmoji/NotoEmoji-Bold,
|
||||
ItalicFont = NotoEmoji/NotoEmoji-Light,
|
||||
]
|
||||
]
|
||||
|
||||
\RequirePackage{amssymb}
|
||||
|
||||
\NewDocumentCommand{\serif}{m}{\textrm{#1}}
|
||||
\NewDocumentCommand{\sans}{m}{\textsf{#1}}
|
||||
@@ -64,8 +66,6 @@
|
||||
\NewDocumentCommand{\code}{m}{\mono{\small{}#1}}
|
||||
\NewDocumentCommand{\emoji}{m}{{\emfamily{}#1}}
|
||||
|
||||
\RequirePackage{amssymb}
|
||||
|
||||
\RequirePackage[os=win]{menukeys}
|
||||
|
||||
\renewmenumacro{\directory}[/]{hyphenatepaths}
|
||||
|
||||
@@ -44,28 +44,40 @@
|
||||
\includegraphics[keepaspectratio,#1]{#2}%
|
||||
}
|
||||
|
||||
\NewDocumentCommand{\wrapfig}{
|
||||
% 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]%
|
||||
\NewDocumentCommand{\@wrapfigbody}{m m m m}{
|
||||
\captionsetup{type=figure}%
|
||||
\capstart%
|
||||
\includegraphics[%
|
||||
keepaspectratio,%
|
||||
#4%
|
||||
]{#3}%
|
||||
\Centering\captionof{figure}{#6}%
|
||||
\label{fig:#5}%
|
||||
\end{wrapfigure}%
|
||||
#2%
|
||||
]{#1}%
|
||||
\Centering\captionof{figure}{#4}%
|
||||
\label{fig:#3}%
|
||||
}
|
||||
|
||||
\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