Move the code of getting printing settings to another class.