#showtooltip will inherit from the cast etc. the macro is executing. You can also specify spells on the tooltip itself if you want to override the default display.
/cancelform takes you out of all forms.
Potentially. You often run into race conditions with shapeshifting.
Further reading:
As for the template I’d recommend you use
#showtooltip SPELL
/cast [noform:1] Bear Form
/cast SPELL
/startattack
1 is traditionally Bear, 2 is traditionally Cat, but the numbers will match the order they appear on your form bar.
Also, be aware that cat and bear form have their own bar 1 so what you’re intending to do may not necessarily work out how you want it to.
Personally, I use a dedicated button for all my combat forms and a second one for my movement/tavel forms/mount