Auto Adding Classes to H1's and H2's

I don’t suppose anyone knows of a way a person can assign a CSS class (using <span> or something) to the FIRST word in every H1 or H2 tags?

I’m using Genesis btw if that makes things easier.