From a1e9b55591a5ae4cf145860010add6b4b01566d3 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sun, 18 Jul 2021 20:40:36 +0530 Subject: [PATCH] When using tablet profile dont override scale_news_images --- recipes/boston.com.recipe | 1 + src/calibre/web/feeds/news.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/recipes/boston.com.recipe b/recipes/boston.com.recipe index 5d93ff1b2c..d3af09a604 100644 --- a/recipes/boston.com.recipe +++ b/recipes/boston.com.recipe @@ -119,6 +119,7 @@ class BostonGlobeSubscription(BasicNewsRecipe): remove_tags_after = dict(attrs={'class': lambda x:x and x.startswith('body |')}) remove_attributes = ['style'] no_stylesheets = True + scale_news_images = 1600, 1200 # simultaneous_downloads = 1 def image_url_processor(self, baseurl, url): diff --git a/src/calibre/web/feeds/news.py b/src/calibre/web/feeds/news.py index 4e6568d153..47f059fe9c 100644 --- a/src/calibre/web/feeds/news.py +++ b/src/calibre/web/feeds/news.py @@ -946,7 +946,7 @@ class BasicNewsRecipe(Recipe): for reg in self.filter_regexps: web2disk_cmdline.extend(['--filter-regexp', reg]) - if options.output_profile.short_name == 'default': + if options.output_profile.short_name in ('default', 'tablet'): self.scale_news_images_to_device = False elif self.scale_news_images_to_device: self.scale_news_images = options.output_profile.screen_size