Loose batteries in your pocket not connected to anything should not demagnetize a credit card. But batteries should not be carried around loose next to metal objects including other batteries or coins because a short circuit could occur.
I usually put transparent tape over my signature but not over the magnetic stripe. This was originally to keep the signature area from becoming too dirty but also keeps "void" from showing through.
Travel tips:
http://members.aol.com/ajaynejr/travel.htm