How to tip your cap
It’s such a simple gesture — a tip of the cap. Nobody knows for sure, but it seems to have evolved from the ancient custom of a soldier taking off his helmet when coming upon a friend on the battlefield. The gesture was meant as a sign of respect: “A man,” Brewer’s Dictionary of Phrase and Fable says, “takes off his hat to show he dares stand unarmed in your presence.”