Download the file
  1. %++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  2. % LaTeX french specific class <http://www.freesoftware.fsf.org/latexfr>
  3. %
  4. % %NAME% : Lettre à la française
  5. % %AUTHOR% : Philippe Roy
  6. % %EMAIL% : ph_roy@toutdoux.org
  7. % %VERSION% : 1.0 (20/12/2000)
  8. %
  9. % Copyright owned by AUTHOR
  10. %
  11. % This program is free software; you can redistribute it and/or modify
  12. % it under the terms of the GNU General Public License as published by
  13. % the Free Software Foundation; either version 2 of the License, or
  14. % (at your option) any later version.
  15. %
  16. % This program is distributed in the hope that it will be useful,
  17. % but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  19. % GNU General Public License for more details.
  20. %
  21. % You should have received a copy of the GNU General Public License
  22. % along with this program; if not, write to the Free Software
  23. % Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  24. %
  25. %++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  26.  
  27.  
  28. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  29. % ChangeLog
  30. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  31.  
  32. % 20/12/2001 philou : Ajout des \raggedright, merci à François Désarménien <francois@fdesar.net>
  33. % 20/12/2001 philou : Ajout des fonctions dans destinataire et signature
  34.  
  35. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  36. % Bugs
  37. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  38.  
  39. % Underfull hbox ? -> t gentil, mais mon papier s'imprime
  40.  
  41. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  42. % Bibliothèques
  43. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  44.  
  45. \NeedsTeXFormat{LaTeX2e}[1998/12/01]
  46. \ProvidesClass{lettre}[2000/06/20 v1.0 Lettre]
  47.  
  48. \LoadClass[12pt,a4paper]{article}
  49. \RequirePackage[french]{babel}
  50. \RequirePackage[T1]{fontenc}
  51. \RequirePackage[latin1]{inputenc}
  52. \RequirePackage[french]{layout}
  53. \RequirePackage{color}
  54.  
  55. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  56. % Mise en page
  57. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  58.  
  59. %\setlength{\textwidth}{19cm} %Largeur du corps
  60. %\setlength{\textheight}{27.7cm} %Hauteur du corps
  61. \setlength{\textwidth}{420pt} %Largeur du corps
  62. \setlength{\textheight}{680pt} %Hauteur du corps
  63. \setlength{\oddsidemargin}{1cm} %Marge gauche
  64. \setlength{\marginparsep}{0cm} %Séparation droite entre corps et marge de notes
  65. \setlength{\marginparwidth}{0cm} %Largeur de la marge de notes
  66.  
  67. \setlength{\topmargin}{0cm} %Marge haute
  68. \setlength{\headheight}{0cm} %Hauteur de l'entête
  69. \setlength{\headsep}{0cm} %Séparation basse entre corps et pied de page
  70. \setlength{\footskip}{0cm} %Hauteur du pied de page
  71. \setlength{\hoffset}{-30pt} %Bords gauche imprimeur
  72. \setlength{\voffset}{-30pt} %Bords haut imprimeur
  73.  
  74. \pagestyle{empty}
  75.  
  76. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  77. % En-tête
  78. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  79.  
  80. \newcommand {\CoordonneesData}{\mbox{}}
  81. \newcommand {\Coordonnees}[1]{\renewcommand{\CoordonneesData}{#1}}
  82.  
  83. \newcommand {\DestinataireData}{\mbox{}}
  84. \newcommand {\Destinataire}[1]{\renewcommand{\DestinataireData}{#1}}
  85.  
  86. \newcommand {\ReferenceData}{\mbox{}}
  87. \newcommand {\Reference}[1]{\renewcommand{\ReferenceData}{#1}}
  88.  
  89. \newcommand {\AttentionData}{\mbox{}}
  90. \newcommand {\Attention}[1]{\renewcommand{\AttentionData}{#1}}
  91. \newcommand {\AttentionFonctionData}{\mbox{}}
  92. \newcommand {\AttentionFonction}[1]{\renewcommand{\AttentionFonctionData}{#1}}
  93.  
  94. \newcommand {\OuvertureData}{\mbox{}}
  95. \newcommand {\Ouverture}[1]{\renewcommand{\OuvertureData}{#1}}
  96.  
  97. \newcommand {\DateData}{\mbox{}}
  98. \newcommand {\Date}[1]{\renewcommand{\DateData}{#1}}
  99.  
  100.  
  101. \newcommand {\FaireEntete}
  102. {
  103. \begin{tabbing}
  104. \mbox{
  105. % Coordonnées
  106. \makebox[10cm][l]{
  107. \begin{minipage}{10cm}\raggedright
  108. \CoordonneesData
  109. \end{minipage}}
  110.  
  111. % Destinataire
  112. \makebox[10cm][l]{
  113. \begin{minipage}{10cm}\raggedright
  114. ~\\~\\~\\~\\
  115. \DestinataireData\\~\\
  116. \DateData
  117. \end{minipage}}
  118.  
  119. }
  120. \end{tabbing}
  121. ~\\
  122.  
  123. % Ma très chère ...
  124. \begin{tabbing}
  125. \hspace{1cm}\= \kill
  126. \> \ReferenceData\\~\\
  127. \> \AttentionData\\
  128. \> \AttentionFonctionData\\~\\
  129. \> \OuvertureData\\~\\
  130. \end{tabbing}
  131. }
  132.  
  133. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  134. % Fermeture
  135. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  136.  
  137. \newcommand {\FermetureData}{\mbox{}}
  138. \newcommand {\Fermeture}[1]{\renewcommand{\FermetureData}{#1}}
  139.  
  140. \newcommand {\SignatureData}{\mbox{}}
  141. \newcommand {\Signature}[1]{\renewcommand{\SignatureData}{#1}}
  142. \newcommand {\SignatureFonctionData}{\mbox{}}
  143. \newcommand {\SignatureFonction}[1]{\renewcommand{\SignatureFonctionData}{#1}}
  144.  
  145. \newcommand {\FaireFermeture}
  146. {
  147. ~\\
  148. % Ma très chère ...
  149. \begin{tabbing}
  150. \hspace{1cm}\= \hspace{10cm}\= \kill
  151. \> \FermetureData\\~\\~\\~\\~\\~\\~\\
  152. \> \> \SignatureData\\
  153. \> \> \SignatureFonctionData\\
  154. \end{tabbing}
  155. }
  156.