\begin{tikzpicture}
 \tkzInit[xmax=3, ymax=3]
 \tkzGrid
 \tkzAxeXY
 \tkzClip
 \draw[red] (-1,-1)--(5,5);
\end{tikzpicture}
