commit 1b32fd0b8bbd051aba3f9ad05337ae3e66dc6d64 Author: rasz Date: Mon Aug 30 11:31:14 2021 -0300 Initial Commit diff --git a/README.md b/README.md new file mode 100644 index 0000000..9a1d80e --- /dev/null +++ b/README.md @@ -0,0 +1,11 @@ +#abnTeX2Fatec +##Author: F. Raszeja +###Made for my local college as an easier way to format "academic" work. + +This is what happens when you are mad with Word breaking formatting, but also can't use the abnTeX2 default models (which are already made with the ABNT - the Brazilian Standards - in mind) because of upper management. + +Actual "model" used by the college in question is a .docx file and I had to work off that, it was very poorly formatted and had some very dumb requirements, can be subject to change but as I am no longer associated with them, I won't be bothered with keeping this updated. + +Also included is an "update" to the way URLs and other web resources are displayed, it should be url6023.sty, but I've not tested it in a while. + +This requires "abntex2" and "biber" being installed and present on your machine. I included a compiled PDF example file and the .tex file used to make it. diff --git a/doc/latex/abntex2fatec/compiled-pdf/example.pdf b/doc/latex/abntex2fatec/compiled-pdf/example.pdf new file mode 100644 index 0000000..7b4c168 Binary files /dev/null and b/doc/latex/abntex2fatec/compiled-pdf/example.pdf differ diff --git a/doc/latex/abntex2fatec/example.bib b/doc/latex/abntex2fatec/example.bib new file mode 100644 index 0000000..ea1a782 --- /dev/null +++ b/doc/latex/abntex2fatec/example.bib @@ -0,0 +1,26 @@ +@book{citation1, + author = {Book Author}, + title = {Book Title}, + date = {2021}, + publisher = {Book Publisher}, +} + +@online{citation2, + author = {John Doe}, + title = {Online Resource Test}, + date = {date}, + url = {https://www.google.com/}, + year = {1998}, + urldate = {2020-11-09}, +} + +@manual{citation3, + author = {{Unity Technologies}}, + title = {Unity User Manual}, + location = {San Francisco}, + version ={2020.3 (LTS)}, + date = {2021-05-15}, + year = {2021}, + url = {https://docs.unity3d.com/Manual/UnityManual.html}, + urldate={2021-05-22} +} diff --git a/doc/latex/abntex2fatec/example.tex b/doc/latex/abntex2fatec/example.tex new file mode 100644 index 0000000..1725d87 --- /dev/null +++ b/doc/latex/abntex2fatec/example.tex @@ -0,0 +1,114 @@ +\documentclass{abntex2fatec} + +\usepackage{setspace} +\usepackage{blindtext} +\usepackage{graphicx} +\usepackage{caption} +\usepackage[T1]{fontenc} +\usepackage[utf8]{inputenc} +\autor{John Doe} + +\titulo{abnTeX2Fatec: ABsurd Norms for Fatec} +\data{2\textordmasculine\ Semester 2021} +\local{Nowhere, SP} + +\orientador{Teacher 1} +\coorientador{Teacher 2} + +\curso{No Course} + +\tipotrabalho{Type of Academic Work} +\preambulo{Preamble information goes here, + including who's helping you out in this, + like \imprimirorientador\\ and your buddy \imprimircoorientador} + +\addbibresource{example.bib} + +\begin{document} + \selectlanguage{brazil} + + \frenchspacing + + % cover + \imprimircapa + + % cover sheet + \imprimirfolhaderosto* + + % bibliographical sheet + + \begin{fichacatalografica} + \sffamily + \vspace*{\fill} % Vertical position + \begin{center} % Centralized minipage + \fbox{\begin{minipage}[c][8cm]{13.5cm} % Width + \small + \imprimirautor + %Surname, Name of the author + + \hspace{0.5cm} \imprimirtitulo / \imprimirautor. -- + \imprimirlocal, \imprimirdata- + + \hspace{0.5cm} \thelastpage p. : il. (algumas color.) ; 30 cm.\\ + \hspace{0.5cm} \imprimirorientadorRotulo~\imprimirorientador\\ + \hspace{0.5cm} + + \parbox[t]{\textwidth}{\imprimirtipotrabalho~--~\imprimirinstituicao, + \imprimirdata.}\\ + + \hspace{0.5cm} + 1. Keyword1. + 2. Keyword2. + 2. Keyword3. + I. Teacher. + II. University xxx. + III. College xxx. + IV. Title + \end{minipage}} + \end{center} + \end{fichacatalografica} + + \begin{dedicatoria} + \hspace{.45\textwidth} + \begin{minipage}{.5\textwidth} + \vspace*{40em} + \noident Dedicated to all my friends and family... + \end{minipage} + \end{dedicatoria} + + \begin{agradecimentos} + I thank John Doe for helping me out with... + \end{agradecimentos} + + \begin{resumo} + \SingleSpacing + \hspace{1.25cm} + \textbf{KEYWORDS}: Keywords go here. They must start with an Uppercase and be followed by a period. Like. This. Example. + \end{resumo} + + \listoffigures* + \cleardoublepage + + \pdfbookmark[0]{\contentsname}{toc} + \tableofcontents* + \cleardoublepage + + \textual + + \pagestyle{simple} + \setstretch{1.5} + + \chapter{Introduction} + This is a chapter. A chapter with * means it won't have a number. + This is a textcite \textcite{citation1}, this is a textapud \textapud{citation1, citation2}{citation3}. + \section{Section} + This is a section. 'Nuff said. + \subsection{Subsection} + This is a subsection. 'Nuff said. + \subsubsection{Subsubsection} + This is a subsubsection. 'Nuff said. + This is a cite \cite{citation1} + + \postextual + \bibliografiaFatec +\end{document} diff --git a/tex/latex/abntex2fatec/abntex2fatec.cls b/tex/latex/abntex2fatec/abntex2fatec.cls new file mode 100755 index 0000000..051c987 --- /dev/null +++ b/tex/latex/abntex2fatec/abntex2fatec.cls @@ -0,0 +1,119 @@ +%% +%% Customizações do abnTeX2 (http://abnTeX2.googlecode.com) para a Fatec +%% +%% This work may be distributed and/or modified under the +%% conditions of the LaTeX Project Public License, either version 1.3 +%% of this license or (at your option) any later version. +%% The latest version of this license is in +%% http://www.latex-project.org/lppl.txt +%% and version 1.3 or later is part of all distributions of LaTeX +%% version 2005/12/01 or later. +%% +%% This work has the LPPL maintenance status `maintained'. +%% +%% The Current Maintainer of this work is F. RASZEJA, no-email +%% +%% Further information about abnTeX2 are available on https://github.com/abntex/abntex2 +%% + +% --- +% INICIO DAS CUSTOMIZACOES PARA A UNIVERSIDADE Fatec +% --- + +%---------------------------------------------------- +% CORREÇÃO DO SUMÁRIO +%---------------------------------------------------- +\NeedsTeXFormat{LaTeX2e} + +\ProvidesClass{abntex2fatec}[2020/09/04 - v0.3] + +% -- Opções Padrão ABNTEX + +\PassOptionsToClass{ + 12pt, + openright, + oneside, + a4paper, + brazil, + sumario=tradicional, + chapter=TITLE, + section=TITLE, + subsection=TITLE, + subsubsection=TITLE, + subsubsubsection=TITLE +}{abntex2} + +\DeclareOption*{ + \PassOptionsToClass{\CurrentOption}{abntex2} +} + +\ProcessOptions\relax + +\LoadClass{abntex2} + +\RequirePackage{etoc} +\RequirePackage{fatexSty} + +\usepackage[a4paper, top=3cm, bottom=2cm, left=3cm, right=2cm]{geometry} + +\usepackage[style=abnt]{biblatex} % Citações padrão ABNT +\DisemulatePackage{setspace} +\DeclareFieldFormat{url}{\bibstring{urlfrom}\addcolon\space<\url{#1}>} +% Comandos Customizados Fatec +\renewcommand{\imprimircapa}{% + \begin{capa}% + \center + \textbf\imprimircustom + \vfill + \bfseries\imprimirautor + \vfill + \begin{center} + \bfseries\imprimirtitulo + \end{center} + \vfill + \bfseries\imprimirlocal\\ + \bfseries\imprimirdata + \end{capa} +} + +\renewcommand{\folhaderostocontent}{% + \begin{folhaderosto}% + \center + \bfseries\imprimirautor + \vfill + \begin{center} + \bfseries\imprimirtitulo + \end{center} + \vspace{1.5cm} + \hspace{.45\textwidth} + \begin{minipage}{.5\textwidth} + \SingleSpacing + \normalfont\imprimirpreambulo + \end{minipage}% + \vfill + \bfseries\imprimirlocal\\ + \bfseries\imprimirdata + \end{folhaderosto} +} +\providecommand{\imprimircurso}{} +\providecommand{\imprimircustom}{} +\newcommand{\curso}[1] +{ + \renewcommand{\imprimircurso}{#1} + \renewcommand{\imprimirinstituicao} + { + Centro Paula Souza + \par + Faculdade de Tecnologia de Local + \par + Curso Superior de Tecnologia em #1 + } + \renewcommand{\imprimircustom} + { + CENTRO PAULA SOUZA + \par + FACULDADE DE TECNOLOGIA DE LOCAL + \par + CURSO SUPERIOR DE TECNOLOGIA EM \MakeUppercase{#1} + } +} diff --git a/tex/latex/abntex2fatec/fatexSty.sty b/tex/latex/abntex2fatec/fatexSty.sty new file mode 100755 index 0000000..58a5bbc --- /dev/null +++ b/tex/latex/abntex2fatec/fatexSty.sty @@ -0,0 +1,151 @@ + +\ProvidesPackage{fatexSty}[2020/09/04 - v0.3] + +\RequirePackage[explicit]{titlesec} % Para consertar formatação +\RequirePackage{indentfirst} % Indenta o primeiro parágrafo de cada sessão. + +\RequirePackage{graphicx} % Gráficos + +% Correção para utilizar fonte arial, 12pt +\RequirePackage[T1]{fontenc} +\RequirePackage[utf8]{inputenc} +\RequirePackage{uarial} +\urlstyle{same} + +%\RequirePackage[brazilian,hyperpageref]{backref} % Paginas com as citações na bibl +%\RequirePackage[alf,abnt-thesis-year=title,abnt-emphasize=bf]{abntex2cite} % Citações "padrão" ABNT + +% Configurações do pacote backref +% Usado sem a opção hyperpageref de backref +%\renewcommand{\backrefpagesname}{Citado na(s) página(s):~} +% Texto padrão antes do número das páginas +%\renewcommand{\backref}{} +% Define os textos da citação +%\renewcommand*{\backrefalt}[4]{ +% \ifcase #1 % +% Nenhuma citação no texto.% +% \or +% Citado na página #2.% +% \else +% Citado #1 vezes nas páginas #2.% +% \fi}% +% -- + +\renewcommand{\familydefault}{\sfdefault} + + +\setlength{\parindent}{1.25cm} + +% Gambiarras para consertar formatação do resumo.... +\AtBeginDocument +{ + \hypersetup{hidelinks = true} % esconder cor de hyperlinks do pdf + \setlength{\absparsep}{36pt} % ajusta o espaçamento dos parágrafos do resumo + \setlength{\abstitleskip}{1ex} % adiciona mais um cm após o 'titulo' do Resumo para ficar com 2cm +} + +\setcounter{secnumdepth}{4} +\setcounter{tocdepth}{4} + +% Correções para titulo de seção, capitulo, etc. +\titleformat{name=\chapter}[block]{\normalfont\bfseries}{\thechapter \quad \MakeUppercase{#1}}{.5em}{\vspace{.5ex}} +\titleformat{name=\chapter,numberless}[block]{\bfseries}{\MakeUppercase{#1}}{12pt}{} +\titleformat{name=\section}[block]{\normalfont}{\thesection \quad \MakeUppercase{#1}}{.5em}{\vspace{.5ex}} +\titleformat{name=\section,numberless}[block]{\normalfont}{\MakeUppercase{#1}}{12pt}{} +\titleformat{name=\subsection}[block]{\normalfont\bfseries}{\thesubsection \quad \MakeUppercase{#1}}{.5em}{\vspace{.5ex}} +\titleformat{name=\subsection,numberless}[block]{\normalfont\bfseries}{\MakeUppercase{#1}}{12pt}{} +\titleformat{name=\subsubsection}[block]{\normalfont}{\thesubsubsection \quad \MakeUppercase{#1}}{.5em}{\vspace{.5ex}} +\titleformat{name=\subsubsection,numberless}[block]{\normalfont}{\MakeUppercase{#1}}{12pt}{} +\titleformat{name=\paragraph}[block]{\normalfont\bfseries}{\theparagraph \quad \MakeUppercase{#1}}{.5em}{\vspace{.5ex}} +\titleformat{name=\paragraph,numberless}[block]{\normalfont\bfseries}{\MakeUppercase{#1}}{12pt}{} +\titleformat{name=\subparagraph}[block]{\normalfont}{\thesubparagraph \quad \MakeUppercase{#1}}{.5em}{\vspace{.5ex}} +\titleformat{name=\subparagraph,numberless}[block]{\normalfont}{\MakeUppercase{#1}}{12pt}{} + +\titlespacing*{\chapter}{0pt}{0cm}{1.5cm} +\titlespacing*{\section}{0pt}{1.5cm}{1.5cm} +\titlespacing*{\subsection}{0pt}{1.5cm}{1.5cm} +\titlespacing*{\subsubsection}{0pt}{1.5cm}{1.5cm} +\titlespacing*{\paragraph}{0pt}{1.5cm}{1.5cm} +\titlespacing*{\subparagraph}{0pt}{1.5cm}{1.5cm} + +\renewcommand{\chaptitlefont}{\normalfont\bfseries} +\renewcommand{\chapnumfont}{\normalfont\bfseries} + +% Correção para padrão FATEC +\renewcommand{\agradecimentosname}{\centerline{Agradecimentos}} + +% Comando para criar nomes do sumário... +\newcommand{\bibliografiaFatec}{% + \begingroup + \newpage + \titleformat{name=\chapter,numberless}[block]{\centering\bfseries}{\MakeUppercase\refname}{12pt}{} + \phantomsection + \addcontentsline{toc}{chapter}{\refname} + \chapter*{} + \printbibliography[heading=none] + \endgroup +} + +% Correções para índice +\makeatletter +\let\old@chapter\l@chapter +\let\old@chapternumberline\chapternumberline + +\etocsetstyle{chapter}{} + {} + {\etocifnumbered + {\addvspace{.5ex}\setlength{\leftskip}{1cm}\noindent + {\llap{\makebox[1cm][l]{\bfseries\etocnumber}}\hspace{0.8cm}\bfseries\etoclink{\MakeUppercase\etocthename} + \hspace{-4pt}\nobreak\dotfill\hspace{-1pt}\etocpage\par} + } + {\addvspace{-4ex}\setlength{\leftskip}{1cm}\noindent + {\llap{\makebox[1cm][l]{\bfseries\etoclink{\MakeUppercase\etocthename}}} + \hspace{1.85cm}\nobreak\bfseries\dotfill\hspace{-1pt}\etocpage\par} + } + } +{}% + +\let\old@section\l@section +\etocsetstyle{section}{} + {\addvspace{.5ex}\noindent\setlength{\leftskip}{1cm}\noindent} + {\llap{\makebox[1cm][l]{{\etocnumber}}}\hspace{0.8cm}\normalfont\etoclink{\MakeUppercase\etocthename} + \hspace{-4pt}\nobreak\dotfill\hspace{-1pt}\etocpage\par} +{}% + +\let\old@subsection\l@subsection +\etocsetstyle{subsection}{} + {} + {\etocifnumbered + {\addvspace{.5ex}\setlength{\leftskip}{1cm}\noindent + {\llap{\makebox[1cm][l]{\bfseries\etocnumber}}\hspace{0.8cm}\bfseries\etoclink{\MakeUppercase\etocthename} + \hspace{-4pt}\nobreak\dotfill\hspace{-1pt}\etocpage\par} + } + {\addvspace{-4ex}\setlength{\leftskip}{1cm}\noindent + {\llap{\makebox[1cm][l]{\bfseries\etoclink{\MakeUppercase\etocthename}}} + \hspace{1.85cm}\nobreak\bfseries\dotfill\hspace{-1pt}\etocpage\par} + } + } +{}% + +\let\old@subsubsection\l@subsubsection +\etocsetstyle{subsubsection}{} + {\addvspace{.5ex}\noindent\setlength{\leftskip}{1cm}\noindent} + {\llap{\makebox[1cm][l]{{\etocnumber}}}\hspace{0.8cm}\normalfont\etoclink{\MakeUppercase\etocthename} + \hspace{-4pt}\nobreak\dotfill\hspace{-1pt}\etocpage\par} +{}% + +\let\old@paragraph\l@paragraph +\etocsetstyle{paragraph}{} +{} +{\etocifnumbered + {\addvspace{.5ex}\setlength{\leftskip}{1cm}\noindent + {\llap{\makebox[1cm][l]{\bfseries\etocnumber}}\hspace{0.8cm}\bfseries\etoclink{\MakeUppercase\etocthename} + \hspace{-4pt}\nobreak\dotfill\hspace{-1pt}\etocpage\par} + } + {\addvspace{-4ex}\setlength{\leftskip}{1cm}\noindent + {\llap{\makebox[1cm][l]{\bfseries\etoclink{\MakeUppercase\etocthename}}} + \hspace{1.85cm}\nobreak\bfseries\dotfill\hspace{-1pt}\etocpage\par} + } +} +{}% +\makeatother \ No newline at end of file diff --git a/tex/latex/abntex2fatec/url6023.sty b/tex/latex/abntex2fatec/url6023.sty new file mode 100755 index 0000000..90f3685 --- /dev/null +++ b/tex/latex/abntex2fatec/url6023.sty @@ -0,0 +1,9 @@ +\ProvidesPackage{url6023} +% NBR 6023/2018 +\makeatletter +\@ifpackageloaded{url}{% +\addtociteoptionlist{abnt-url-package=url} +\def\UrlLeft{} +\def\UrlRight{} +\urlstyle{same}} +\makeatother \ No newline at end of file