1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54
| % !TEX encoding = UTF-8 Unicode
% !TEX TS-program = pdfLaTeX
\documentclass[12pt, french, a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{geometry}
\usepackage{tikz}% indispensable pour faire des dessins
\usepackage{babel}
\begin{document}
\begin{figure}
\centering
\begin{tikzpicture}
% les styles
\tikzset{%
fleche/.style={->, >=latex, thick},%
cadre/.style={draw=black, fill=yellow!50!white, text centered, text width=3cm, rounded corners=8pt}%
}
% première ligne
\node[cadre] (A) at (0,0) {Titre};
% seconde ligne
\node[cadre] (B) at (-4.5,-1.5) {B};
\node[cadre] (C) at (0,-1.5) {C};
\node[cadre] (D) at (4.5,-1.5) {D};
% troisieme ligne
\node[cadre] (E) at (-4.5,-3) {E};
\node[cadre] (F) at (0,-3) {F};
\node[cadre] (G) at (4.5,-3) {G};
% dernière ligne
\node[cadre] (H) at (-4.5,-4.5) {H};
\node[cadre] (I) at (0,-4.5) {I};
\node[cadre] (J) at (4.5,-4.5) {J};
% les fleches
\draw[fleche] (C) -- (D);
\draw[fleche] (C.270) -- (E);
\draw[fleche] (C.270) -- (F);
\draw[fleche] (C.270) -- (G);
\draw[fleche] (E) -- (F);
\draw[fleche] (F.270) -- (I);
\draw[fleche] (F.270) -- (J);
\end{tikzpicture}
\caption{Une figure avec Tikz}
\end{figure}
\end{document} |
Partager