diff --git a/src/calibre/customize/profiles.py b/src/calibre/customize/profiles.py index 36e2b9bdd2..2318c6724e 100644 --- a/src/calibre/customize/profiles.py +++ b/src/calibre/customize/profiles.py @@ -678,6 +678,15 @@ class NookOutput(OutputProfile): fbase = 16 fsizes = [12, 12, 14, 16, 18, 20, 22, 24] +class NookColorOutput(NookOutput): + name = 'Nook Color' + short_name = 'nook_color' + description = _('This profile is intended for the B&N Nook Color.') + + screen_size = (600, 980) + comic_screen_size = (584, 980) + dpi = 169 + class BambookOutput(OutputProfile): author = 'Li Fanxi' @@ -698,6 +707,6 @@ output_profiles = [OutputProfile, SonyReaderOutput, SonyReader300Output, iPadOutput, KoboReaderOutput, TabletOutput, SonyReaderLandscapeOutput, KindleDXOutput, IlliadOutput, IRexDR1000Output, IRexDR800Output, JetBook5Output, NookOutput, - BambookOutput, ] + BambookOutput, NookColorOutput] output_profiles.sort(cmp=lambda x,y:cmp(x.name.lower(), y.name.lower())) diff --git a/src/calibre/gui2/wizard/__init__.py b/src/calibre/gui2/wizard/__init__.py index 2ac0908ea9..e2f463b80b 100644 --- a/src/calibre/gui2/wizard/__init__.py +++ b/src/calibre/gui2/wizard/__init__.py @@ -38,6 +38,7 @@ class Device(object): name = 'Default' manufacturer = 'Default' id = 'default' + supports_color = False @classmethod def set_output_profile(cls): @@ -56,6 +57,12 @@ class Device(object): def commit(cls): cls.set_output_profile() cls.set_output_format() + if cls.supports_color: + from calibre.ebooks.conversion.config import load_defaults, save_defaults + recs = load_defaults('comic_input') + recs['dont_grayscale'] = True + save_defaults('comic_input', recs) + class Kindle(Device): @@ -138,6 +145,12 @@ class Nook(Sony505): manufacturer = 'Barnes & Noble' output_profile = 'nook' +class NookColor(Nook): + id = 'nook_color' + name = 'Nook Color' + output_profile = 'nook_color' + supports_color = True + class CybookG3(Device): name = 'Cybook Gen 3' @@ -178,6 +191,7 @@ class iPhone(Device): output_format = 'EPUB' manufacturer = 'Apple' id = 'iphone' + supports_color = True class Android(Device): @@ -185,6 +199,7 @@ class Android(Device): output_format = 'EPUB' manufacturer = 'Android' id = 'android' + supports_color = True class HanlinV3(Device): @@ -354,11 +369,6 @@ class StanzaPage(QWizardPage, StanzaUI): return FinishPage.ID def commit(self): - from calibre.ebooks.conversion.config import load_defaults, save_defaults - recs = load_defaults('comic_input') - recs['dont_grayscale'] = True - save_defaults('comic_input', recs) - p = self.set_port() if p is not None: from calibre.library.server import server_config