I have this code from this question answered by David Carlisle.
I don't fully understand what it's doing. I would like both tables to be full width.
Below is a minimal example where i would like the first table to be full width. The second table acts properly.
\documentclass[10pt,a4paper,oneside,onecolumn,openany]{report}
\usepackage{tabulary}
\usepackage{tabularx}
\usepackage{ltablex}
\usepackage{ragged2e}
\usepackage{longtable}
\usepackage[showframe]{geometry}
\makeatletter
\def\ltabulary{%
\def\endfirsthead{\}%
\def\endhead{\}%
\def\endfoot{\}%
\def\endlastfoot{\}%
\def\tabulary{%
\def\TY@final{%
\def\endfirsthead{\LT@end@hd@ft\LT@firsthead}%
\def\endhead{\LT@end@hd@ft\LT@head}%
\def\endfoot{\LT@end@hd@ft\LT@foot}%
\def\endlastfoot{\LT@end@hd@ft\LT@lastfoot}%
\longtable}%
\let\endTY@final\endlongtable
\TY@tabular}%
\tabulary}
\def\endltabulary{\endtabulary}
\makeatother
\begin{document}
\hspace*{0pt}\tymin=50pt\tymax=400pt\begin{ltabulary}{\textwidth}{|L|L|} \hline
\rule{0pt}{4mm}\textbf{\hspace{0pt}Fuz} & \textbf{\hspace{0pt}Baz} \ \hline
\rule{0pt}{4mm}A & B \ \hline
\rule{0pt}{4mm}C & D \ \hline
\end{ltabulary}
\hspace*{0pt}\tymin=50pt\tymax=400pt\begin{ltabulary}{\textwidth}{|L|L|} \hline
\rule{0pt}{4mm}\textbf{\hspace{0pt}Fuz} & \textbf{\hspace{0pt}Baz} \ \hline
\rule{0pt}{4mm}AAAAAAAAAA & BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB \ \hline
\rule{0pt}{4mm}C & D \ \hline
\end{ltabulary}
\end{document}
Output:
Thanks.



{0.5\textwidth}-- the double XX athe end are only to demonstrate expansion to textwidth and can be safely removed – js bibra Dec 10 '20 at 15:34