0

I want to change the command \textsubscript to \tsub by writing the following line in the preamble:

\renewcommand{\textsubscript}{\tsub}

but, unfortunately, it doesn't work !

  • 1
    Did you try \let? You wrote \renewcomman instead of \renewcommand. – Marco Daniel Apr 1 '13 at 14:20
  • 1
    Does \tsub previously defined? – Sigur Apr 1 '13 at 14:21
  • 2
    The other way around: \newcommand{\tsub}{\textsubscript} – egreg Apr 1 '13 at 14:21
  • @ Marco Daniel ... I wrote it \renewcommand in my document. I tried \let and it works :) – Muhammad Apr 1 '13 at 14:29
2

Try the following instead of \renewcommand:

\let\tsub\textsubscript
  • @ DL6ER ... It works ! , Thank you :) – Muhammad Apr 1 '13 at 14:26
  • But what is the problem with using '\renewcommand' – Muhammad Apr 1 '13 at 14:45
  • 2
    Typing: \renewcommand{\textsubscript}{\tsub} does the following: Take whatever \textsubscript does and throw it away. Let then \tsub be executed when \textsubscript is called. But \tsub might not be defined, so LaTeX don't know what to do and stop. – MrD Apr 1 '13 at 14:54
  • It's always good to know why something fails ;-) You might mark the answer as "accepted", so others will see, that this question is solved, when they have a similar problem and look for a solution. – MrD Apr 1 '13 at 16:39

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.