# How to use dinbrief to create a letter that fits with the window of a DIN envelope?

I am trying to use the dinbrief package to create a standard German letter for a DL envelope with a window. Supposedly, by using this class, I will get a letter conformant with DIN 5008 that should fit into the respective envelopes. Somehow, however, the address does not seem to fit well into the window:

I am using the unmodified example from page 5 in the manual. Here is a verbatim copy of that example from the manual (subject to the same licensing as the original manual):

\documentclass[12pt]{dinbrief}
\usepackage{german}
Am See 1\\
76133 Karlsruhe}
\backaddress{R. Kurz, Am See 1, 76133 Karslruhe}
\signature{R"udiger Kurz}
\place{Karlsruhe}
\begin{document}
\phone{0721}{222222}
\begin{letter}{Deutsche Bundespost\\
Fernmeldeamt Karlsruhe\\
Postfach 7300\\[\medskipamount]
{\bf 76131 Karlsruhe}}
\yourmail{01.04.93}
\sign{123456}
\subject{Betrieb eines Mikrowellensenders}
\opening{Sehr geehrte Damen und Herren,}
anbei sende ich Ihnen eine Kopie der bisherigen Genehmigung f"ur
unseren Mikrowellenherd...
... Ihre Bem"uhungen im voraus vielen Dank.
\closing{Mit freundlichen Gr"u"sen,}
\ps{Wir bitten um schnelle Erledigung.}
\cc{Deutsche Bundespost\\
Karlsruher Privatfunk \\
S"uddeutscher Rundfunk}
\encl{Abschrift der Urkunde}
\end{letter}
\end{document}


I have folded the paper at the printed fold marks.

Like this, the sender address set via \backaddress is positioned at quite a high position; in fact, it is just about visible through the window. At the same time, a noticeably tall vertical space below the sender address is left empty:

If the paper inside the envelope shifts upwards only by the small tolerance by which the envelope is taller than the folded sheet of paper, the sender address becomes even less visible:

Note that this is with the default setting for the address position, i.e. matching the addressstd option. The addresshigh option can also be used (minimally modified from above):

\documentclass[12pt,addresshigh]{dinbrief}
\usepackage{german}
Am See 1\\
76133 Karlsruhe}
\backaddress{R. Kurz, Am See 1, 76133 Karslruhe}
\signature{R"udiger Kurz}
\place{Karlsruhe}
\begin{document}
\phone{0721}{222222}
\begin{letter}{Deutsche Bundespost\\
Fernmeldeamt Karlsruhe\\
Postfach 7300\\[\medskipamount]
{\bf 76131 Karlsruhe}}
\yourmail{01.04.93}
\sign{123456}
\subject{Betrieb eines Mikrowellensenders}
\opening{Sehr geehrte Damen und Herren,}
anbei sende ich Ihnen eine Kopie der bisherigen Genehmigung f"ur
unseren Mikrowellenherd...
... Ihre Bem"uhungen im voraus vielen Dank.
\closing{Mit freundlichen Gr"u"sen,}
\ps{Wir bitten um schnelle Erledigung.}
\cc{Deutsche Bundespost\\
Karlsruher Privatfunk \\
S"uddeutscher Rundfunk}
\encl{Abschrift der Urkunde}
\end{letter}
\end{document}


Like this, things get even worse:

The sender address is partially obscured even when the paper of the letter is at the bottom of the envelope:

If the paper shifts up a bit, the sender address becomes completely invisible:

To be clear, I expect a letter in a window to look somewhat like this, this, or this. Likewise, Figure 10 on page 20 of this document by Deutsche Post (the most wide-spread German post agency) shows an example. As you will notice, none of these examples place the sender address in the window at so high a position that it almost touches the upper edge of the window.

I know I can tweak the position and size of the address field with various commands from the dinbrief class. However, it was my impression that a DIN-conformant document class exists for the very purpose to avoid making any such manual adjustments.

Therefore, my (multi-faceted) question is:

• Is the dinbrief package broken? (Improbable, and give or take 2 or 3 millimetres, measurements in the printed letters exactly matched those indicated for DIN 5008 on Wikipedia.)
• Is DIN 5008 ill-defined? (Improbable ... or is it?)
• Am I doing anything wrong? (In theory, very probable, even though I have no idea what it could be, given that I use the unchanged example from the manual.)
• This behaviour is normal, check other letters you get. – Johannes_B Oct 11 '15 at 15:38
• Best would be you add all information, also the mwe into your question. It is not nice to force helpers to visit other pages to be able to help you with your problem. Good questions are questions containing all needed informations ... – Kurt Oct 11 '15 at 15:51

I recommend using \centeraddress to vertically center the address inside the window. As long as you don't have too many lines, the problem is alleviated. To lower the return address, you can make the address field smaller using \setaddressheight{35mm}.

If you want to experiment with this: the lower edge of the window of an envelope starts 15mm above the first folding mark and the window is 45mm heigh. As you can tell, the address in my MWE is securely inside this area.

\documentclass[12pt,a4paper]{dinbrief}
\usepackage[ngerman]{babel}
\usepackage{lmodern}
\usepackage[utf8]{inputenc}

\signature{Christian Lindig}
\place{Saarbrücken}
\nowindowrules

\begin{document}
\begin{letter}{
DIN e.V.\\
Am DIN-Platz\\
Burggrafenstraße 6\\
10787 Berlin}

\subject{DIN 676 für Geschäftsbriefe}

\opening{Sehr geehrte Damen und Herren,}

die DIN Norm 676 sieht zwei Formate für Geschäftsbriefe vor: die erste
Falzmarke ist einmal 87\,mm von der Oberkante des Briefbogens entfernt und
einmal 105\,mm. Können Sie eines der beiden Formate besonders empfehlen?

\closing{Mit freundlichem Gruß}

\end{letter}
\end{document}


• Somehow, I cannot see a difference when I build your example. The sender address is at the very top of the window again, and if the letter paper slides only a tad updwards, the sender address gets partially obscured. Looking at the measurements, that is no surprise, given that the window is 45mm in height (even roughly 46mm on the envelopes I am using, so there is even more tolerance), butt he line below the sender address is placed at 55mm above the upper fold mark. With 15mm below the window on the outside, plus a bit space to account for the fact that a folded sheet cannot use the ... – O. R. Mapper Oct 11 '15 at 17:52
• ... full 15mm on the inside of the envelope, it becomes clear that the remaining space is barely enough for the sender line even if the paper happens to sit at the very bottom of the envelope. It seems like this is exactly the standardized layout, though, leading me to the (to me) surprising conclusion that this standard seems to be unexpectedly impractical. Now, it's difficult to decide what to do with this answer - thank you for reproducing the issue (+1), but your example remains absolutely the same for me with and without \centeraddress. – O. R. Mapper Oct 11 '15 at 17:52
• I agree that the position of the sender should be lower to account for the letter moving inside the envelope. This requires re-defining some dimensions. My answer is addressing the problem of the recipient address sitting too low, which is a bigger practical problem. It is solved by \centeraddress in my opinion. – Christian Lindig Oct 11 '15 at 18:00
• I have updated my answer to address the problem of the return address. I reduced the vertical size of the address field to 35mm (from 45mm), which lowers the address field. It's probably good enough to use 40mm. – Christian Lindig Oct 11 '15 at 20:20