optimizing printing