4

I am currently using the textcmds package to get the quotation marks, but how can I fix the right quotation marks in the below latex code?

$\boldmath{\q{DIST^{V1.1}\textbf{-}SPRD}}$

enter image description here

What is need is this :

enter image description here

1
  • don' ignore warnings! LaTeX Font Warning: Command \boldmath invalid in math mode on input line 4. Apr 15, 2022 at 20:09

1 Answer 1

4

A first problem with your code is that you start math mode too soon. For sure, do consider replacing

$\boldmath{\q{DIST^{V1.1}\textbf{-}SPRD}}$

with

{\boldmath\q{$DIST^{V1.1}\textbf{-}SPRD$}}

The outcome of making this change -- shown in the second row of the screenshot below -- isnt' parcicularly satisfying from a typographic point of view, though, as the spacing between the letters in the strings "DIST" and "SPRD" obeys math-mode intead of text-mode rules. To get around this issue, do encase the words in either \mathit or \mathrm wrappers.

Finally, it's not clear to me if it's even a good idea to use math mode here. For sure, do also consider writing the expression in pure text mode, as follows:

\q{\textbf{DIST\textsuperscript{V1.1}-SPRD}}

That's what's shown in the fifth row in the following screenshot.

Here's some sample code that generates all five possibilities.

enter image description here

\documentclass{article}
\usepackage{textcmds,amsmath}
\begin{document}
\obeylines % just for this example
$\boldmath{\q{DIST^{V1.1}\textbf{-}SPRD}}$
{\boldmath\q{$DIST^{V1.1}\textbf{-}SPRD$}}
{\boldmath\q{$\mathit{DIST}^{\mathit{V}1.1}\textbf{-}\mathit{SPRD}$}}
{\boldmath\q{$\mathrm{DIST}^{\mathrm{V}1.1}\textbf{-}\mathrm{SPRD}$}}
\q{\textbf{DIST\textsuperscript{V1.1}-SPRD}}
\end{document}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .