I have a g-brief document which includes an xwatermark in it. By the below error it appears as though xwatermark doesn't like semicolons in the watermarks description:

TeX console error (I can't seem to copy from the console in MacTeX?!)

The relevant part seems to be Enclode your toke ';' in braces:

   % \clip (-2,-5) rectangle (10,5);
    \foreach \x in {0,0.05,...,2}{
      \draw (0,\x) .. controls (4-\x,-4-3*\x) and (11-2*\x,4-3*\x) .. (12,-5+3*\x);
      \draw (0,\x-1) .. controls (4-\x,\x-2) and (11-2*\x,-4-3*\x) .. (12,-3+3*\x);
      \draw (0,\x-3) .. controls (4-\x,\x-2) and (11-4*\x,-1-4*\x) .. (12,-5+3.5*\x);

Yet, putting the semicolons in braces doesn't seem to work. Any idea how to safely integrate a tikz drawing in an xwatermark?

Edit1: As Ulrike of course was totally right here's a complete, crowded example of my standard g-brief with lots of over-the-years acquired hacks in which I hope I haven't left in anything embarrasing.

% !TEX encoding = UTF-8 Unicode
\usepackage[arrow, matrix, curve]{xy}
\usepackage[output-decimal-marker={,},group-separator = {.},group-four-digits]{siunitx}

    {\fontsize{4cm}{4cm}\selectfont{  }}}}}

    {\fontsize{1cm}{1cm}\selectfont{  }}}}}

    \makebox[\wd0][c]{%  hor. centering
    \raisebox{.5\ht0}{%  approx. vert. centering
    \csname Gin@isotrue\endcsname% = "keepaspectratio"
    \resizebox*{.8\ht0}{.8\ht0}{% Scale down (the height is also used for the width to avoid the surrounding spaces)
    \parbox{10em}{% Allow line breaks
            c me 2018



    \advance\julianday by 1\relax
      % It's a weekday (Mon-Fri)
      {% It's a holiday
      {% Not a holiday
        \advance\daycount by -1\relax
  \ifnum\daycount > 0

   % \clip (-2,-5) rectangle (10,5);
    \foreach \x in {0,0.05,...,2}{
      \draw (0,\x) .. controls (4-\x,-4-3*\x) and (11-2*\x,4-3*\x) .. (12,-5+3*\x);
      \draw (0,\x-1) .. controls (4-\x,\x-2) and (11-2*\x,-4-3*\x) .. (12,-3+3*\x);
      \draw (0,\x-3) .. controls (4-\x,\x-2) and (11-4*\x,-1-4*\x) .. (12,-5+3.5*\x);

\holiday{2015-04-21}{Oster Montag}
\holiday{2015-10-03}{Tag der deutschen Einheit}

\renewcommand{\blztext}{\footnotesize BIC}
\renewcommand{\kontotext}{\footnotesize IBAN}


\Name                {me}
\Strasse             {here 1}
\Zusatz              {}
\RetourAdresse       {}
\Ort                 {12345 city}
\Land                {}

\Telefon             {5551212}
%\Telefax             {5551313}
%\EMail               {me@example.com}

%\Bank                {Bank}
%\BLZ                 {ABCD}
%\Konto               {DE12 3456 7890}

\Unterschrift        {My T\watermark. name}

\Postvermerk         {persönlich/vertraulich}
\Adresse             {abc\\def\\xxx\\12345 abc}

\Betreff             {abc }

\Datum               {\today}
\IhrZeichen          {} 
\IhrSchreiben        {}
%\MeinZeichen         {}

\Anrede              {Sehr geehrte Damen und Herren,}
\Gruss               {Mit freundlichem Gruss,}{1cm}

%\Anlagen             {\emph{Anlagen:\\ xxx }}

%\Verteiler           {\it Verteiler:\\ xxx}
%\klassisch %-> altes Kopfzeilenformat, Betr.: vor Betreff und Unterschrift kursiv und in Klammern
%\unserzeichen %-> "Unser Zeichen" statt "Mein Zeichen"




  • 1
    I wouldn't use xwatermark but beside this: always make a complete example. That makes it much easier to test your issue. – Ulrike Fischer May 31 '18 at 9:41
  • @UlrikeFischer Of course, sorry for leaving it out. I have added a compete example above. Thanks for the heads up... – Christian May 31 '18 at 9:54
  • 1
    Make the example smaller. It contains lots of irrelevant stuff. And as you are using eso-pic anyway: use it also for the watermark. Much less troublesome than xwatermark. – Ulrike Fischer May 31 '18 at 10:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.