LaTeX : Mes modèles de documents

Voici un modèle de document LaTeX que j’utilise. Le code suivant appelle d’autres parties qui sont au-dessous :

%------------------------------------------------%
\documentclass[11pt]{article}
%------------------------------------------------%
% Importer les packages communs
  \input{inc/common.tex}
  \input{inc/commandes.tex
}
% Quel type de feuille?
  \input{inc/geometry1.tex}
% Titre / Auteur / Date
  \title{\huge{\textbf{Mathématiques}}}
  \author{Analyse complexe}
  \date{Mise à jour : \today
}  
% Créer l'index
  \makeindex
% Entête & pied de page
  \pagestyle{fancy}
  \headheight = 15.0pt
  \lhead{}
  \chead{}
  \rhead{\bfseries Mathématiques}
  \lfoot{Mohammed Sayed}
  \cfoot{}
  \rfoot{\thepage}
  \renewcommand{\headrulewidth}{0.4pt}
  \renewcommand{\footrulewidth}{0.4pt}

\begin{document
}
% Insérer l'entête
  \maketitle
% Contenu de votre document
%------------------------------------------------%
Salaam les amis



%------------------------------------------------%
% Afficher l'index
%  \printindex
% Sauter une page
  \newpage
% Afficher le sommaire
  \tableofcontents
% Liste des graphiques
% \listoffigures
\end{document}
%------------------------------------------------%

Voici l’ensemble des packages qui me sont utiles :

%% ------------------------------------------------ %%
%% Les packages généraux
%% ------------------------------------------------ %%
% Pour le français :: english, greek, etc.
  \usepackage[francais]{babel}
% Gestion des accents pour les PDF
  \usepackage[T1]{fontenc}
% Caractères additionnels (*)
% \usepackage{textcomp}
% Style :: txfonts, fourier, lmodern...
  \usepackage{lmodern}
%  \usepackage{kpfonts}
% \usepackage[utopia]{mathdesign}
% \usepackage[charter]{mathdesign}
%\usepackage[garamond]{mathdesign}
% Pour les mathématiques
  \usepackage{amsmath,amssymb}
% Gestion des couleurs
  \usepackage{xcolor}
% Gestion des hyperliens
  \usepackage[colorlinks=true,
          menucolor=red,
          breaklinks=true,
          urlcolor=blue,
          linkcolor=magenta
]{hyperref}
% Zoom par défaut
  \hypersetup{pdfstartview=XYZ}
% Créer un index
  \usepackage{makeidx}
% Pour les graphiques
  \usepackage{graphicx}
  \usepackage{subfigure
}
% Entête et pied de page
  \usepackage{fancyhdr}
% Style math partout
  \everymath{\displaystyle}
% Plusieurs colonnes
  \usepackage{multicol}
% Créer des frames
  \usepackage{framed}
% Inclure des codes sources
  \usepackage{listings}
% Mise en forme des théorèmes
  \usepackage{theorem}
% Passer en mode portrait
  \usepackage{lscape}
%% ------------------------------------------------ %%

Et les commandes que j’utilise :

%% ------------------------------------------------ %%
%% Mes commandes pour les raccourcis en Maths
%% ------------------------------------------------ %%
% Mettre en gras
  \newcommand{\mat}[1]{\textbf{#1}}
% Mettre en script
  \newcommand{\mcal}[1]{\mathcal{#1}}
% Indicatrice d'un ensemble
  \newcommand{\ind}[1]{\displaystyle{1\!\!1_{#1}}}
% Une probabilité
  \newcommand{\proba}{\mathbb{P}}
% Ensembles mathématiques
  \newcommand{\R}{\mathbb{R}}
  \newcommand{\N}{\mathbb{N}}
  \newcommand{\Z}{\mathbb{Z}}
  \newcommand{\Q}{\mathbb{Q}}
  \newcommand{\K}{\mathbb{K}
}
%% ------------------------------------------------ %%
%% Les théorèmes, propositions...
%% ------------------------------------------------ %%
% Les compteurs
  \newcounter{exercice}
  \newcounter{definition}
  \newcounter{theoreme}
  \newcounter{proposition}
  \newcounter{corollaire}
  \newcounter{lemme}
  \newcounter{proprietes
}
% L'environnement des definitions
  \newenvironment{definition}[1][]
     {\refstepcounter{definition
}%
     \def\FrameCommand{\colorbox{red!7}}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\textcolor{red}{
       \textbf{Définition~\thedefinition\ifx\\#1\\\else~(#1)\fi. --- }}
     \ignorespaces
    }{\endMakeFramed
}
% L'environnement des exercices & solutions
  \newenvironment{exercice}[1][]
    {\refstepcounter{exercice
}%
     \def\FrameCommand{\colorbox{blue!10}}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\textcolor{blue}{
       \textbf{Exercice~\theexercice\ifx\\#1\\\else~(#1)\fi. --- }}
     \ignorespaces
    }{\endMakeFramed}
  \newenvironment{solution}
    {\def\FrameCommand{\colorbox{green!10}
}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\textcolor{green!60!black}{
       \textbf{Solution de l'exercice~\theexercice. --- }}
     \ignorespaces
    }{\endMakeFramed
}  
% L'environnement des théorèmes  
  \newenvironment{theoreme}[1][]
    {\refstepcounter{theoreme
}%
     \def\FrameCommand{\colorbox{magenta!10}}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\textcolor{magenta}{
       \textbf{Théorème~\thetheoreme\ifx\\#1\\\else~(#1)\fi. --- }}
     \ignorespaces
    }{\endMakeFramed
}
% L'environnement des propositions  
  \newenvironment{proposition}[1][]
    {\refstepcounter{proposition
}%
     \def\FrameCommand{\colorbox{orange!10}}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\textcolor{orange}{
       \textbf{Proposition~\theproposition\ifx\\#1\\\else~(#1)\fi. ---}}
     \ignorespaces
    }{\endMakeFramed
}
% L'environnement des propriétés  
  \newenvironment{proprietes}[1][]
    {\refstepcounter{proprietes
}%
     \def\FrameCommand{\colorbox{olive!10}}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\textcolor{olive}{
       \textbf{Propriétés~\theproprietes\ifx\\#1\\\else~(#1)\fi. --- }}
     \ignorespaces
    }{\endMakeFramed
}  
% L'environnement des corollaires  
  \newenvironment{corollaire}[1][]
    {\refstepcounter{corollaire
}%
     \def\FrameCommand{\colorbox{gray!10}}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\textcolor{gray}{
       \textbf{Corollaire~\thecorollaire\ifx\\#1\\\else~(#1)\fi. --- }}
     \ignorespaces
    }{\endMakeFramed
}
% L'environnement des lemmes
  \newenvironment{lemme}[1][]
    {\refstepcounter{lemme
}%
     \def\FrameCommand{\colorbox{gray!10}}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\textcolor{gray}{
       \textbf{Lemme~\thelemme\ifx\\#1\\\else~(#1)\fi. --- }}
     \ignorespaces
    }{\endMakeFramed
}
% L'environnement tresimportant
  \newenvironment{tresimportant}
    {\fboxsep=10pt%
     \def\FrameCommand{\fcolorbox{red}{red!10}}%
     \MakeFramed {\advance\hsize-\width \FrameRestore}%
     \noindent\begingroup\color{red}\ignorespaces
    }{\endgroup\endMakeFramed}


  \newtheorem{notation}{Notation}[subsection]
  \newtheorem{vocabulaire}{Vocabulaire}[subsection]
  \newtheorem{remarque}{Remarque
}[subsection]

%% ------------------------------------------------ %%
%% Mise en forme des codes sources
%% ------------------------------------------------ %%
% Définir les couleurs
  \definecolor{colKeys}{rgb}{0,0,1}
  \definecolor{colIdentifier}{rgb}{0,0,0}
  \definecolor{colComments}{rgb}{0,0.5,1}
  \definecolor{colString}{rgb}{0.6,0.1,0.1
}
% Configuration de la mise en page
  \lstset{%configuration de listings
           float=hbp,%
      basicstyle=\ttfamily\small, %
      identifierstyle=\color{colIdentifier}, %
      keywordstyle=\color{colKeys}, %
      stringstyle=\color{colString}, %
           commentstyle=\color{colComments}, %
      columns=flexible, %
      tabsize=2, %
      frame=single, %
      frameround=tttt, %
      extendedchars=true, %
      %showspaces=false, %
      showstringspaces=false, %
      numbers=left, %
      numberstyle=\tiny, %
      breaklines=true, %
      breakautoindent=true, %
      captionpos=b,%
      %xrightmargin=0cm, %
      xleftmargin=0cm
          }
\lstset{language=c++}            
%% ------------------------------------------------ %%

Et enfin, les deux différents formats de papier que j’utilise :

% Format 1 :
%% ------------------------------------------------ %%
%% Un autre format possible
%% ------------------------------------------------ %%
% Taille du papier
\usepackage[a5paper,
      landscape,
      twocolumn,
      twoside,
      left=0cm,
      hmarginratio=2:1,
      includemp,
      marginparwidth=10pt,
      bottom=0.5cm,
      foot=0.7cm,
      includefoot,
%     textheight=11cm,
      heightrounded,
      columnsep=1cm,
      dvips,
      top=1.4cm,
      verbose]{geometry}
%% ------------------------------------------------ %%

%% ------------------------------------------------ %%
%% Un autre format possible
%% ------------------------------------------------ %%
% Taille du papier
\usepackage[left=1cm,
        right=1.5cm,
        bottom=1cm,
        top=0.4cm,
        foot=0.7cm
]{geometry}
%% ------------------------------------------------ %%



Trackback URL

Pas de commentaires pour "LaTeX : Mes modèles de documents"

Hi Stranger, leave a comment:

ALLOWED XHTML TAGS:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Subscribe to Comments