Example of what it will look like: http://imsanctuary.info/rainbow.html
I've only tested this on IPB 3.4.2, but I'm sure it will work with earlier version and later versions. Let me know if it doesn't though.
Step 1) Go to your ACP > Look & Feel > Your Skin > globalTemplate.
Place the following code near the bottom of your globalTemplate. I put mine above the <!-- ::: Footer ::: --> part of the globalTemplate.
The code:
Once you put that code somewhere in there, click 'Save', then head over to Members > Member Groups > Manage Member Groups.
Click on the group you want to use the rainbow username style on.
For the group prefix, use this:
<span name="Rainbow">
For the group sufix, use this:
</span>
Click on 'Complete Edit' and you're done!
Enjoy!