replaced platform-dependent commands like windows() with dev.new()