diff options
| author | tassaron | 2017-05-30 19:31:10 -0400 |
|---|---|---|
| committer | tassaron | 2017-05-30 19:31:10 -0400 |
| commit | ca7e8bdb0dc998088aeb45a77987a78cc4656b34 (patch) | |
| tree | 8f41e662740fcbb17dd2a38b5af6764429fd8a77 /components/original.py | |
| parent | 7240f25deb21db365f39d00c50eb07d41dc4c797 (diff) | |
the most simple way of saving dictionaries
Diffstat (limited to 'components/original.py')
| -rw-r--r-- | components/original.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/components/original.py b/components/original.py index 47e53b8..40f51eb 100644 --- a/components/original.py +++ b/components/original.py @@ -32,11 +32,13 @@ class Component(__base__.Component): self.visColor = self.RGBFromString(self.page.lineEdit_visColor.text()) self.parent.drawPreview() - def version(self): - return 1 + def loadPreset(self, presetDict): + self.preFrameRender(**presetDict) def savePreset(self): - return {} + return { 'layout' : self.page.comboBox_visLayout.currentIndex(), + 'visColor' : self.page.lineEdit_visColor.text(), + } def previewRender(self, previewWorker): spectrum = numpy.fromfunction(lambda x: 0.008*(x-128)**2, (255,), dtype="int16") |
