I'm writing an elsevier els-cas article and am trying to hatch some table cells for a table\tabular setting. It seemed to work fine until I used \resizebox and set the table size to \textwidth. The Tikz hatched cells don't seem to scale correctly. I looked at previous solutions such as hatching table cells fails when using positioning and Correctly scaling a tikzpicture but the solutions don't seem to suit the table environment I'm working with.
For the MWE I wasn't able to fit any hatch correctly in one cell, not to mention two. I'm looking for something like this (see attached picture).
The MWE:
\documentclass[a4paper]{cas-dc}
\usepackage{makecell}
\usepackage{tikz}
\usepackage{multirow}
\begin{document}
\begin{table}[]
\resizebox{\textwidth}{!}{%
\begin{tabular}{c|ll|llc|cccc|}
\multicolumn{1}{l|}{\multirow{2}{}{}} & \multicolumn{2}{c|}{\multirow{2}{}{Unit}} & \multicolumn{3}{c|}{Time} & \multicolumn{4}{c|}{Non-uniformity} \ \cline{4-10}
\multicolumn{1}{l|}{} & \multicolumn{2}{c|}{} & \multicolumn{1}{c|}{1} & \multicolumn{1}{l|}{2} & 3 & \multicolumn{1}{c|}{1} & \multicolumn{1}{c|}{2} & \multicolumn{1}{c|}{3} & 4 \ \hline
\multirow{3}{*}{\begin{tabular}[c]{@{}c@{}}Single-\ part\end{tabular}} & \multicolumn{2}{l|}{x} & \multicolumn{3}{l|}{} & \multicolumn{3}{c|}{} & \ \cline{2-10}
& \multicolumn{2}{l|}{y} & \multicolumn{3}{l|}{} & \multicolumn{3}{c|}{} & \ \cline{2-10}
& \multicolumn{2}{l|}{z} & \multicolumn{3}{l|}{} & \multicolumn{3}{c|}{} & \multicolumn{1}{l|}{} \ \hline
\end{tabular}}
\end{table}
\end{document}




\resizeboxbecause you will have inconsistent rule widths. – F. Pantigny Aug 12 '22 at 12:06\resizebox{\textwidth}{!}{%there is no possibility of getting reasonable output if you scale each table by a different arbitrary value. – David Carlisle Aug 12 '22 at 14:08