Looking at the implementation of interact.SaveFontPreferences this almost certainly meant to use the variables in interact. Although these still fail because calling self.GetFormat results in AttributeError: 'PyCPropertyPage' object has no attribute 'GetFormat':
>>> from pywin.dialogs import ideoptions; ideoptions.OptionsPropPage().OnFormatInput(None,None)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Program Files\Python39\lib\site-packages\Pythonwin\pywin\dialogs\ideoptions.py", line 122, in OnFormatInput
fmt = self.GetFormat(formatInput)
File "C:\Program Files\Python39\lib\site-packages\Pythonwin\pywin\mfc\object.py", line 24, in __getattr__
return getattr(o, attr)
AttributeError: 'PyCPropertyPage' object has no attribute 'GetFormat'
For all I know these methods might always have been broken in the past 25 years. At least this allows us to turn on reportUnboundVariable in pyright.
Looking at the implementation of
interact.SaveFontPreferences
this almost certainly meant to use the variables ininteract
. Although these still fail because callingself.GetFormat
results inAttributeError: 'PyCPropertyPage' object has no attribute 'GetFormat'
:For all I know these methods might always have been broken in the past 25 years. At least this allows us to turn on
reportUnboundVariable
in pyright.