summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/famt/ProjectReport/ProjectReport.cls
blob: c08573601f346076a002b760246f02abab4c6616 (plain)
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
 \NeedsTeXFormat{LaTeX2e}
 \ProvidesClass{ProjectReport}[2012/02/24 FAMT Project Report]

% Allow the inclusion of graphics
\ifx\pdfoutput\undefined
% we are running LaTeX, not pdflatex
\usepackage{graphicx}
\else
% we are running pdflatex, so convert .eps files to .pdf
\usepackage[pdftex]{graphicx}
\usepackage{epstopdf}
\fi
   
% Declare some variables to hold the text fields 

    \newcommand{\Title}[1]{\gdef\FAMTField@Title{#1}}
    \newcommand{\Protitle}[1]{\gdef\FAMTField@Protitle{#1}}
    \newcommand{\deptname}[1]{\gdef\FAMTField@deptname{#1}}
    \newcommand{\dept}[1]{\gdef\FAMTField@dept{#1}}
    \newcommand{\degree}[1]{\gdef\FAMTField@degree{#1}}
    \newcommand{\university}[1]{\gdef\FAMTField@university{#1}}
    \newcommand{\MemberA}[1]{\gdef\FAMTField@MemberA{#1}}
    \newcommand{\MemberB}[1]{\gdef\FAMTField@MemberB{#1}}
    \newcommand{\MemberC}[1]{\gdef\FAMTField@MemberC{#1}}
    \newcommand{\MemberD}[1]{\gdef\FAMTField@MemberD{#1}}
    \newcommand{\RegA}[1]{\gdef\FAMTField@RegA{#1}}
    \newcommand{\RegB}[1]{\gdef\FAMTField@RegB{#1}}
    \newcommand{\RegC}[1]{\gdef\FAMTField@RegC{#1}}
    \newcommand{\RegD}[1]{\gdef\FAMTField@RegD{#1}}
    \newcommand{\Year}[1]{\gdef\FAMTField@Year{#1}}
    \newcommand{\Month}[1]{\gdef\FAMTField@Month{#1}}
    \newcommand{\Guidename}[1]{\gdef\FAMTField@Guidename{#1}}   
    \newcommand{\Collegename}[1]{\gdef\FAMTField@Collegename{#1}}
    \newcommand{\Certificate}[1]{\gdef\FAMTField@Certificate{#1}}

% Code for printing month
     \usepackage{ifthen}
     \newcommand{\monthnum}[1]%
{%
\ifthenelse{\equal{#1}{1}}{\Month{January}}{}%
\ifthenelse{\equal{#1}{2}}{\Month{February}}{}%
\ifthenelse{\equal{#1}{3}}{\Month{March}}{}%
\ifthenelse{\equal{#1}{4}}{\Month{April}}{}%
\ifthenelse{\equal{#1}{5}}{\Month{May}}{}%
\ifthenelse{\equal{#1}{6}}{\Month{June}}{}%
\ifthenelse{\equal{#1}{7}}{\Month{July}}{}%
\ifthenelse{\equal{#1}{8}}{\Month{August}}{}%
\ifthenelse{\equal{#1}{9}}{\Month{September}}{}%
\ifthenelse{\equal{#1}{10}}{\Month{October}}{}%
\ifthenelse{\equal{#1}{11}}{\Month{November}}{}%
\ifthenelse{\equal{#1}{12}}{\Month{December}}{}%
}

% Initialize the variables to their default values

    \Title{A project report on}
    \Protitle{}
    \deptname{Information Technology}
    \dept{Department of Information Technology}
    \degree{Bachelor of Engineering}
    \MemberA{} \MemberB{} \MemberC{} \MemberD{}
    \RegA{} \RegB{} \RegC{} \RegD{}
    \Year{\number \year}
    \Guidename{}
    \Collegename{Finolex Academy of Management and Technology, Ratnagiri}
    \Certificate{CERTIFICATE}
    \university{Mumbai}
   \monthnum{4}

% Define the preliminary page layouts using the variables

% Defining title page
    \newcommand{\FAMTtitlepage}{
        \thispagestyle{empty}
        {  
        \centering
        \providecommand\pdfbookmark[3][]{} \pdfbookmark[0]{Title Page}{bm:Title}
      \parbox[t]{6in}{\centering \Large\FAMTField@Title} \\[\baselineskip]       
      \LARGE{\textbf{\FAMTField@Protitle}} \\[\baselineskip] \normalsize
      \Large
      \vspace{0.2cm}
      \textit{submitted in partial fulfillment of the \\ requirements for the degree of}\\[\baselineskip]
      \vspace{0.2cm}
      \textbf{\FAMTField@degree} \linebreak
      \textit{in} \linebreak
      \textbf{ \FAMTField@deptname} \\[\baselineskip]
      \textit{by} \\[\baselineskip]
\begin{table}[h]
\centering
\begin{tabular}{lr}
\textbf{\Large{\FAMTField@MemberA}} & \textbf{\Large{\FAMTField@RegA}} \tabularnewline
\textbf{\Large{\FAMTField@MemberB}} & \textbf{\Large{\FAMTField@RegB}} \tabularnewline
\textbf{\Large{\FAMTField@MemberC}} & \textbf{\Large{\FAMTField@RegC}} \tabularnewline
\textbf{\Large{\FAMTField@MemberD}} & \textbf{\Large{\FAMTField@RegD}} \tabularnewline 
\end{tabular}
\end{table}
       \textit{under the guidance of} \linebreak
        \textbf{\textup{\FAMTField@Guidename}} \\[\baselineskip]
        \vspace{0.2cm}
        \includegraphics[width=0.25 \textwidth]{logo}\\[\baselineskip]
        \vspace{0.2cm}
        \FAMTField@dept \linebreak
        \FAMTField@Collegename \linebreak
        \mbox{\FAMTField@Month \hspace{0.1cm} \FAMTField@Year} \\[\baselineskip]
        }
        \clearemptydoublepage
      }

% Defining certificate page

      \newcommand{\FAMTcertificatepage}{
        \thispagestyle{empty}
        {\centering
        \providecommand\pdfbookmark[3][]{} \pdfbookmark[0]{CertificatePage}{bm:Certificate}
        \parbox[t]{6in}{\centering \Large{\underline{\FAMTField@Certificate}}\par}\\[\baselineskip] 
      \normalsize \large
      The report titled \linebreak
      \LARGE{\textbf{\FAMTField@Protitle}} \\[\baselineskip] \normalsize \large
      \textit{duly completed by}\\[\baselineskip]      
\begin{table}[h]
 \centering
 \begin{tabular}{lr}
\textbf{\Large{\FAMTField@MemberA}} & \textbf{\Large{\FAMTField@RegA}} \\
\textbf{\Large{\FAMTField@MemberB}} & \textbf{\Large{\FAMTField@RegB}} \\
\textbf{\Large{\FAMTField@MemberC}} & \textbf{\Large{\FAMTField@RegC}} \\
\textbf{\Large{\FAMTField@MemberD}} & \textbf{\Large{\FAMTField@RegD}} \\
 \end{tabular}
 \end{table}
       \textit{as a partial fulfillment of the \\ requirements for the degree of}\\[\baselineskip]
       \textbf{\FAMTField@degree} \linebreak
       \textit{in} \linebreak
       \textbf{\FAMTField@deptname} \\[\baselineskip]
       \textit{from} \linebreak  
       \textbf{The University of \FAMTField@university}
\vfill
\begin{table}[h]
\centering
\begin{tabular}{ccc}
\tabularnewline \tabularnewline \tabularnewline
\large{\FAMTField@Guidename} \\ \large{(Project Guide)} & \hspace*{1cm}  \large{(Internal Examiner)} \hspace*{1cm} & \large{(External Examiner)} 
\tabularnewline \tabularnewline \tabularnewline \tabularnewline \tabularnewline
\large{(H.O.D.)} &  & \large{(Principal)} 
\tabularnewline
 \end{tabular}
 \end{table}
\begin{flushleft}
Date: \linebreak
Place: \FAMTField@dept, \\
\hspace{1.2cm} \FAMTField@Collegename
\end{flushleft} 
       }
       \clearemptydoublepage
      }
        
% Define the macro for making preliminary pages

     \newcommand{\makepreliminarypages}{
        \singlespace
        \changepage{0.8in}{}{}{}{}{}{-0.2in}{-0.3in}{}
        \FAMTtitlepage
        \FAMTcertificatepage
        \renewcommand{\clearemptydoublepage}{\cle@remptydoublep@ge}   
        \changepage{-0.5in}{}{}{}{}{}{0.2in}{0.3in}{}
        \doublespace
    }

    \usepackage{xifthen} % Default Argument is Empty
    % \newcommand{\optarg}[1]{\ifthenelse{\isempty{#1}}{}{#1}}
    
    % College name is other than Finolex Academy of Management and Technology
    \newcommand{\College}[1]{\ifthenelse{\isempty{#1}}{}{\Collegename{#1}}}
    
    % Department name is other than Information Technology
    \newcommand{\Department}[1]{\ifthenelse{\isempty{#1}}{}{\deptname{#1} \dept{#1}}}

    % Degree name is other than Bachelor of Engineering
    \newcommand{\Degree}[1]{\ifthenelse{\isempty{#1}}{}{\degree{#1}}}

    % University name is other than University of Mumbai
    \newcommand{\University}[1]{\ifthenelse{\isempty{#1}}{}{\university{#1}}}


% A command to handle single sided preliminary pages in a double sided environment

% Define the '\clearemptydoublepage' command to clear pages but not number any blank pages inserted.
    \let\cle@rdoublep@ge\cleardoublepage
    \newcommand{\cle@remptydoublep@ge}{
      \clearpage
      \if@twoside
      \ifodd\c@page\else
      \fi\fi
      {\pagestyle{empty}\cle@rdoublep@ge}}
    \newcommand{\clearemptydoublepage}{\cle@remptydoublep@ge}

% Load the class and needed packages
    \DeclareOption*{\PassOptionsToClass{\CurrentOption}{book}}
    \ProcessOptions
    \relax
    \LoadClass[a4paper,12pt,oneside]{book}
    \RequirePackage{changepage}

% A couple of useful macros for line spacing

% The \singlespace macro switches to single spaced lines
\newcommand{\singlespace}{\par\renewcommand{\baselinestretch}{1}\small\normalsize\par}

% The \doublespace macro switches to double spaced lines
\newcommand{\doublespace}{\par\renewcommand{\baselinestretch}{1.66}\small\normalsize\par}

% This package allows you to specify the 4 margins without needing to remember the particular page dimensions commands
\usepackage[top=1.4in, bottom=1.1in, left=1.3in, right=1.1in]{geometry}

% Redefine the Table of Contents to deal with some blank page
% and bookmarking issues relating to ETD submission
    \let\TEMPtableofcontents\tableofcontents
    \renewcommand{\tableofcontents}{
      \clearemptydoublepage
      \singlespace
      \providecommand\phantomsection{} \phantomsection
      \addcontentsline{toc}{chapter}{Table of Contents}
      \TEMPtableofcontents
      \clearemptydoublepage
      \doublespace
    }

% Redefine the List of Figures to deal with some blank page
% and bookmarking issues
    \let\TEMPlistoffigures\listoffigures
    \renewcommand{\listoffigures}{
      \providecommand\phantomsection{} \phantomsection
      \addcontentsline{toc}{chapter}{List of Figures}
      \TEMPlistoffigures
    }

% Redefine the Bibliography to deal with a bookmarking issues
    \let\TEMPbibliography\bibliography
    \renewcommand{\bibliography}{\clearemptydoublepage
      \providecommand\phantomsection{} \phantomsection
      \addcontentsline{toc}{chapter}{Bibliography}
      \TEMPbibliography
    }

% These packages typeset the thesis with Times Roman font
\usepackage[T1]{fontenc}
\usepackage{mathptmx}

% The fancyhdr package allows to easily customize page header.
% The settings below produce a nice, well separated header.
\usepackage{fancyhdr}
  \fancyhead{}
  \fancyhead[RO,RE]{\slshape \rightmark}
  \fancyfoot{}
  \fancyfoot[CO,CE]{\thepage}
  \pagestyle{fancy}
  \renewcommand{\chaptermark}[1]{\markboth{\chaptername \ \thechapter \ \ #1}{}}
  \renewcommand{\sectionmark}[1]{\markright{\thesection \ \ #1}}

% The caption package allows you to change the formatting of figure captions.
% The commands here change to the suggested caption format:
% single spaced and a bold tag
\usepackage[margin=0.3in,labelfont=bf,labelsep=none]{caption}
 \DeclareCaptionFormat{suggested}{\singlespace#1#2 #3\par\doublespace}
 \captionsetup{format=suggested}

% The hyperref package provides automatic linking and
% bookmarking for the table of contents, index, equation
% references, and figure references.  It must be included for
% the FAMT class to make a properly functioning
% electronic thesis.  It should be the last package loaded if
% possible.
%
% To add a bookmark in the pdf you can use \pdfbookmark.  
% You can look up its usage in hyperref package documentation
\usepackage[bookmarksnumbered,pdfpagelabels=true,plainpages=false,colorlinks=true,linkcolor=black,citecolor=black,urlcolor=blue]{hyperref}
\urlstyle{rm}
\doublespace