Improving print functionality