Settings used by the HTML export feature.
| 285 | |
| 286 | |
| 287 | class HTMLExportSettings: |
| 288 | """ |
| 289 | Settings used by the HTML export feature. |
| 290 | """ |
| 291 | _instance = None |
| 292 | |
| 293 | @classmethod |
| 294 | def getInstance(cls): |
| 295 | if cls._instance is None: |
| 296 | cls._instance = HTMLExportSettings() |
| 297 | |
| 298 | return cls._instance |
| 299 | |
| 300 | def __init__(self): |
| 301 | serviceHTMLExportDefaultSettings = { |
| 302 | "path" : config.savePath + os.sep + 'pyfaFits.html', |
| 303 | "minimal": False |
| 304 | } |
| 305 | self.serviceHTMLExportSettings = SettingsProvider.getInstance().getSettings( |
| 306 | "pyfaServiceHTMLExportSettings", |
| 307 | serviceHTMLExportDefaultSettings |
| 308 | ) |
| 309 | |
| 310 | def getMinimalEnabled(self): |
| 311 | return self.serviceHTMLExportSettings["minimal"] |
| 312 | |
| 313 | def setMinimalEnabled(self, minimal): |
| 314 | self.serviceHTMLExportSettings["minimal"] = minimal |
| 315 | |
| 316 | def getPath(self): |
| 317 | return self.serviceHTMLExportSettings["path"] |
| 318 | |
| 319 | def setPath(self, path): |
| 320 | self.serviceHTMLExportSettings["path"] = path |
| 321 | |
| 322 | |
| 323 | class UpdateSettings: |