You can use the key rectangle split empty part height to set the height of empty parts. However, this key only adds a a invisible rule with the given height to an internal macro. Therefore the height can't be reduced once set. The default value is 1ex. The overwrite this use the key rectangle split every empty part={} which deletes all previous set height, depth and width values.
The inner sep value is still added around the empty part which makes it very difficult to make it smaller without reducing this value.
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{shapes}
\begin{document}
\begin{tikzpicture}
\node[rectangle split,rectangle split parts=3,draw] {
XgX
\nodepart{second}
\nodepart{third}
XgX
};
\end{tikzpicture}
\begin{tikzpicture}
\node[rectangle split,rectangle split parts=3,inner sep=0pt,
rectangle split every empty part={},% delete existing height, depth and width
rectangle split empty part height=0.1cm,
draw] {
XgX
\nodepart{second}%
\nodepart{third}
XgX
};
\end{tikzpicture}
\end{document}
Package pgfkeys Error: I do not know the key '/tikz/rectangle split every empty part' and I am going to ignore it. Perhaps you misspelled it.Any ideas? – yegor256 Feb 22 '11 at 19:02