%%%==============================================================================
%% Copyright 2022-23 by Alceu Frigeri
%%
%% This work may be distributed and/or modified under the conditions of
%%
%% * The [LaTeX Project Public License](http://www.latex-project.org/lppl.txt),
%%   version 1.3c (or later), and/or
%% * The [GNU Affero General Public License](https://www.gnu.org/licenses/agpl-3.0.html),
%%   version 3 (or later)
%%
%% This work has the LPPL maintenance status *maintained*.
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
%% This is version 1.12 (2023/09/23)
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
%%
%%%==============================================================================
%% UFRGS stands for "Federal University of Rio Grande do Sul" in south Brazil
%% EE    stands for "Engineering School"
%% CCA   stands for "Control and Automation Engineering Course" (Portuguese acronym)
%%%==============================================================================

%
\NewDocumentCommand{\tcforms@examinersTRforms}{}{%
  \tccore@examiners{examinerB}%
  \tcforms@reviewTRform{examinerB}%
  \tccore@examiners{examinerC}%
  \tcforms@reviewTRform{examinerC}%
}%
%



%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
% TCC examiner form (grades)%
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NewDocumentCommand{\tcforms@examinersTRform}{m}{%
  \tc@formtopbox[tcdef@forms@formsfootnote]{\tcdef@forms@formstitleTR}{\tcdef@forms@examformtitle}%
%
  \vfill%
  \tcdef@forms@formsstudentlabel : {\bf \csname tc@student\Alph{tc@studentcount}\endcsname}\\%
  \tcdef@forms@formsexaminerlabel :  \csname tc@student\Alph{tc@studentcount}@#1\endcsname%
  \vfill%
  \tcdef@forms@examformdesc%

  \vfill%

  \begin{center}
    \begin{tabular}{|c|c|c|}%
      \hline%
      \tc@TCCpointAlabel & \tc@TCCpointBlabel & \tc@TCCpointClabel \\\hline%
      & & \\\hline
    \end{tabular}%
  \end{center}%

  \vfill%

  \tcforms@formsigdate{\tcdef@forms@examinersignature}%
  \vfill%
  \begin{description}
    \item[\tcdef@forms@examformnoteslabel:] \tcdef@forms@examformnotes
  \end{description}%

  \vfill%
  \pagebreak%
}%
%

%\def\emptybox{\framebox[3em]{\color{white}W}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
% TCC I reviewer form (corrections)%
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NewDocumentCommand{\tcforms@reviewTRform}{m}{%
  \tc@formtopbox[tcdef@forms@TRformfootnote]{\tcdef@forms@formstitleTR}{\tcdef@forms@formsTRtitle}%

  \vfill%
  \tcdef@forms@formsstudentlabel : {\bf \expandafter\csname tc@student\Alph{tc@studentcount}\endcsname}\\[-4mm]%
  
  \tcdef@forms@formsworktitlelabel : {\bf \@title}\\%
  
  \tcdef@forms@formsexaminerlabel : \expandafter\csname tc@student\Alph{tc@studentcount}@#1\endcsname\\[-4mm]%
  
  {\scriptsize {\textsl{(favor retornar este diretamente à coordenação de TCC.)}}}
  \vfill%
%  \resizebox{0.9\textwidth}{!}{%%
   O trabalho submetido\footnotemark[2]:

     \begin{enumerate}[tcc,nosep]
     \item \emptybox\  \textbf{Enquadramento do Tema}. {\footnotesize(peso:2)}\\ {\footnotesize Quão bem o mesmo se enquadra no perfil de um formando em Eng. de Controle e Automação.}
     \item \emptybox\ \textbf{Revisão Bibliográfica}. {\footnotesize(peso:2)}\\ {\footnotesize A revisão apresentada é adequada, suficiente, para o tema do trabalho?}
     \item \emptybox\ \textbf{Abordagem/Plano de Trabalho Proposto}. {\footnotesize(peso:2)}\\ {\footnotesize Considerar se a abordagem, plano de trabalho proposto, é adequada e factivel.}
     \item \emptybox\ \textbf{Redação}. {\footnotesize(peso:1)}\\ {\footnotesize     Considerar a qualidade do trabalho escrito apresentado.}
     \item { O Trabalho Submetido}
     \begin{itemize}[tcc,nosep]
       \item[$\Box$] Está adequado, dispensando correções do texto.
       \item[$\Box$] Está adequado, sendo necessário correções, conforme anotações anexas.
       \item[$\Box$] Necessita ser revisto/re-escrito,\footnotemark[3] e: 
       \begin{itemize}
         \item[$\Box$] basta a revisão final do texto pelo orientador,
         \item[$\Box$] revisarei o trabalho depois de corrigido.
       \end{itemize}
     \end{itemize} 
   \end{enumerate}
   
Outras considerações, parecer (se necessário): \\

	\begin{tabular}{p{0.9\textwidth}}
	~\\\hline
	~\\\hline
	~\\\hline
	~\\\hline
  ~\\\hline
	~\\\hline
	\end{tabular}\\[-1mm]
 % }%
  \footnotetext[2]{Use a escala 0-10: \begin{enumerate*}\item[0.] Péssimo  \item[3.] Deficitário \item[6.] Bom \item[8.] Muito Bom \item[10.] Excelente \end{enumerate*}}
  \footnotetext[3]{\tcdef@forms@reviewformfootnoteB}%
  \vfill%

  \tcforms@formsigdate{\tcdef@forms@examinersignature}%
  \vfill%
  \pagebreak%
}%
%
% TODO: THIS ONE, as the reference for 'work submission a board approaval'
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
% TCC Board approval form%
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
% TCC Advisor approval form%
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NewDocumentCommand{\tcforms@advisorTRapprovalform}{}{%
  \tc@formtopbox{\tcdef@forms@formstitleTR}{Formulário de Aprovação para Avaliação}%

  \vfill%

  \tcforms@tccdesc%

  \vfill%
  \tcdef@forms@advisorapprovalformdesc%

  \vfill%

  \tcdef@core@tccadvisorsreview%

  \vfill%
  %Aprovo a versão final do trabalho submetido pel\tccore@@ref{student}{article} alun\tccore@@ref{student}{article} e 
  %considero \tccore@@ref{student}{article} mesm\tccore@@ref{student}{article} apt\tccore@@ref{student}{article} para avaliação pela Banca Examinadora.%

  \tcforms@formsigdate{\tcdef@forms@advisorsignature}%
  \vfill%

  \tcforms@formsigdate{\tcdef@forms@studentsignature}%
  \vfill%
  \pagebreak%
}%
%
\NewDocumentCommand{\tcforms@advisorTRboardform}{}{%
  \tc@formtopbox{\tcdef@forms@formstitleTR}{Formulário de Aprovação de Banca Examinadora}%

  \vfill%

  \tcforms@tccdesc%

  \vfill%
  \begin{center}
    \tcdef@forms@formsboardtitle
  \end{center}%

  \tcforms@examinerdesc{studentA}{examinerB}%

  \tcforms@examinerdesc{studentA}{examinerC}%


  \vfill%

  Aprovo a Banca Examinadora acima relacionada.%
  \vfill%

  \tcforms@formsigdate{\tcdef@forms@advisorsignature}%
  \vfill%

  \pagebreak%
}%
%



%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
% TCC requirement form (TCC register)%
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NewDocumentCommand{\tcforms@reqTRform}{}{%
  \tc@formtopbox{\tcdef@forms@formstitleTR}{\tcdef@forms@reqformtitle}%

  \vfill%

  \tcdef@forms@reqformopening%
  \vfill%

  \tcdef@forms@reqformdescTR%
  \vfill%

  \tcdef@forms@formstemptitlelabel : \@title %

  \tcdef@forms@formsstudentemaillabel : {\bf \tc@studentAemail} %

  \tcdef@forms@formsadvisorlabel : \tc@studentA@advisor%

  \tcdef@forms@formsadvisoremaillabel : {\bf \tc@studentA@advisoremail}%
  \hfill \tcdef@forms@formsphonelabel : {\bf \tc@studentA@advisorphone}%
  

  {\bf \tcdef@forms@formsbrieflabel}:\footnote[1]{\tcdef@forms@renewreqformnotes}%

  \vfill%
  \tcdef@core@tccbrief%

  \parbox[t]{.45\textwidth}{\tcforms@formsigdate{\tcdef@forms@studentsignature}}\hfill%
  \parbox[t]{.45\textwidth}{\tcforms@formsigdate{\tcdef@forms@advisorsignature}}%
  \pagebreak%
}%
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
% TCC co-advisor requirement form (TCC register)%
%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NewDocumentCommand{\tcforms@coadvisorTRform}{}{%
  \@ifundefined{tc@studentA@coadvisor}{%
    \coadvisor{\rule{\tc@namerule}{.1pt}}{}%
    \coadvisorinfo{}{\rule{\tc@titlerule}{.1pt}}{\rule{\tc@emailrule}{.1pt}}{\rule{\tc@phonerule}{.1pt}}%
    }{}%
  \tc@formtopbox{\tcdef@forms@formstitleTR}{\tcdef@forms@coadvisorformtitle}%

  \vfill%

  \tcdef@forms@reqformopening%
  \vfill%

  \tcdef@forms@coadvisorformdesc%
  \vfill%

  \tcdef@forms@formstemptitlelabel : \@title %

  \tcdef@forms@formsadvisorlabel: \tc@studentA@advisor

  \tcdef@forms@formscoadvisorlabel: \tc@studentA@coadvisor%

  \tcdef@forms@formscoadvisoremaillabel : {\bf \tc@studentA@coadvisoremail}%
  \hfill \tcdef@forms@formsphonelabel : {\bf \tc@studentA@coadvisorphone}%


  \vfill%
  {\bf \tcdef@forms@formsreasonlabel}:%

  \tcdef@core@tcccoadvisorbrief%    !!!! What a Hell ?!?!?!

  \tcforms@formsigdate{\tcdef@forms@studentsignature}%

  \parbox[t]{.45\textwidth}{\tcforms@formsigdate{\tcdef@forms@advisorsignature}}\hfill%
  \parbox[t]{.45\textwidth}{\tcforms@formsigdate{\tcdef@forms@coadvisorsignature}}%
  \pagebreak%
}%
%
%


\NewDocumentCommand{\tcforms@rectifyTRapprovalform}{}{%
  \tc@formtopbox{\tcdef@forms@formstitleTR}{\tcdef@forms@rectifyapprovalformtitle}%

  \vfill%

  \tcforms@tccdesc%

  \vfill%
  \tcdef@forms@rectifyapprovalTRformdesc%

  \vfill%

  \tcforms@rectifyexaminersig[\tcdef@forms@formsadvisorlabel]{tc@studentA@advisor}%

  \vfill%

  \@ifundefined{tc@nBoard}{}{%
    \tcforms@rectifyexaminersig{tc@studentA@examinerA}%
  }%

  \tcforms@rectifyexaminersig{tc@studentA@examinerB}%

  \tcforms@rectifyexaminersig{tc@studentA@examinerC}%
  \vfill%
  \pagebreak%
}%
%
%
%
