- Fix \Appendices command.
- Create float for code. - Adjust fallback font weights. - Redefine Center environment to eliminate extra space. - Create TblrEnviron for code.
This commit is contained in:
@@ -160,7 +160,7 @@
|
||||
\colorlet{codeKeywordColor}{PrimeLightBlue}
|
||||
\colorlet{codeOperatorColor}{PrimeLightPink}
|
||||
\colorlet{codeCommentColor}{PrimeLightMint}
|
||||
\colorlet{codeNumberColor}{textColor}
|
||||
\colorlet{codeNumberColor}{textColor}%{PrimeLightLime}
|
||||
\colorlet{codeStringColor}{PrimeLightLime}
|
||||
} {
|
||||
% Page and text colors.
|
||||
@@ -200,7 +200,7 @@
|
||||
\colorlet{codeKeywordColor}{PrimeBlue}
|
||||
\colorlet{codeOperatorColor}{PrimePink}
|
||||
\colorlet{codeCommentColor}{PrimeMint}
|
||||
\colorlet{codeNumberColor}{textColor}
|
||||
\colorlet{codeNumberColor}{textColor}%{PrimeLime}
|
||||
\colorlet{codeStringColor}{PrimeLime}
|
||||
}
|
||||
|
||||
|
||||
@@ -64,8 +64,8 @@
|
||||
\@@_heading:nnnnn {subparagraph} {#1} {#2} {#3} {#4}
|
||||
}
|
||||
|
||||
\NewDocumentCommand{\Appendices}{}{
|
||||
\@@_heading:nnnnn {part} {\c_true_bool} {\c_false_bool} {Appendices} {
|
||||
\NewDocumentCommand{\Appendices}{t^}{
|
||||
\@@_heading:nnnnn {part} {\c_true_bool} {#1} {Appendices} {
|
||||
\c_@@_appendices_label_str
|
||||
}
|
||||
}
|
||||
|
||||
@@ -360,4 +360,27 @@
|
||||
\\
|
||||
\end{tblr}
|
||||
\end{BigFloat}
|
||||
\group_end: }
|
||||
\group_end: }
|
||||
|
||||
\NewDocumentEnvironment{CodeFloat}{
|
||||
% #1: Label.
|
||||
>{\TrimSpaces}m
|
||||
% #2: Caption.
|
||||
+m
|
||||
% #3: Number of indentations.
|
||||
m
|
||||
% #4: Body text.
|
||||
+b
|
||||
}{
|
||||
\begin{figure}
|
||||
\begin{MyCaption}{fig:#1}{#2}
|
||||
\Centering
|
||||
\begin{tblrCode}{
|
||||
colspec = {*{#3}{l}},
|
||||
hline{1,Z} = {0.6pt},
|
||||
}
|
||||
#4
|
||||
\end{tblrCode}
|
||||
\end{MyCaption}
|
||||
\end{figure}
|
||||
}{}
|
||||
@@ -23,8 +23,8 @@
|
||||
|
||||
luaotfload.add_fallback(
|
||||
"Roboto", {
|
||||
"NotoSans:mode=harf;",
|
||||
"NotoSansSymbols:mode=harf;",
|
||||
"NotoSans-Medium:mode=harf;",
|
||||
"NotoSansSymbols-SemiBold:mode=harf;",
|
||||
"NotoSansSymbols2:mode=harf;",
|
||||
"NotoEmoji:mode=harf;",
|
||||
}
|
||||
@@ -33,7 +33,7 @@
|
||||
luaotfload.add_fallback(
|
||||
"RobotoMono", {
|
||||
"NotoMono:mode=harf;",
|
||||
"NotoSansSymbols:mode=harf;",
|
||||
"NotoSansSymbols-SemiBold:mode=harf;",
|
||||
"NotoSansSymbols2:mode=harf;",
|
||||
"NotoEmoji:mode=harf;",
|
||||
}
|
||||
@@ -41,10 +41,10 @@
|
||||
|
||||
luaotfload.add_fallback(
|
||||
"RobotoSlab", {
|
||||
"NotoSerif:mode=harf;",
|
||||
"NotoSansSymbols:mode=harf;",
|
||||
"NotoSerif-SemiBold:mode=harf;",
|
||||
"NotoSansSymbols-SemiBold:mode=harf;",
|
||||
"NotoSansSymbols2:mode=harf;",
|
||||
"NotoEmoji:mode=harf;",
|
||||
"NotoEmoji-SemiBold:mode=harf;",
|
||||
}
|
||||
)
|
||||
}
|
||||
@@ -56,6 +56,8 @@
|
||||
BoldFont = *-SemiBold,
|
||||
ItalicFont = *-LightItalic,
|
||||
BoldItalicFont = *-SemiBoldItalic,
|
||||
SlantFont = RobotoSlab-SemiBold,
|
||||
BoldSlantFont = RobotoSlab-Black,
|
||||
RawFeature = {fallback=RobotoSerif},
|
||||
]
|
||||
|
||||
|
||||
@@ -108,6 +108,8 @@
|
||||
}
|
||||
}{}
|
||||
|
||||
\RenewDocumentEnvironment{Center}{}{\group_begin:\Centering}{\par\group_end:}
|
||||
|
||||
|
||||
\ExplSyntaxOff
|
||||
\AtBeginDocument{
|
||||
|
||||
@@ -30,6 +30,13 @@
|
||||
hline{2} = {0.4pt},
|
||||
}
|
||||
|
||||
\NewTblrEnviron{tblrCode}
|
||||
\SetTblrInner[tblrCode]{
|
||||
rows = {font=\ttfamily\small},
|
||||
hlines = {0pt},
|
||||
colsep = {0pt},
|
||||
}
|
||||
|
||||
\NewTblrTableCommand{\midtitle}[2][pageColor]{
|
||||
\SetCell[c=#2]{
|
||||
c, m,
|
||||
|
||||
Reference in New Issue
Block a user