From 4da7f648f562e59b38e65fa0f92c501b9401c32c Mon Sep 17 00:00:00 2001 From: Joshua Lucas Date: Tue, 8 Jul 2025 09:38:44 -0500 Subject: [PATCH] Merge previous changes. --- PrimeManual.sty | 35 +++++++++++++++++++++++------------ 1 file changed, 23 insertions(+), 12 deletions(-) diff --git a/PrimeManual.sty b/PrimeManual.sty index 01f2a57..2be2caf 100644 --- a/PrimeManual.sty +++ b/PrimeManual.sty @@ -37,7 +37,7 @@ Extension = .ttf, UprightFont = *-Light, BoldFont = *-SemiBold, - ItalicFont = *-Italic, + ItalicFont = *-LightItalic, BoldItalicFont = *-SemiBoldItalic, ] % Headings & Titles font: Roboto Slab @@ -75,7 +75,7 @@ % Color import and definition %#region - \RequirePackage[RGB]{xcolor} + \RequirePackage{xcolor} \definecolor{PrimeBlue}{RGB}{25,45,145} %#endregion @@ -85,12 +85,14 @@ \hypersetup{colorlinks=true, allcolors=PrimeBlue} %#endregion -% Graphics packages for including images +% Graphics package for including images %#region \RequirePackage{graphicx} \RequirePackage{calc} - \newcommand{\ig}[2][0.5in]{\includegraphics[keepaspectratio,width=#1]{graphics/#2}} + \newcommand{\ig}[2][0.5in]{ + \includegraphics[keepaspectratio,width=#1]{graphics/#2} + } %#endregion % Define custom title page. @@ -158,14 +160,8 @@ % Margin Note formatting. %#region \RequirePackage{marginnote} - % -38pt seems to be just the right vertical adjustment to align margin notes - % with the reference in the text. - %\renewcommand{\marginnotevadjust}{-38pt} \renewcommand{\marginfont}{\small\color{PrimeBlue}} - % Title formatting for margin notes. - \newcommand{\margintitle}[1]{\paragraph{\textbf{#1}}} - % Put a glossary definition in a margin note. % Optional parameter is vertical adjustment of the note. \newcommand{\margindef}[2][0pt]{% @@ -175,12 +171,26 @@ \textsf{\textbf{ \Glsentryname{#2}:% Create the title of the margin note. }} - \glsdesc*{#2}}[#1]% Create the text of the margin note. + \glsdesc*{#2} + }[#1]% Create the text of the margin note. } % Put a footnote in a margin note. % Optional parameter is vertical adjustment of the note. - \newcommand{\mnote}[2][0pt]{\footnotemark\marginnote{\footnotemark[\value{footnote}]#2}[#1]} + \newcommand{\mnote}[2][0pt]{% + \footnotemark + \marginnote{ + \footnotemark[\value{footnote}]#2}[#1] + } + + \RequirePackage[hypcap=true]{caption} + \newcommand{\marginfig}[2]{% + \marginnote{ + \captionsetup{type=figure}% + {\centering\includegraphics{#1}\par} + \captionof{figure}{#2} + } + } %#endregion % Cross references @@ -214,6 +224,7 @@ } \newcommand{\lblTable}[2][]{ \textbf{\lblGeneral[#1]{#2}{\caption}{tbl}} + \smallskip } \newcommand{\lblFigure}[2][]{ \textbf{\lblGeneral[#1]{#2}{\caption}{fig}}