I have this line:

\textbf{Adv}\textsuperscript{downgrade}\textsubscript{$Pi$, DP, X}

But I get this output: enter image description here

And I want it like this: enter image description here

Can you help me with simple solutions as much as possible plz.


With \rlap and some \raisebox because of ascenders and descenders in the us/superscript:



\textbf{Adv}\textsubscript{\raisebox{-1pt}{\rlap{$\Pi$, DP, X}}}\textsuperscript{\raisebox{1pt}{downgrade}}


enter image description here


The code given above supposes the user knows which is shortest, of the superscript or the subscript text. The shortest has to to be enterd in the code first, the \rlapped. The following code, based on eqparbox makes it automatic:

\textbf{Adv}\textsuperscript{\raisebox{1pt}{\rlap{\eqmakebox[subp][l]{downgrade}}}}\textsubscript{\raisebox{-1pt}{\eqmakebox[subp][l]{$\Pi$, DP, X}}}
| improve this answer | |
  • This won't work if the subscript is wider than the superscript. Which is not a problem in the answer to the question this one is a duplicate of. And the “close as duplicate” vote was given several minutes before you answered. – egreg Jul 11 '16 at 20:26
  • @egreg: For the first point, I should have explained it's up to the user, in each case, which of the sub or superscript has to be ‘rlapped’. For the ‘close as duplicate’, I must say I didn't notice. Shall I withdraw my answer? – Bernard Jul 11 '16 at 20:58
  • I think that you should at least fix it. If you agree it's a duplicate, vote. – egreg Jul 11 '16 at 21:03
  • @egreg: Well, the question is indeed a duplicate, but my solution (which is now automatic, hopefully) does not rely on mathmode… – Bernard Jul 11 '16 at 21:22
  • \textsuperscript and \textsubscript do rely on math mode anyway. – egreg Jul 11 '16 at 21:29

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