EB-Garamond icon indicating copy to clipboard operation
EB-Garamond copied to clipboard

Upright Parentheses And Brackets in Italic Text

Open amarakon opened this issue 1 year ago • 9 comments

I want to typeset all parentheses and brackets upright even in italic text. I can do this in LaTeX using the embrac package which automatically makes them upright. The downside of this approach is that I have to manually adjust the kerning to avoid collisions. I think it would be the most ideal if the italic font had a stylistic set that keeps parentheses and brackets upright with good kerning to take care of any potential collisions.

\documentclass{article}

\usepackage{fontspec}
\usepackage{embrac}

\setmainfont[ItalicFont = * 12 Italic]{EB Garamond}

\AddEmph{⸢}[0pt, 0pt]{⸣}[0.3em, 0pt]
\ChangeEmph{(}[0.2em, 0pt]{)}[0pt, 0pt]
\ChangeEmph{[}[0.2em, 0pt]{]}[0pt, 0pt]

\begin{document}

\emph{⸢f⸣}
\emph{(just)}
\emph{[just]}

\end{document}

import-2023-04-04_18:35:18

amarakon avatar Apr 04 '23 22:04 amarakon