Debian Codegraph @

texmf-dist/doc/latex/abntexto/abntexto-exemplo.tex

raw
1 %! File: abntexto-exemplo.tex
2 %! License: Public Domain Software
3 %! Version: 1.1 2026-05-08
4 %! Author: Elayson Abreu 2022--2026
5 %! Contact: [email protected]
6 %!
7 %! This work consists of the files
8 %! abntexto.bib, abntexto-exemplo.bib,
9 %! abntexto.cls, abntexto-3-2-1-beta.cls,
10 %! CHANGELOG.md, README.md,
11 %! abntexto-birds.jpg, abntexto.pdf,
12 %! abntexto-exemplo.pdf, abntexto-onehalf-tex.pdf
13 %! abntexto-onehalf-word.tex, abntexto-screenshot.png,
14 %! abntexto.tex, abntexto-exemplo.tex
15
16 % !TeX TS-program = lualatex
17 \documentclass{abntexto}
18
19 % Precisamos do shorthands=off em babel para
20 % que o tikz-cd.sty funcione corretamente.
21
22 \usepackage{lipsum}
23 \usepackage[english,brazilian,shorthands=off]{babel}
24 \usepackage[style=abnt]{biblatex} \addbibresource{abntexto-exemplo.bib}
25 \usepackage{hyperref}
26 \usepackage{fontspec}
27 \usepackage{unicode-math}
28 \usepackage{multirow}
29 \usepackage{booktabs}
30 \usepackage{tikz}
31 \usepackage{chemfig}
32 \usepackage[siunitx]{circuitikz}
33 \usepackage{pseudo}
34 \usepackage{tikz-cd}
35 \usepackage{xurl}
36 \usepackage[brazilian,noabbrev,capitalize]{cleveref} \AtBeginDocument{\def\ref{\cref}}
37
38 \setmainfont{XITS}[
39 UprightFont = *-Regular,
40 BoldFont = *-Bold,
41 ItalicFont = *-Italic,
42 BoldItalicFont = *-BoldItalic,
43 Extension = .otf
44 ]
45 \setmathfont{XITSMath-Regular.otf}
46 \setmonofont{InconsolataN-Regular.otf}
47
48 \def \Autor{Elayson Abreu}
49 \def \Instituicao{Instituição}
50 \def \IniciaisDaInstituicao{SIGLA}
51 \def \Cidade{Cidade}
52 \def \AnoDeEntrega{Ano}
53 \def \Titulo{Classe {\ttfamily abntexto} para \LaTeX\ versão 1.1: um exemplo de uso}
54 \def \TipoDeTrabalho{Dissertação}
55 \def \DescricaoDoTrabalho{\TipoDeTrabalho\ apresentada a \Instituicao\ como cumprimento às exigências legais para obtenção do título de Mestre.}
56 \def \AreaDeConcentracao{Matemática}
57 \def \Orientador{Dr.\,Nome}
58 \def \Coorientador{Dr.\,Nome}
59
60 \definelegendplace{g}{Gráfico}{logr}
61 \definelegendplace{c}{Composto}{loq}
62 \definelegendplace{circ}{Circuito}{locirc}
63 \definelegendplace{a}{Algoritmo}{loa}
64 \definelegendplace{d}{Diagrama}{lod}
65 \definelegendplace{f}{Fotografia}{lof}
66 \Crefname{g}{Gráfico}{Gráficos}
67 \Crefname{c}{Composto}{Compostos}
68 \Crefname{circ}{Circuito}{Circuitos}
69 \Crefname{a}{Algoritmo}{Algoritmos}
70 \Crefname{d}{Diagrama}{Diagramas}
71 \Crefname{f}{Fotografia}{Fotografias}
72
73 \def\paragraphfont {\scshape}
74 \def\subparagraphfont {\scshape\addfontfeatures{FakeSlant=.2}}
75 \def\tocparagraphfont {\scshape}
76 \def\tocsubparagraphfont{\scshape\addfontfeatures{FakeSlant=.2}}
77
78 \long\def\note#1{\abntextonote{#1}}
79
80 \def\Centro{\noindent\hfil}
81 \def\Direita{\noindent\hfill}
82 \def\me{Elaboração própria.}
83 \appto\bibfont{\raggedright\interlinepenalty=10000 \singlesp\bibitemsep=\baselineskip}
84 \hypersetup{
85 pdfauthor = \Autor,
86 pdftitle = \Titulo,
87 pdfcreator = LaTeX with abntexto,
88 pdfkeywords = P1. P2. P3. P4,
89 }
90 \makeatletter
91
92
93
94 \begin{document}
95
96 % De acordo com a NBR 14724, “os elementos pré-textuais devem iniciar no
97 % anverso da folha, com exceção dos dados internacionais de catalogação na publicação,
98 % que devem constar no verso da folha de rosto. Recomenda-se que os elementos textuais e
99 % pós-textuais sejam apresentados no anverso e verso das folhas (ABNT, 2024, p. 10)”.
100
101 % CAPA
102 % ================================================
103
104 \Centro
105 \begin{minipage}{.7\linewidth}
106 \centering
107 \includegraphics[height=4\baselineskip]{example-image}\\
108 \Instituicao
109 \end{minipage}
110 \Enter[7]
111
112 \Centro\Autor
113 \Enter[3]
114
115 \Centro
116 \begin{minipage}{.7\linewidth}
117 \centering
118 \Titulo
119 \end{minipage}
120 \vfill
121
122 \Centro\Cidade % A próxima linha em branco é necessária.
123
124 \Centro\AnoDeEntrega
125
126 \newpage\null\newpage
127
128 % FOLHA DE ROSTO
129 % ================================================
130
131 \Centro\Autor
132 \Enter[9]
133
134 \Centro
135 \begin{minipage}{.7\linewidth}
136 \centering
137 \Titulo
138 \end{minipage}
139 \Enter[2]
140
141 \Direita
142 \begin{minipage}{.5\linewidth}
143 \singlesp\nohyph
144 \DescricaoDoTrabalho\Enter
145 Área de concentração: \AreaDeConcentracao.\\
146 Orientador: \Orientador.\\
147 Coorientador: \Coorientador.
148 \end{minipage}
149 \vfill
150
151 \Centro\Cidade % A próxima linha em branco é necessária.
152
153 \Centro\AnoDeEntrega
154
155 \newpage
156
157 % FICHA CATALOGRÁFICA
158 % ================================================
159
160 \begingroup \twosidelayout
161 \leavevmode\vfill
162 \Centro Dados Internacionais de Catalogação na Publicação (CIP)
163 \Enter[.5]
164
165 \Centro
166 \begin{indexcard}
167 \noindent A000\hskip\parindent \qquad \Autor
168
169 \setbox0=\hbox{A000\qquad}\leftskip=\wd0 % A linha em branco antes
170 % dessa instrução é necessária.
171 \Titulo/\Autor\ --- \Cidade: \Instituicao, UNI, \AnoDeEntrega.
172
173 105\,f.
174
175 \TipoDeTrabalho\ (\MakeUppercase{\AreaDeConcentracao}) --- \Instituicao, UNI: \Cidade, \AnoDeEntrega.
176
177 Orientador(a): \Orientador.
178
179 Coorientador(a): \Coorientador.
180
181 1. P1.
182 2. P2.
183 3. P3.
184 4. P4.
185 I. Título.
186
187 \Direita CDU 000
188 \end{indexcard}
189 \newpage
190 \endgroup
191
192 % ERRATA (OPCIONAL)
193 % ================================================
194
195 \nonum\notoc\section{Errata}
196
197 \begingroup \bibfont\fullcite{ferrigno2011}. \par\endgroup % Esse \par é necessário.
198 \Enter
199
200 \Centro
201 \begin{tabular}{cccc}
202 \hline
203 \bfseries Folha & \bfseries Linha & \bfseries Onde se lê & \bfseries Leia-se \\ \hline
204 16 & 10 & auto-clavado & autoclavado \\ \hline
205 \end{tabular}
206 \newpage\null\newpage
207
208 % FOLHA DE APROVAÇÃO
209 % ================================================
210
211 \Centro\Autor
212 \Enter[9]
213
214 \Centro
215 \begin{minipage}{.7\linewidth}
216 \centering
217 \Titulo
218 \end{minipage}
219 \Enter[2]
220
221 \Direita
222 \begin{minipage}{.5\linewidth}
223 \singlesp\nohyph
224 \DescricaoDoTrabalho\Enter
225 Área de concentração: \AreaDeConcentracao.
226 \end{minipage}
227 \Enter
228
229 {\parindent=1.5cm Aprovado em 00/00/0000.\par}
230 \Enter
231
232 \judgeline{Nome \\ Instituição}\Enter
233 \judgeline{Nome \\ Instituição}\Enter
234 \judgeline{Nome \\ Instituição}
235 \newpage\null\newpage
236
237 % DEDICATÓRIA (OPCIONAL)
238 % ================================================
239
240 \leavevmode\vfill
241
242 \Direita
243 \begin{minipage}{5cm}
244 \itshape Dedico este trabalho a\dots
245 \end{minipage}
246 \newpage\null\newpage
247
248 % AGRADECIMENTOS (OPCIONAL)
249 % ================================================
250
251 \nonum\notoc\section{Agradecimentos}
252 {\parindent=1.5cm\lipsum[1]\par}
253 \newpage\null\newpage
254
255 % EPÍGRAFE (OPCIONAL)
256 % ================================================
257
258 \leavevmode\vfil
259
260 \Direita
261 \begin{minipage}{3cm}
262 \noindent {\itshape Epígrafe}\linebreak
263 Autor (ano)
264 \end{minipage}
265 \newpage\null\newpage
266
267 % RESUMO
268 % ================================================
269
270 \nonum\notoc\section{\abstractname}
271 % Apesar de ser um parágrafo, o Resumo
272 % não costuma ter indentação.
273 \noindent \lipsum[1]\Enter
274
275 Palavras-chave: Palavra-chave A. Palavra-chave B. Palavra-chave C.
276 \newpage\null\newpage
277
278 % RESUMO EM LÍNGUA ESTRANGEIRA
279 % ================================================
280
281 {\selectlanguage{english}\nonum\notoc\section{\abstractname}}
282 {\selectlanguage{english}\noindent \lipsum[1]\Enter}
283
284 {\selectlanguage{english}Keywords: Keyword A. Keyword B. Keyword C.\par}
285 \newpage
286
287 % LISTA DE FIGURAS (OPCIONAL), TABELAS (OPCIONAL), SUMÁRIO
288 % ================================================
289
290 \nonum\notoc\section{\listfigurename}
291 \makelof
292 \newpage\null\newpage
293
294 \nonum\notoc\section{\listtablename}
295 \makelot
296 \newpage\null\newpage
297
298 \nonum\notoc\section{\contentsname}
299 \maketoc
300
301 \section{Uma seção primária}
302 \subsection{Uma seção secundária}
303 \subsubsection{Uma seção terciária}
304 \paragraph{Uma seção quaternária}
305 \subparagraph{Uma seção quinária}
306
307 \section{Tabelas e figuras}
308
309 \lipsum[1]
310
311 \legend{table}{Pessoas residentes em domicílios particulares, por sexo e situação do domicílio. Brasil, 1980.}
312 \src{\textcite{ibge1993}.}
313 \label{tab:pessoas-residentes-em}
314 \begin{place}
315 \begin{tabular}{*3{c@{\quad}} c} \hline
316 Situação do domicílio & Total & Mulheres & Homens \\ \hline
317 Total & 117\,960\,301 & 59\,595\,332 & 58\,364\,969 \\
318 Urbana & 79\,972\,931 & 41\,115\,439 & 38\,857\,492 \\
319 Rural & 37\,987\,370 & 18\,479\,893 & 19\,507\,477 \\ \hline
320 \end{tabular}
321 \end{place}
322
323 \legend{table}{Esperança de vida ao nascer, por região socioeconômica. Brasil, 1940--1980.}
324 \src{\textcite[adaptado]{ibge1993}.}
325 \note{Média das esperanças de vida ao nascer, resultantes de interpolação linear, nas Tábuas de Mortalidade Modelo Brasil, das probabilidades de morrer até as idades de 2, 3 e 5 anos, obtidas através do emprego da Técnica de Brass.\\ Sinais convencionais utilizados:
326 \par\vskip3pt
327 \begin{tabular}{rl}
328 .. & Não se aplica dado numérico. \\
329 ... & Dado numérico não disponível.
330 \end{tabular}
331 }
332 \label{tab:esperanca-de-vida}
333 \begin{place}
334 \begin{tabular}{@{}llllll@{}}
335 \toprule
336 \multicolumn{1}{c}{\multirow{2}{*}{\begin{tabular}[c]{@{}c@{}}Região\\ socioeconômica\end{tabular}}} &
337 \multicolumn{5}{c}{Esperança de vida ao nascer (anos)} \\ \cmidrule(l){2-6}
338 \multicolumn{1}{c}{} &
339 \multicolumn{1}{c}{1940} &
340 \multicolumn{1}{c}{1950} &
341 \multicolumn{1}{c}{1960} &
342 \multicolumn{1}{c}{1970} &
343 \multicolumn{1}{c}{1972} \\ \midrule
344 Brasil &
345 42,74 &
346 45,90 &
347 52,37 &
348 52,49 &
349 53,36 \\
350 Região I - RJ &
351 45,38 &
352 50,91 &
353 59,19 &
354 57,29 &
355 63,21 \\
356 Região VI - DF &
357 .. &
358 .. &
359 48,91 &
360 54,17 &
361 60,31 \\
362 \begin{tabular}[c]{@{}l@{}}Região VII - RO, AC, AM,\\ RR, PA, AP, MS, MT e GO\end{tabular} &
363 ... &
364 ... &
365 ... &
366 56,67 &
367 ... \\ \midrule \midrule
368 \multicolumn{1}{c}{\multirow{2}{*}{\begin{tabular}[c]{@{}c@{}}Região\\ socioeconômica\end{tabular}}} &
369 \multicolumn{5}{c}{Esperança de vida ao nascer (anos)} \\ \cmidrule(l){2-6}
370 \multicolumn{1}{c}{} &
371 \multicolumn{1}{c}{1973} &
372 \multicolumn{1}{c}{1976} &
373 \multicolumn{1}{c}{1977} &
374 \multicolumn{1}{c}{1978} &
375 \multicolumn{1}{c}{1980} \\ \midrule
376 Brasil &
377 54,56 &
378 57,25 &
379 57,81 &
380 58,44 &
381 59,83 \\
382 Região I - RJ &
383 63,44 &
384 65,96 &
385 65,09 &
386 64,81 &
387 63,23 \\
388 Região II - SP &
389 64,87 &
390 64,31 &
391 64,54 &
392 64,98 &
393 63,55 \\ \bottomrule
394 \end{tabular}
395 \end{place}
396
397 \legend{figure}{Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit, vestibulum ut, placerat ac, adipiscing vitae, felis.}
398 \src\me
399 \label{fig1}
400 \begin{place}
401 \includegraphics[width=.4\linewidth]{example-image-a}
402 \end{place}
403
404 Ver \ref{tab:pessoas-residentes-em}, \ref{fig1}.
405
406 \section{TikZ, chemfig, circuitikz, pseudo}
407
408 \ref{g:fun} elaborado com {\ttfamily tikz.sty}. \ref{q:etanol} desenhado com {\ttfamily chemfig.sty}. \ref{circ:am} desenhado com {\ttfamily circuitikz.sty}. \ref{a:exemplo} escrito com {\ttfamily pseudo.sty}. \ref{d:exemplo} elaborado com {\ttfamily tikz-cd.sty}. Ver \ref{f:pass}.
409
410 \begin{multiplace}
411 \sublegend[g]{Função quadrática}
412 \label{g:fun}
413 \subsrc\me
414 \hfil
415 \begin{subplace}
416 \begin{tikzpicture}[scale=.75]
417 % Eixos
418 \draw[->] (-2.5,0) -- (2.5,0) node[right] {$x$};
419 \draw[->] (0,-0.5) -- (0,4.5) node[above] {$y$};
420
421 % Grade (opcional)
422 % \draw[very thin,color=gray!30] (-2.1,-0.1) grid (2.1,4.1);
423
424 % Rótulos nos eixos
425 \foreach \x in {-2,-1,1,2}
426 \draw (\x,0.1) -- (\x,-0.1) node[below] {$\x$};
427 \foreach \y in {1,2,3,4}
428 \draw (0.1,\y) -- (-0.1,\y) node[left] {$\y$};
429
430 % Gráfico de f(x) = x^2
431 \draw[domain=-2:2, smooth, variable=\x, blue, thick]
432 plot ({\x}, {\x*\x});
433
434 % Nome da função
435 \node[blue] at (1.3, 1.6) {$f(x) = x^2$};
436 \end{tikzpicture}
437 \end{subplace}
438 \sublegend[c]{A estrutura química do etanol}
439 \label{q:etanol}
440 \subsrc\me
441 \hfil
442 \begin{subplace}
443 \chemfig{H-C(-[2]H)(-[6]H)-C(-[2]H)(-[6]H)-O-H}
444 \end{subplace}
445 \sublegend[circ]{\raggedright Fonte de tensão $V$ e dois resistores $R_1$ e $R_2$ ligados em paralelo.}
446 \label{circ:am}
447 \subsrc\me
448 \vadjust{\nobreak}\\[\baselineskip] \null \hfil
449 \begin{subplace}
450 \begin{circuitikz}[scale=.7]
451 \draw
452 (0,0) to[battery1, l=$V$] (0,4)
453 to[short] (2,4)
454 to[R, l=$R_1$] (2,2)
455 -- (2,0)
456 -- (0,0);
457
458 \draw
459 (2,4) to[short] (4,4)
460 to[R, l=$R_2$] (4,0)
461 -- (2,0);
462 \end{circuitikz}
463 \end{subplace}
464 \sublegend[a]{Exemplo}
465 \label{a:exemplo}
466 \subsrc{\cite{package-pseudo}}
467 \hfil
468 \begin{subplace}
469 \begin{pseudo}[kw,indent-mark]
470 for $k = 1$ to $n$ \\+
471 for $i = 1$ to $n$ \\+
472 for $j = 1$ to $n$ \\+
473 $t_{ij} = t_{ij} \lor (t_{ik} \land t_{kj})$ \\---
474 return $t$
475 \end{pseudo}
476 \end{subplace}
477 \sublegend[d]{Exemplo em 3D}
478 \label{d:exemplo}
479 \subsrc\me
480 \vadjust{\nobreak}\\[\baselineskip] \null \hfil
481 \begin{subplace}
482 $$
483 \begin{tikzcd}[row sep=1.5em, column sep=2em]
484 & A \arrow[rr, "f"] \arrow[dd, "g"'] \arrow[dl, swap, "u"] & & B \arrow[dd, "h"] \arrow[dl, "v"] \\
485 U \arrow[rr, crossing over, "w" near start] \arrow[dd, "s"'] & & V \\
486 & C \arrow[rr, "k"'] & & D \\
487 X \arrow[rr, "y"'] & & Y \arrow[from=uu, crossing over, "t"']
488 \end{tikzcd}
489 $$
490 \end{subplace}
491 \sublegend[f]{Pássaros}
492 \label{f:pass}
493 \subsrc{Disponível em: \url{https://pixabay.com/pt/photos/p\%C3\%A1ssaros-penas-asas-ornitologia-9324370/}. Acesso em: 17 jul 2025.}
494 \hfil
495 \begin{subplace}
496 \includegraphics[width=.9\linewidth]{abntexto-birds.jpg}
497 \end{subplace}
498 \end{multiplace}
499
500 \section{Citações}
501
502 \enquote{A vida é aquilo que acontece enquanto você está ocupado fazendo outros planos} \cite{lennon}.
503
504 \Enquote{
505 É uma verdade universalmente reconhecida que um homem solteiro em posse de uma grande fortuna precisa de uma esposa. Por mais pouco conhecidos os sentimentos ou pontos de vista de tal homem possam ser ao entrar numa vizinhança, esta verdade está tão bem fixada nas mentes das famílias vizinhas que ele é considerado a propriedade legítima de alguma filha sua
506 \cite[][tradução por Lúcio Cardoso]{austen1813orgulho}.
507 }
508
509 \section{Alíneas}
510
511 \lipsum[1][1-5]:
512
513 \begin{topics}
514 \item \lipsum[1][1]:
515 \begin{topics}
516 \item \lipsum[1][1];
517 \item \lipsum[1][1];
518 \end{topics}
519 \item \lipsum[1][1];
520 \item \lipsum[1][1]
521 \end{topics}
522
523 \newpage
524
525 \begin{corrprint}
526 \printbibliography
527 \end{corrprint}
528
529 \end{document}