This trick is performed with a small stick having a loop attached that is too small for the stick to pass through.
Spread out the string and place it each side of the buttonhole, then draw the cloth around the hole through the string until it is far enough to pass the stick through the hole. Pull back the cloth and you have the string looped in the hole with a hitch the same as if the stick had been passed through the string.
The stick may be removed by pulling up the loop as if you were passing the stick through it, putting the stick in the hole and leaving the string on the outside, then spread the string, pulling up the cloth and passing the stick through the hole as before