Updated GUI

Plus small notquantize tweaks.
This commit is contained in:
Paweł Jastrzębski committed 2013-03-05 23:41:48 +01:00
1 parent b162425e52
commit 718af10be7
3 files changed
+30 -39

No files matched your search

+2 -2
View File
@@ -111,12 +111,12 @@ class ComicPage:
raise RuntimeError('Cannot read image file %s' % source)
self.image = self.image.convert('RGB')
def saveToDir(self, targetdir):
def saveToDir(self, targetdir, notquantize):
filename = os.path.basename(self.origFileName)
try:
self.image = self.image.convert('L') # convert to grayscale
os.remove(os.path.join(targetdir,filename))
if options.notquantize:
if notquantize:
self.image.save(os.path.join(targetdir, os.path.splitext(filename)[0] + ".jpg"), "JPEG")
else:
self.image.save(os.path.join(targetdir, os.path.splitext(filename)[0] + ".png"), "PNG")