I don't know the history of the hankies and their colors, but I've always found them a fascinating method of communication.
As if the color isn't enough to try and remember, don't forget that which side you put the hanky in has meaning too!
Left = Top
Right = Bottom
Red is for Fisting
Blue is for Fucking
Yellow is for WaterSports
Green is for Hustling
Olive is for Military
Gray is for Bondange
Orange is for Anything
Mustard is for 8" or More
Brown is for Scat
Black is for S/M
White is for Masturbating
Pink is for Dildos
Gold is for Group Sex
Purple is for Piercing
Magenta is for Armpits
Charcoal is for Latex