2

To illustrate the movement of a horse on a chessboard, I used the following commands. How to eliminate the square that appears to the right of the figure?enter image description here

enter image description here

benedito
  • 4,600

1 Answers1

5

That's the chessboard package but there's a mistake in the code with style=4x4. Not sure of the specifics but it compiled after I made it pgfstyle. After fixing that it's just a matter of setting showmover=false for the second board as well. The box indicates whose turn it is to move and your code had it turned off for the first diagram but not the second.

\documentclass[11pt]{article}
\usepackage{chessboard}
\begin{document}
\begin{center}
\storechessboardstyle{8x8}{maxfield=d8}
\chessboard[pgfstyle=4x4,setwhite={Nd4,Ne6,Nf3,Nb3,Nc2,Nc6,Nb5,Ne2,Nf5},showmover=false]
\chessboard[pgfstyle=straightmove,arrow=to,linewidth=0.2ex,color=red,pgfstyle=knightmove,markmoves={d4-e6,d4-f3,d4-b3,d4-c2,d4-c6,d4-b5,d4-e2,d4-f5},shortenstart=1ex,showmover=false]
\end{center}
\end{document}
DJP
  • 12,451