
私は垂直中央揃えのテーブルセルを使用して を使用します$\vcenter{\hbox{#1}}$
。結果は問題ありませんが、
ここで追加のスペースを取得するにはどうすればよいでしょうか。
これは完全に任意のテーブルであり、内容、幅、高さ、h ライン、v ラインなどがいつでも変更される可能性があることに注意してください。ケースバイケースで 0pt ルールを追加するなどの個別の調整は望ましくありません。
\documentclass[]{article}
%\usepackage{booktabs, array}
% \setlength{\defaultaddspace}{0pt}
%\setlength{\extrarowheight}{10mm}
% \renewcommand{\arraystretch}{2.9}
\usepackage{pgfplotstable}
\pgfplotsset{compat=newest}
\pgfplotstableset{
string type, col sep=comma, header=false,
column type/.add={|}{|},
assign column name/.style={
/pgfplots/table/column name={\textbf{#1}}
},
% vertical (help) lines
every head row/.style={before row=\hline},
every even row/.style={before row=\hline, after row=\hline},
every last row/.style={after row=\hline},
}
\begin{document}
\pgfplotstableread[]{
a, abc abc abc, c
{\tiny a}, b, {\Huge C}
T, {2}, {\rule{50pt}{30pt}}
, b, c
}\mytable
\pgfplotstabletypeset[
every column/.style={
postproc cell content/.style={@cell content=$\vcenter{\hbox{##1}}$} },
]{\mytable}
\end{document}
答え1
中央のボックス内にパディング(例えば2pt)を追加することができます
$\vcenter{\vskip2pt\hbox{##1}\vskip2pt}$