Some IDE can do that automatically. (Some even have features like "smart tabs" that uses tabs and spaces in a way that wouldn't mess things up with different settings).
But I'm not in any way forcing you to reformat the whole code.