You can paint them attached, but it is not easy.
You can, but I wouldn't. Are your cabinets paint grade or stain grade wood?
Don't forget to lightly sand with 220 grit and tack cloth, followed by good quality primer, prior to painting. Each coat will require a long dry time to avoid smudges, etc.
You can but easier to paint with them off. Just a pain to paint them with them on.