5

I am writing a school report which has to be evaluated by two different teachers.

I need to mark which sections each teacher should read. I guess I can make a small symbol next to the header to mark which teacher the specific section is written to.

How is this possible?

I guess I can do something like

\section{Milking the Cow}
\teacher{A}
Some text

or editing the section headers or something like that.

2 Answers 2

6

A margin symbol could be clearer and less intrusive:

\documentclass{article}
\usepackage{lipsum,xcolor}
\def\Smith{\rlap{\protect\makebox[-3cm]{\color{red}\S}}}
\def\Philips{\rlap{\protect\makebox[-3cm]{\color{red}$\Phi$}}}
\def\Omar{\rlap{\protect\makebox[-3cm]{\color{red}$\Omega$}}}
\begin{document}
\section{\Smith Lore ipsum}\lipsum[2]
\section{\Philips Nulla malesuada}\lipsum[3]
\section{\Omar Quisque ullamcorper}\lipsum[4]
\end{document}

MWE

7

Give them some magic so that they can give you good marks!

\documentclass{article}
\def\TA{{\color{red}\staveVI}} \def\TB{{\color{blue}\staveXXXVI}}
\usepackage{staves,xcolor,lipsum}
\begin{document}
\section{test}
\TA\lipsum[1]
\section {test}
\TB\lipsum[2]
\end{document}

enter image description here

If you change the definitions to robust commands you can also put them in the section title.

\DeclareRobustCommand\TA{{\color{red}\staveVI}}
\DeclareRobustCommand\TB{{\color{blue}\staveXXXVI}}

enter image description here

I sort of like them so as cleaders

\makeatletter
\def\TA{%
   \bgroup%
   \leavevmode
   \color{red}\tiny%
   \cleaders \hb@xt@ 1.5em{\hss\staveVI\hss}\hfill
   \kern\z@
   \egroup}

\def\TB{%
   \bgroup%
   \leavevmode
   \color{blue}\tiny%
   \cleaders \hb@xt@ 1.5em{\hss\staveXXXVI\hss}\hfill
   \kern\z@
   \egroup}  
 \makeatother

Leader glue is one of those magical ingedients of TeX!

enter image description here

3
  • Haha - I like it. Can the symbols be right aligned in the section header and with the same height as the text, so it wont "conflict" with the normal layout. Thank you!
    – Jamgreen
    Jun 6, 2015 at 9:40
  • 2
    @Jamgreen This will need some more magic. Change to \DeclareRobustCommand\TA{\hfill\scalebox{.3}{\mbox{\color{red}\staveVI}}}, but when they are smaller they lose their power:) Also don't forget to add \usepackage{graphicx} for the scalebox
    – yannisl
    Jun 6, 2015 at 9:52
  • 1
    Now the problem is that they are also present in the table of contents. Is it possible to hide them there? :-D
    – Jamgreen
    Jun 6, 2015 at 10:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .