Whenever in the trial of any criminal case it shall be necessary or proper to prove the signature of any person, it shall be competent to introduce in evidence for the purpose of comparison, any specimen or specimens of the handwriting or signature of such person, admitted or proved to the satisfaction of the court to be genuine, whether or not the paper on which such handwriting or signature appears is one in evidence or connected with the case or not.