5

From time to time I use brackets as an equivalent of respectively, like in the following sentence:

A semigroup [monoid, group] $S$ is commutative if, for all $x, y \in S$, $xy = yx$.

Now, I would like to be able to write the same sentence in italics or slanted, while keeping the brackets in roman (or in math mode). I tried something like

\textit{$[$test$]$}

but it does not produce a nice result, because the second bracket is to close from the words in italics. Next I tried

\begin{proposition}     
 Let $M$ be a semigroup $[$monoid, group$\\,]$...  
\end{proposition}

which produces a better result, but is still far from being optimal.

So, is there a way to get the appropriate spacing around the brackets?

  • 1
    You might be interested in @cgnieder's package embrac, which (semi-)automatically handles upright parenthesis in italic text and therefore redefines \textit and \emph. – Henri Menke Oct 6 '13 at 11:38
9

The brackets are textual punctuation not math symbols so $[$ is not what you want, I think you want \textup{[} The \text... commands should automatically handle insertion of italic correction space when switching between slanted and upright styles.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.