The problem is local on $B$. Thus we may assume $B$ is quasi-compact. By Decent Spaces, Lemma \ref{decent-spaces-lemma-locally-Noetherian-decent-quasi-separated} we see $B$ is quasi-separated. By Limits of Spaces, Proposition \ref{spaces-limits-proposition-there-is-a-scheme-finite-over} we can choose a finite surjective morphism $\pi : Y \to X$ where $Y$ is a scheme. Claim: $\delta_Y$ is a dimension function. \medskip\noindent The claim implies the lemma. With $X \to B$ as in the lemma set $Z = Y \times_B X$ with projections $p : Z \to Y$ and $q : Z \to X$. Then we have $$ \delta_Z(z) = \delta_Y(p(z)) + \text{transcendence degreeof }z/p(z) $$ and $\delta_Z(z) = \delta_X(q(z))$. This follows from Morphisms of Spaces, Lemma  \ref{spaces-morphisms-lemma-dimension-fibre-at-a-point-additive} and the fact that these transcendence degrees are zero for finite morphisms. By Decent Spaces, Lemma \ref{decent-spaces-lemma-scheme-with-dimension-function} and the claim we find that $\delta_Z$ is a dimension function. Then we find that $\delta_X$ is a dimension function by Decent Spaces, Lemma \ref{decent-spaces-lemma-check-dimension-function-finite-cover}. \medskip\noindent Proof of the claim. Consider a specialization $y \leadsto y'$, $y \not = y'$ of points of the Noetherian scheme $Y$. Then $\delta_Y(y) > \delta_Y(y')$ because there are no specializations between points in fibres of $Y$ (see Decent Spaces, Lemma \ref{decent-spaces-lemma-conditions-on-fibre-and-qf}). Using this for a chain of specializations we find $$ \delta_Y(y) - \delta_Y(y') \geq \text{codim}(\overline{\{y'\}}, \overline{\{y\}}) $$ Our task is to show equality. By Properties, Lemma \ref{properties-lemma-locally-Noetherian-closed-point} we can choose a specialization $y' \leadsto y_0$. It suffices to show $\delta_Y(y) - \delta_Y(y_0) = \text{codim}(\overline{\{y_0\}}, \overline{\{y\}})$ because this will imply the equality for both $y \leadsto y'$ and $y' \leadsto y_0$. \medskip\noindent Choose a maximal chain $y = y_c \leadsto y_{c - 1} \leadsto \ldots \leadsto y_0$ of specializations in $Y$. Set $b = \pi(y)$ and $b_0 = \pi(y_0)$. Choose a maximal chain $b = b_e \leadsto b_{e - 1} \leadsto \ldots \leadsto b_0$ of specializations in $|B|$. We have to show $e = c$. Since $\pi$ is closed (Morphisms of Spaces, Lemma \ref{spaces-morphisms-lemma-finite-proper}) we can find a sequence of specializations $y = y'_e \leadsto y'_{e - 1} \leadsto \ldots \leadsto y'_0$ mapping to $b = b_e \leadsto b_{e - 1} \leadsto \ldots \leadsto b_0$. Observe that $y'_e \leadsto y'_{e - 1} \leadsto \ldots \leadsto y'_0$ is a maximal chain as well. If $y_0 = y'_0$, then because $Y$ is catenary, we conclude that $e = c$ as desired. In the next paragraph we reduce to this case by sleight of hand and we conclude in the same manner. \medskip\noindent Since $\pi$ is closed we see that $b_0$ is a closed point of $|B|$. By Decent Spaces, Lemma \ref{decent-spaces-lemma-decent-space-closed-point} we can represent $b_0$ by a closed immersion $b_0 : \Spec(k) \to B$. By Lemma \ref{lemma-construct-glueing} we can find a factorization $$ Y \to Y' \to X $$ with $\pi' : Y' \to X$ finite and $Y \to Y'$ a morphism which map $y_0$ and $y'_0$ to the same point and is an isomorphism away from the inverse image of $b_0$. (Of course $Y'$ won't be a scheme but this doesn't matter for the argument that follows.) Clearly the maximal chains of specializations $y_c \leadsto y_{c - 1} \leadsto \ldots \leadsto y_0$ and $y'_e \leadsto y'_{e - 1} \leadsto \ldots \leadsto y'_0$ map to maximal chains of specializations in $Y'$ having the same start and end. Since $B$ is universally catenary, we see that $|Y'|$ is catenary and we conclude as before.