I am able to adjust properties like PaperLength, PaperWidth and Orientation using below code snippet. But I am unable to find a way to do something similar with respect to print speed and darkness adjustments.
import win32print
pHandle = win32print.OpenPrinter(str(self.printername.get()))
properties = win32print.GetPrinter(pHandle, 2)
pDevModeObj = properties["pDevMode"]
pDevModeObj.Orientation = DMORIENT_PORTRAIT
pDevModeObj.PaperLength = int(Length) # Variable
pDevModeObj.PaperWidth = int(Width) # Variable
I have checked a similar post but it has not helped fully. Python win32print changing advanced printer options