I'd like to have a conditional macro that emboldens symbols, using different commands depending on whether the argument is a math symbol or text. Specifically, I'd like to use \bm for math symbols and \mathbf for alphanumeric characters. Thus it would look something like
\def\vec#1{\ifthenelse{\ismathsymbol{#1}}{\bm{#1}}{\mathbf{#1}}
Problem is I don't know of a test such as \ismathsymbol. Obviously, it would be just fine if there were a test for alphanumeric characters.
Thanks for any advice!
\newcommand\vec[1]{\mathbf{\bm{#1}}}– David Carlisle Jul 17 '15 at 00:56amssymb? – cfr Jul 17 '15 at 01:35v,\nu,ABare math symbols butshiftis text? How can TeX Tell the difference between the last two? – Symbol 1 Jul 17 '15 at 03:32