\RequirePackage[l2tabu,orthodox]{nag}
\documentclass[11pt,letterpaper,twoside]{article}
\usepackage[T1]{fontenc}
\usepackage[total={6in,10in},left=1.5in,top=0.5in,includehead,includefoot]{geometry}
\usepackage{tabularx}
\begin{document}
\subsection{Subsection title}
Bla bla
\begin{table}
\begin{tabularx}{\textwidth}{|X|X|X|}
\hline
Name 1 & Name 2 & Name 3
\\ \hline
Text & Text & Text
\\ \hline
\end{tabularx}
\end{table} % What is wrong with this table?
Bla bla
\end{document}
Last edited by Cham on Sat Oct 28, 2017 4:54 pm, edited 1 time in total.
Nothing. The package assumes that every tabular (defined within table) moves around (it does indeed, as that is the only purpose of a table) and needs a caption to be refernced.
Are you maybe doing \begin{table}[H] in your own document? Do not. Omit the table environment.
A mistake many users make.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
\RequirePackage[l2tabu,orthodox]{nag}
\documentclass[11pt,letterpaper,twoside]{article}
\usepackage[T1]{fontenc}
\usepackage[total={6in,10in},left=1.5in,top=0.5in,includehead,includefoot]{geometry}
\usepackage{tabularx}
\usepackage{here}
\begin{document}
\subsection{Subsection title}
Bla bla
\begin{table}[H]
\centering
\renewcommand{\arraystretch}{1.5}
\begin{tabularx}{\textwidth}{|X|X|X|}
\hline
Name 1 & Name 2 & Name 3
\\ \hline
Text & Text & Text
\\ \hline
\end{tabularx}
\end{table} % WHAT IS WRONG?
Bla bla
\end{document}
\RequirePackage[l2tabu,orthodox]{nag}
\documentclass[11pt,letterpaper,twoside]{article}
\usepackage[T1]{fontenc}
\usepackage[total={6in,10in},left=1.5in,top=0.5in,includehead,includefoot]{geometry}
\usepackage{tabularx}
\usepackage{here}
\begin{document}
\subsection{Subsection title}
Bla bla
{\centering
\renewcommand{\arraystretch}{1.5}
\begin{tabularx}{\textwidth}{|X|X|X|}
\hline
Name 1 & Name 2 & Name 3
\\ \hline
Text & Text & Text
\\ \hline
\end{tabularx}}
Bla bla
\begin{center}
\renewcommand{\arraystretch}{1.5}
\begin{tabularx}{\textwidth}{|X|X|X|}
\hline
Name 1 & Name 2 & Name 3
\\ \hline
Text & Text & Text
\\ \hline
\end{tabularx}
\end{center}
No Wombat in the table above.
\end{document}
Just stick with using H.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
Ok, thanks a lot. For the moment, I'll stick with the table environment (with [H]).
But I still have a strange Nag warning with that label inside a list. I don't know what to do, to solve this issue, and I'm yet unable to produce a MWE for this. I'll try something else.
Nag is a script, without any intelligence. It might report false warnings.
The manual even tells you so, it can report false things and it might not pick up all bad things.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.