some format handling tweaks