source: anr-2010/anr.sty

Last change on this file was 263, checked in by coach, 15 years ago

IA: added altera

File size: 8.2 KB
Line 
1%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2\catcode`\@=11
3%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
4
5%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
6\newlength{\desclen}
7\newlength{\yearlen}
8\newlength{\mmlen}
9
10%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
11%{\catcode`\<=1\catcode`\>=2
12%       <\catcode`\{=12\gdef\OBraceTw<{>>
13%       <\catcode`\}=12\gdef\CBraceTw<}>>
14%>
15%\@ifundefined{specHasManual}{\let\specHasManual\relax}{}
16\let\specHasManual\relax
17\let\specCsgManual\relax
18\let\specXilinxOptimization\relax
19
20\def\setMacroInAuxFile#1{%
21    \global\expandafter\edef\csname#1\endcsname{\name}
22    \expandafter\immediate\expandafter\write\@auxout\expandafter{\expandafter\string\expandafter\gdef\expandafter\string\csname #1\endcsname{\name}}
23}
24\def\eoa{end-of-args}
25\def\@novers#1-#2\eoa{#1}
26\def\novers#1{\ifx\relax#1\def\next{{\color{red}FIXME}}\else\def\next{\expandafter\@novers#1\eoa}\fi\next}
27
28%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
29\newcount\supportercnt\supportercnt=1
30\newwrite\supporter
31\immediate\openout\supporter=anr-supporter.tex
32\def\letterOfInterest#1#2{{%
33  \let\subsection\relax%
34  \let\label\relax%
35  \let\begin\relax%
36  \let\end\relax%
37  \let\includegraphics\relax%
38  \let\linewidth\relax%
39  \let\newpage\relax%
40  \immediate\write\supporter{%
41    \subsection{#1} \label{supp:\the\supportercnt}}%
42  \immediate\write\supporter{%
43    \begin{center}\includegraphics[width=0.9\linewidth]{#2}\end{center}}%
44    \newpage%
45  }%
46  #1 (page \pageref{supp:\the\supportercnt})%
47  \advance\supportercnt1%
48}
49\def\letterOfInterestPlus#1{{%
50  \let\begin\relax%
51  \let\end\relax%
52  \let\includegraphics\relax%
53  \let\linewidth\relax%
54  \let\newpage\relax%
55  \immediate\write\supporter{%
56    \begin{center}\includegraphics[width=0.9\linewidth]{#1}\end{center}}%
57    \newpage%
58  }%
59}
60
61\def\letterOfInterestNb{?}
62\def\letterOfInterestClose{
63  \advance\supportercnt-1
64  \immediate\closeout\supporter
65  \immediate\write\@auxout{%
66    \string\gdef\string\letterOfInterestNb{\the\supportercnt}
67  }
68}
69
70
71%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
72\let\ganttlf\relax
73\newwrite\ganttdata
74\immediate\openout\ganttdata=anr.gantt
75
76\def\enable{enable}
77\def\disable{disable}
78\def\leader{leader}
79\newenvironment{taskinfo}%
80{%
81\let\ALL\disable%
82\let\IRISA\disable%
83\let\LIP\disable%
84\let\TIMA\disable%
85\let\UBS\disable%
86\let\UPMC\disable%
87\let\XILINX\disable%
88\let\BULL\disable%
89\let\THALES\disable%
90\let\NAVTEL\disable%
91\let\ZIED\disable%
92}{%
93\ifx\ALL\enable%
94  \ifx\IRISA\disable\let\IRISA\enable\fi%
95  \ifx\LIP\disable\let\LIP\enable\fi%
96  \ifx\UPMC\disable\let\UPMC\enable\fi%
97  \ifx\TIMA\disable\let\TIMA\enable\fi%
98  \ifx\UBS\disable\let\UBS\enable\fi%
99  \ifx\XILINX\disable\let\XILINX\enable\fi%
100  \ifx\BULL\disable\let\BULL\enable\fi%
101  \ifx\THALES\disable\let\THALES\enable\fi%
102  \ifx\NAVTEL\disable\let\NAVTEL\enable\fi%
103  \ifx\ZIED\disable\let\ZIED\enable\fi%
104\fi%
105\def\@leader{\begin{small}\textcolor{red}{lead.}\end{small}}
106\def\@partner{\begin{small}\textcolor{blue}{part.}\end{small}}
107\def\@IRISA{\ifx\IRISA\disable{}\else\ifx\IRISA\enable{\@partner}\else{\@leader}\fi\fi}%
108\def\@LIP{\ifx\LIP\disable{}\else\ifx\LIP\enable{\@partner}\else{\@leader}\fi\fi}%
109\def\@UPMC{\ifx\UPMC\disable{}\else\ifx\UPMC\enable{\@partner}\else{\@leader}\fi\fi}%
110\def\@TIMA{\ifx\TIMA\disable{}\else\ifx\TIMA\enable{\@partner}\else{\@leader}\fi\fi}%
111\def\@UBS{\ifx\UBS\disable{}\else\ifx\UBS\enable{\@partner}\else{\@leader}\fi\fi}%
112\def\@XILINX{\ifx\XILINX\disable{}\else\ifx\XILINX\enable{\@partner}\else{\@leader}\fi\fi}%
113\def\@BULL{\ifx\BULL\disable{}\else\ifx\BULL\enable{\@partner}\else{\@leader}\fi\fi}%
114\def\@THALES{\ifx\THALES\disable{}\else\ifx\THALES\enable{\@partner}\else{\@leader}\fi\fi}%
115\def\@NAVTEL{\ifx\NAVTEL\disable{}\else\ifx\NAVTEL\enable{\@partner}\else{\@leader}\fi\fi}%
116\def\@ZIED{\ifx\ZIED\disable{}\else\ifx\ZIED\enable{\@partner}\else{\@leader}\fi\fi}%
117\begin{tabular}{|c|c|c|c|c|c|c|c|c|c|}\hline
118\Sirisa  & \Slip  & \Stima  & \Subs  & \Supmc  & \Sxilinx & \Sbull  & \Sthales & \Snavtel & \Szied \\\hline
119\@IRISA  & \@LIP  & \@TIMA  & \@UBS  & \@UPMC  & \@XILINX & \@BULL  & \@THALES & \@NAVTEL & \@ZIED \\\hline
120\end{tabular}\par
121}
122
123%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
124\newenvironment{objectif}%
125{\begin{description}\item[Objectives]}
126{\end{description}}
127
128%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
129\newcount\taskcnt\taskcnt=0
130\newcount\subtaskcnt
131\newcount\livrablecnt
132\newenvironment{workpackage}%
133{\global\advance\taskcnt1
134 \global\subtaskcnt0
135 \def\taskname{T\the\taskcnt}%
136 \begin{description}%
137 %\let\itemsave\item%
138 \def\subtask{%
139    \global\advance\subtaskcnt1
140    \def\subtaskname{S\taskname-\the\subtaskcnt}%
141    \item[\subtaskname]}}
142{\end{description}}
143
144%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
145\def\writeganttinfo#1#2#3#4#5#6{{%
146    \let\xcoach\relax
147    \let\xcoachplus\relax
148    \let\irisa\relax    \let\Sirisa\relax
149    \let\lip\relax      \let\Slip\relax
150    \let\tima\relax     \let\Stima\relax
151    \let\ubs\relax      \let\Subs\relax
152    \let\upmc\relax     \let\Supmc\relax
153    \let\altera\relax   \let\Saltera\relax
154    \let\xilinx\relax   \let\Sxilinx\relax
155    \let\bull\relax     \let\Sbull\relax
156    \let\thales\relax   \let\Sthales\relax
157    \let\zied\relax     \let\Szied\relax
158    \let\navtel\relax   \let\Snavtel\relax
159    \immediate\write\ganttdata{%
160      T=\the\taskcnt\space S=\the\subtaskcnt\space%
161      D=\the\livrablecnt\space V=\vers\space%
162      BM=#1 EM=#2 R=#3 PART={#4} KIND={#5} TITLE=#6%
163    }
164}}
165\newenvironment{livrable}%
166{%
167 \newcount\verscnt\verscnt=-1
168 \newif\ifIsLivrableStarted\IsLivrableStartedfalse
169 \newif\ifLivrableTopLine\LivrableTopLinetrue
170 \def\livrableTableDef{\begin{tabular}{|c|c|c|c|p{.625\linewidth}|}\hline}
171 \def\livrableTableLine##1##2##3##4{%
172    \makebox[3.5em]{\begin{small}##1\end{small}} &
173    \makebox[2.2em]{\begin{small}##2\end{small}} &
174    \makebox[1.5em]{\begin{small}##3\end{small}} &
175    \makebox[2.2em]{\begin{small}##4\end{small}} &
176 }
177 \def\livrableTableTopLine{%
178   \livrableTableLine{number}{date}{type}{resp.} description
179 }
180 \livrablecnt-1
181 \ifvmode \else\par\fi
182   
183 \def\itemV##1##2##3##4##5{%
184    \ifIsLivrableStarted
185        \global\advance\verscnt1
186    \else
187        \global\advance\livrablecnt1
188        \global\verscnt1
189    \fi
190    \def\vers{V\the\verscnt}
191    \global\edef\name{D\the\taskcnt\the\subtaskcnt\the\livrablecnt-\vers}%
192    \writeganttinfo{##1}{##2}{none}{##4}{##3}{##5}
193    \\\hline
194    \ifLivrableTopLine
195      \ifIsLivrableStarted\else\hline\hline\fi
196    \else
197      \ifIsLivrableStarted\else\end{tabular}\\\livrableTableDef\fi
198    \fi
199    \global\LivrableTopLinefalse
200    \global\IsLivrableStartedtrue
201    %\global\LivrableStartfalse
202    \livrableTableLine%
203        {\textsc{\name}}%
204        {\textsc{T0+##2}}%
205        {\textsc{##3}}%
206        {\textsc{##4}}%
207 }
208 \def\itemL##1##2##3##4##5##6{%
209    \ifIsLivrableStarted
210        %\global\advance\verscnt1
211    \else
212        \global\advance\livrablecnt1
213        %\global\verscnt1
214    \fi
215    \def\vers{VF}
216    \global\edef\name{D\the\taskcnt\the\subtaskcnt\the\livrablecnt-\vers}%
217    \writeganttinfo{##1}{##2}{##6}{##4}{##3}{##5}
218    \\\hline
219    \ifLivrableTopLine
220      \ifIsLivrableStarted\else\hline\hline\fi
221    \else
222      \ifIsLivrableStarted\else\end{tabular}\\\livrableTableDef\fi
223    \fi
224    \global\LivrableTopLinefalse
225    \global\IsLivrableStartedfalse
226    %\global\LivrableStartfalse
227    \livrableTableLine%
228        {\textsc{\name}}%
229        {\textsc{T0+##2}}%
230        {\textsc{##3}}%
231        {\textsc{##4}}%
232 }
233 \def\CoutHorsD##1##2##3##4##5{%
234    \let\xcoach\relax
235    \let\xcoachplus\relax
236    \let\irisa\relax    \let\Sirisa\relax
237    \let\lip\relax      \let\Slip\relax
238    \let\tima\relax     \let\Stima\relax
239    \let\ubs\relax      \let\Subs\relax
240    \let\upmc\relax     \let\Supmc\relax
241    \let\altera\relax   \let\Saltera\relax
242    \let\xilinx\relax   \let\Sxilinx\relax
243    \let\bull\relax     \let\Sbull\relax
244    \let\thales\relax   \let\Sthales\relax
245    \let\zied\relax     \let\Szied\relax
246    \let\navtel\relax   \let\Snavtel\relax
247    \immediate\write\ganttdata{%
248      T=\the\taskcnt\space S=\the\subtaskcnt\space%
249      D=none BM=##1 EM=##2 R=##5 PART={##3} TITLE=##4%
250    }
251 }
252% \begin{small}
253 \livrableTableDef
254 \livrableTableTopLine
255 %\begin{tabular}{|c|c|c|c|p{.55\linewidth}|}\hline%
256 %\makebox[3.5em]{number} & \makebox[1.5em]{date} & type & resp. & description
257}
258{\\\hline\end{tabular}\\%
259%\end{small}\\%
260}
261
262%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
263\catcode`\@=12
264%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Note: See TracBrowser for help on using the repository browser.