Well, showing affection is rubbing against something even after its been claimed as its territory. Headbutting from the cat means they are being affectionate, as well as slow uncurling of the tail. What the cat is doing, touching his nose and scenting the woman's face is checking for other scents. He then marks her.
A cat is very aware of what it's doing. When marking a human or another animal, it's with affectionate intentions as long as it's using its facial glands to mark you. If it's just barely touching you with the tip of its tail while walking past you, it's more of a typical territorial or even aggressive marking.