TeXnik - Tips TeX and LaTeX


Welcome to the TeXnik website (under construction)

First Letter of a Word in Bold
TUG logo

Main page

Index
UK FAQ
Documentation
Software
CTAN
Search CTAN:

Statistics

Google c.t.t.

Google d.c.t.t.

 


 


an example

the latex code

% by Heiko Oberdiek
\newcommand*{\formatfirst}[1]{\textbf{#1}}
\newcommand*{\formatrest}[1]{\textsc{#1}}
\newcommand*{\firstI}[1]{%
  \expandafter\formatfirst\expandafter{\@car #1\@empty\@nil}%
  \expandafter\formatrest\expandafter{\@cdr #1\@empty\@nil}%
}
\newcommand*{\firstBold}[1]{%
  \@firstBold#1 \@nil
}
\def\@firstBold#1 #2\@nil{%
  \firstI{#1}%
  \ifx\\#2\\%
  \else
    \@ReturnAfterFi{%
      \space
      \@firstBold#2\@nil
    }%
  \fi
}
\long\def\@ReturnAfterFi#1\fi{\fi#1}
more examples:

local time: Thu Apr 25 10:18:22 CEST 2024 ; file is: 1764.68609953704 days old
contact webmaster _at_ TeXnik.de