When you type fn+2 you get "2". So you can keep your tab macro but still use the numbers if needed.
By the way, noisneil has created a macro which solves the problem even more elegantly (without "fn). "Type "J" or Do Something Else." Just replace "J" with "2."
I stand by my original position; don't use single character keys as triggers in apps you'll be typing in.
However, it's a free country/world, so here's a macro along the lines of what @Frankb is referring to.
It types 1, 2, 3 or 4 when those keys are tapped. When they're held for slightly longer, they perform actions. The timeout that determines the length of a 'long press' is quite short by default, so it still feels nice and snappy. Replace the red comment actions with whatever you want them to do.
Side-note: @peternlewis, it would be really handy if you could click the disclosure triangle of one action in a Switch/Case group while holding a modifier (maybe ⌃⌥?) to disclose all actions it contains.
He was hoping to be able to tap for both functions, but that's not really doable, so I figured a long-press for the tab switch made more sense than for typing.
There was another thread that discussed this that you might want to look at. It starts with expanding/collapsing just Comment actions and then moves on to doing the same for all actions. You can find it here: