It's the cat in the hat. The cat wearing the hat. Not a kitty curled up snug inside some sombrero.
Like the girl in the bikini. The man in the grey flannel suit. Or better, men in black. The woman in Chanel. In fashion.
Dr Seuss's cat in the hat wears a hat. He at no time sits inside a giant fedora; he does not jump out of a prop panama. The hat he wears is silly, but it sits atop his head.
Of course, commercials are now running for the live-action version of The Cat in the Hat. The French version title is Le Chat dans le chapeau. Who tranlates this stuff? The cat is not literally in a hat — it's an idiomatic usage of the preposition "in."
The cat wearing the hat. The cat with the hat.
Le Chat au chapeau. That's what they mean.