Ensure text_font is from our list and correctly spelled.
(self)
| 9044 | return f'Widget:(field_type={self.field_type_string} script={self.script})' |
| 9045 | |
| 9046 | def _adjust_font(self): |
| 9047 | """Ensure text_font is from our list and correctly spelled. |
| 9048 | """ |
| 9049 | if not self.text_font: |
| 9050 | self.text_font = "Helv" |
| 9051 | return |
| 9052 | valid_fonts = ("Cour", "TiRo", "Helv", "ZaDb") |
| 9053 | for f in valid_fonts: |
| 9054 | if self.text_font.lower() == f.lower(): |
| 9055 | self.text_font = f |
| 9056 | return |
| 9057 | self.text_font = "Helv" |
| 9058 | return |
| 9059 | |
| 9060 | def _checker(self): |
| 9061 | """Any widget type checks. |