This question is a follow up to my previous question:
Is it possible to use > and < to pipe opening and closing braces on each side of a cell's content? To be more specific, what I want is to define the following column:
\newcolumntype{P}{>{\leavevmode\kern-\tabcolsep\bfseries\parbox[t]{\hsize}{}X<{}}}
I want a column type that automatically embraces the cell content in a \parbox.
I enclose a short MNWE:
\documentclass[table]{article}
\usepackage{lmodern, microtype, xcolor, tabularx, tabulary}
\begin{document}
\begin{tabularx}{0.5\columnwidth}{>{\raggedright\arraybackslash\leavevmode\kern-\tabcolsep\parbox[t]{\hsize}{ }X<{}}XX<{\leavevmode\kern-\tabcolsep\raggedleft\arraybackslash}}
\rowcolor{lightgray}All this testing is not so funny&test&test\\\hline
testing, testing and even more testing &test&test\\
\rowcolor{lightgray}I want to write a noce table in a simple way&test&test\\
\end{tabularx}
\end{document}

Xcolumn type is based on ˙\parboxes. Why you like to add them again? If you have some reason to do this, it might be better to use\minipage(on left side)\endminipge` (on the right side of column type) – Zarko Aug 18 '19 at 15:31parbox(see Bernard's answer to the referred question).minipageadd top spacing, which then needs to be cancelled and complicated the column definition even more. After posting the question, I remembered the package collcell, which probably will do want I want. – Sveinung Aug 18 '19 at 15:38