3
$\begingroup$

Suppose that I use Graphics, Text, and Style to type one letter in the subscript of a letter and one in the superscript of the same letter. In the Writing Assistant in Mathematica 9, I click the button button to help typeset the string in this command:

Graphics[Text[
  Style["\!\(\*SubsuperscriptBox[\(A\), \(B\), \(C\)]\)", 30, 
   FontFamily -> "Arial"]]]

The graphical output is the following.

example

Why do the letters A, B, and C appear italic, even though I did not specify them as such? I want the letters to all be regular font. The italicization does not happen if I take out the Graphics directive, and just use Text and Style. But I have to use Graphics because I will ultimately include it in a plot.

$\endgroup$
2
  • 2
    $\begingroup$ check out SingleLetterItalics $\endgroup$
    – chuy
    Apr 16, 2014 at 16:27
  • 1
    $\begingroup$ you can change the single letter italics, referenced in the previous comment, like this: Graphics[Text[Style["...", 30,FontFamily -> "Arial",SingleLetterItalics -> False]]] $\endgroup$ Apr 16, 2014 at 22:12

1 Answer 1

8
$\begingroup$
Graphics[Text[
  Style[Subsuperscript["A", "B", "C"], 30, FontFamily -> "Arial", 
   SingleLetterItalics -> False]]]

enter image description here

or

Graphics[Text[
  Style[Subsuperscript[Style["A", Italic], "B", "C"], 30, 
   FontFamily -> "Arial", SingleLetterItalics -> False]]]

enter image description here

$\endgroup$
1
  • $\begingroup$ The very subtle difference lurks in from the difference of SubscriptBox and Subscript! With Subscript the text is upright in Graphics by default (v11). $\endgroup$
    – Johu
    Aug 29, 2018 at 0:07

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.