[comp.text.tex] uppercase

NN1@awiwuw11.wu-wien.ac.at (11/03/90)

Suppose I have the following code

\author{John Doe \address{Michigan State Univ.}
   \and Mike Deer \address{Ohio State Univ.}
   }

and suppose further, that the \author macro is called by another macro,
say, \doauthor.

The goal is to end up with only the names in uppercase letters, but the
expansion of \address (or anything else, for that matter) unaffected.

The simplistic approach for \doauthor, e.g.,
   \def\doauthor{\uppercase\expandafter{\author}} obviously will not
work, since the uppercase is a rather late operation and will apply to
anything in the expansion of \author.

Question 1: How to accomplish this?

This raises the following interesting aspect:

Question 2: How can one apply certain macro operations only to the
toplevel arguments?

For example, if my argument is {a b c \xxx{d e f} g}, only a, b, c, and
g should be affected.

In futilely trying to solve question 1, I also attempted to split the
argument to author into pieces that are top level elements, and pieces
that are csnames or arguments (i.e., within braces). This raises

Question 3: How can on split a piece of text into words? How can one
split a piece of text into logical units (say into: text, csnames,
brace-delimited things).

Thanks, thw.

Thomas Weigert, RISC-Linz, Johannes Kepler University Linz, Austria.
email: k316670@aearn.bitnet, weigert@mcs.anl.gov

eijkhout@s41.csrd.uiuc.edu (Victor Eijkhout) (11/03/90)

<NN1@awiwuw11.wu-wien.ac.at> writes:

>\author{John Doe \address{Michigan State Univ.}
>   \and Mike Deer \address{Ohio State Univ.}
>   }
>The goal is to end up with only the names in uppercase letters, but the
>expansion of \address (or anything else, for that matter) unaffected.

I answered this in some detail less than three weeks ago, so
I don't feel like doing it again. Let me tell you where to look:
find the siam.sty at some listserver, or get
rapport1.sty and voorwerk.sty from the listserv@hearn.bitnet.
Rapport1 is compatible to 'report' and 'voorwerk' is the replacement
that is used instead of titlpage.sty.
Send the following msg to listserv@hearn.bitnet:
  get tex-nl filelist
  get rapport1 sty
  get voorwerk sty
  get ntg10 sty
.

Good luck.

Victor.