From 67427f215fb51cbb6ff232b3f6201bfcca75fc52 Mon Sep 17 00:00:00 2001 From: bashrc Date: Sun, 26 Jul 2026 14:43:35 +0100 Subject: [PATCH] Option to apply dithering to uploaded images --- epicyon.py | 22 +++++++- src/daemon_post_question.py | 4 +- src/daemon_post_receive.py | 46 +++++++++++++-- src/desktop_client.py | 18 ++++-- src/inbox.py | 2 + src/media.py | 5 +- src/newsdaemon.py | 3 +- src/posts.py | 43 +++++++++++++- src/sendC2S.py | 3 +- src/tests.py | 109 +++++++++++++++++++++++++++--------- src/webapp_create_post.py | 6 ++ translations/ar.json | 3 +- translations/bn.json | 3 +- translations/ca.json | 3 +- translations/cy.json | 3 +- translations/de.json | 3 +- translations/el.json | 3 +- translations/en.json | 3 +- translations/es.json | 3 +- translations/fa.json | 3 +- translations/fi.json | 3 +- translations/fr.json | 3 +- translations/ga.json | 3 +- translations/he.json | 3 +- translations/hi.json | 3 +- translations/it.json | 3 +- translations/ja.json | 3 +- translations/ko.json | 3 +- translations/ku.json | 3 +- translations/nl.json | 3 +- translations/oc.json | 3 +- translations/pl.json | 3 +- translations/pt.json | 3 +- translations/ru.json | 3 +- translations/sw.json | 3 +- translations/tr.json | 3 +- translations/uk.json | 3 +- translations/yi.json | 3 +- translations/zh.json | 3 +- 39 files changed, 267 insertions(+), 78 deletions(-) diff --git a/epicyon.py b/epicyon.py index 477d81ac7..d90b14fb5 100644 --- a/epicyon.py +++ b/epicyon.py @@ -514,6 +514,11 @@ def _command_options() -> None: type=str2bool, nargs='?', const=True, default=True, help="Enable replies to a post") + parser.add_argument("--ditherImage", "--dither", + dest='ditherImage', + type=str2bool, nargs='?', + const=True, default=False, + help="Whether to dither the attached image") parser.add_argument("--dav", dest='dav', type=str2bool, nargs='?', @@ -2093,7 +2098,9 @@ def _command_options() -> None: domain, port, to_nickname, to_domain, to_port, cc_url, http_prefix, send_message, - argb.commentsEnabled, attach, media_type, + argb.commentsEnabled, + argb.ditherImage, + attach, media_type, attached_image_description, video_transcript, city, cached_webfingers, person_cache, is_article, @@ -3949,9 +3956,10 @@ def _command_options() -> None: delete_all_posts(base_dir, nickname, domain, 'inbox') delete_all_posts(base_dir, nickname, domain, 'outbox') - test_save_to_file = True + test_save_to_file: bool = True test_c2s: bool = False - test_comments_enabled = True + test_comments_enabled: bool = True + test_apply_dithering: bool = False test_attach_image_filename = None test_media_type = None test_image_description = None @@ -3983,6 +3991,7 @@ def _command_options() -> None: test_save_to_file, test_c2s, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, test_city, @@ -4002,6 +4011,7 @@ def _command_options() -> None: test_save_to_file, test_c2s, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, test_city, @@ -4021,6 +4031,7 @@ def _command_options() -> None: test_save_to_file, test_c2s, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, test_city, @@ -4040,6 +4051,7 @@ def _command_options() -> None: test_save_to_file, test_c2s, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, test_city, @@ -4060,6 +4072,7 @@ def _command_options() -> None: test_save_to_file, test_c2s, test_comments_enabled, + test_apply_dithering, 'img/logo.png', 'image/png', 'Description of image', test_video_transcript, test_city, @@ -4079,6 +4092,7 @@ def _command_options() -> None: test_save_to_file, test_c2s, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, test_city, @@ -4098,6 +4112,7 @@ def _command_options() -> None: test_save_to_file, test_c2s, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, test_city, @@ -4117,6 +4132,7 @@ def _command_options() -> None: test_save_to_file, test_c2s, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, test_city, diff --git a/src/daemon_post_question.py b/src/daemon_post_question.py index 660cad8e9..ecff8dce5 100644 --- a/src/daemon_post_question.py +++ b/src/daemon_post_question.py @@ -214,7 +214,8 @@ def _send_reply_to_question(self, base_dir: str, print('Voting on message ' + message_id) print('Vote for: ' + answer) - comments_enabled = True + comments_enabled: bool = True + apply_dithering: bool = False attach_image_filename = None media_type = None image_description = None @@ -251,6 +252,7 @@ def _send_reply_to_question(self, base_dir: str, mentions_str + ' ' + answer, False, False, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, diff --git a/src/daemon_post_receive.py b/src/daemon_post_receive.py index 05d79a5bd..b7a26786a 100644 --- a/src/daemon_post_receive.py +++ b/src/daemon_post_receive.py @@ -84,6 +84,7 @@ def _receive_new_post_process_newpost(self, fields: {}, content_license_url: str, mentions_str: str, comments_enabled: bool, + apply_dithering: bool, filename: str, attachment_media_type: str, low_bandwidth: bool, @@ -182,6 +183,7 @@ def _receive_new_post_process_newpost(self, fields: {}, http_prefix, mentions_str + fields['message'], False, False, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], video_transcript, @@ -287,6 +289,7 @@ def _receive_new_post_process_newblog(self, fields: {}, http_prefix: str, person_cache: {}, content_license_url: str, comments_enabled: bool, + apply_dithering: bool, filename: str, attachment_media_type: str, low_bandwidth: bool, @@ -364,6 +367,7 @@ def _receive_new_post_process_newblog(self, fields: {}, domain, port, http_prefix, fields['message'], save_to_file, client_to_server, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], video_transcript, city, @@ -414,7 +418,8 @@ def _receive_new_post_process_editblog(self, fields: {}, attachment_media_type: str, low_bandwidth: bool, yt_replace_domain: str, - twitter_replacement_domain: str) -> int: + twitter_replacement_domain: str, + apply_dithering: bool) -> int: """Edited blog post has been received and is then sent to the outbox """ print('Edited blog post received') @@ -498,7 +503,7 @@ def _receive_new_post_process_editblog(self, fields: {}, city, low_bandwidth, license_url, creator, fields['languagesDropdown'], - debug) + debug, apply_dithering) replace_you_tube(post_json_object, yt_replace_domain, @@ -533,6 +538,7 @@ def _receive_new_post_process_newunlisted(self, fields: {}, content_license_url: str, port: int, mentions_str: str, comments_enabled: bool, + apply_dithering: bool, filename: str, attachment_media_type: str, low_bandwidth: bool, @@ -615,6 +621,7 @@ def _receive_new_post_process_newunlisted(self, fields: {}, mentions_str + fields['message'], save_to_file, client_to_server, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], video_transcript, @@ -707,6 +714,7 @@ def _receive_new_post_process_newfollowers(self, fields: {}, person_cache: {}, content_license_url: str, port: int, comments_enabled: bool, + apply_dithering: bool, filename: str, attachment_media_type: str, low_bandwidth: bool, @@ -795,6 +803,7 @@ def _receive_new_post_process_newfollowers(self, fields: {}, save_to_file, client_to_server, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], video_transcript, @@ -891,6 +900,7 @@ def _receive_new_post_process_newdm(self, fields: {}, person_cache: {}, content_license_url: str, port: int, comments_enabled: str, + apply_dithering: bool, filename: str, attachment_media_type: str, low_bandwidth: bool, @@ -986,6 +996,7 @@ def _receive_new_post_process_newdm(self, fields: {}, save_to_file, client_to_server, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], @@ -1135,6 +1146,7 @@ def _receive_new_post_process_newreminder(self, fields: {}, nickname: str, save_to_file: bool = False client_to_server: bool = False comments_enabled: bool = False + apply_dithering: bool = False conversation_id = None convthread_id = None mentions_message = mentions_str + fields['message'] @@ -1164,6 +1176,7 @@ def _receive_new_post_process_newreminder(self, fields: {}, nickname: str, save_to_file, client_to_server, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], video_transcript, @@ -1287,11 +1300,14 @@ def _receive_new_post_process_newreport(self, fields: {}, video_transcript: str = '' if fields.get('videoTranscript'): video_transcript = fields['videoTranscript'] + comments_enabled: bool = True + apply_dithering: bool = False message_json = \ create_report_post(base_dir, nickname, domain, port, http_prefix, mentions_str + fields['message'], - False, False, True, + False, False, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], video_transcript, @@ -1321,6 +1337,7 @@ def _receive_new_post_process_newquestion(self, fields: {}, content_license_url: str, port: int, comments_enabled: bool, + apply_dithering: bool, filename: str, attachment_media_type: str, low_bandwidth: bool, @@ -1394,6 +1411,7 @@ def _receive_new_post_process_newquestion(self, fields: {}, fields['message'], q_options, False, False, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], video_transcript, @@ -1428,6 +1446,7 @@ def _receive_new_post_process_newreading(self, fields: {}, domain: str, port: int, mentions_str: str, comments_enabled: bool, + apply_dithering: bool, filename: str, attachment_media_type: str, low_bandwidth: bool, @@ -1531,6 +1550,7 @@ def _receive_new_post_process_newreading(self, fields: {}, fields['bookurl'], book_rating, False, False, comments_enabled, + apply_dithering, filename, attachment_media_type, fields['imageDescription'], video_transcript, @@ -2117,6 +2137,10 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, comments_enabled: bool = False else: comments_enabled: bool = True + if not fields.get('ditherImage'): + apply_dithering: bool = False + else: + apply_dithering: bool = True buy_url: str = '' if fields.get('buyUrl'): @@ -2136,6 +2160,7 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, content_license_url, mentions_str, comments_enabled, + apply_dithering, filename, attachment_media_type, low_bandwidth, @@ -2187,7 +2212,9 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, cookie, calling_domain, http_prefix, person_cache, content_license_url, - comments_enabled, filename, + comments_enabled, + apply_dithering, + filename, attachment_media_type, low_bandwidth, buy_url, chat_url, @@ -2205,7 +2232,8 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, attachment_media_type, low_bandwidth, yt_replace_domain, - twitter_replacement_domain) + twitter_replacement_domain, + apply_dithering) if post_type == 'newunlisted': return _receive_new_post_process_newunlisted( self, fields, @@ -2217,6 +2245,7 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, content_license_url, port, mentions_str, comments_enabled, + apply_dithering, filename, attachment_media_type, low_bandwidth, @@ -2267,6 +2296,7 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, person_cache, content_license_url, port, comments_enabled, + apply_dithering, filename, attachment_media_type, low_bandwidth, @@ -2315,6 +2345,7 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, person_cache, content_license_url, port, comments_enabled, + apply_dithering, filename, attachment_media_type, low_bandwidth, @@ -2424,7 +2455,9 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, self, fields, city, base_dir, nickname, domain, domain_full, http_prefix, person_cache, content_license_url, - port, comments_enabled, filename, + port, comments_enabled, + apply_dithering, + filename, attachment_media_type, low_bandwidth, translate, auto_cw_cache, debug, project_version, curr_session, @@ -2441,6 +2474,7 @@ def _receive_new_post_process(self, post_type: str, path: str, headers: {}, domain, port, mentions_str, comments_enabled, + apply_dithering, filename, attachment_media_type, low_bandwidth, diff --git a/src/desktop_client.py b/src/desktop_client.py index 8477c7a24..202a3610a 100644 --- a/src/desktop_client.py +++ b/src/desktop_client.py @@ -557,7 +557,8 @@ def _desktop_reply_to_post(session, post_id: str, attached_image_description = None is_article: bool = False subject = None - comments_enabled = True + comments_enabled: bool = True + apply_dithering: bool = False city = 'London, England' say_str = 'Sending reply' event_date = None @@ -577,7 +578,8 @@ def _desktop_reply_to_post(session, post_id: str, domain, port, to_nickname, to_domain, to_port, cc_url, http_prefix, reply_message, - comments_enabled, attach, media_type, + comments_enabled, apply_dithering, + attach, media_type, attached_image_description, video_transcript, city, cached_webfingers, person_cache, is_article, @@ -646,7 +648,8 @@ def _desktop_new_post(session, city = 'London, England' is_article: bool = False subject = None - comments_enabled = True + comments_enabled: bool = True + apply_dithering: bool = False subject = None say_str = 'Sending' event_date = None @@ -666,7 +669,8 @@ def _desktop_new_post(session, domain, port, None, '#Public', port, cc_url, http_prefix, new_message, - comments_enabled, attach, media_type, + comments_enabled, apply_dithering, + attach, media_type, attached_image_description, video_transcript, city, cached_webfingers, person_cache, is_article, system_language, languages_understood, @@ -1450,7 +1454,8 @@ def _desktop_new_dm_base(session, to_handle: str, city: str = 'London, England' is_article: bool = False subject = None - comments_enabled = True + comments_enabled: bool = True + apply_dithering: bool = False subject = None # if there is a local PGP key then attempt to encrypt the DM @@ -1510,7 +1515,8 @@ def _desktop_new_dm_base(session, to_handle: str, domain, port, to_nickname, to_domain, to_port, cc_url, http_prefix, new_message, - comments_enabled, attach, media_type, + comments_enabled, apply_dithering, + attach, media_type, attached_image_description, video_transcript, city, cached_webfingers, person_cache, is_article, system_language, languages_understood, diff --git a/src/inbox.py b/src/inbox.py index 05dddcded..037b34832 100644 --- a/src/inbox.py +++ b/src/inbox.py @@ -1444,6 +1444,7 @@ def _bounce_dm(sender_post_id: str, session, http_prefix: str, save_to_file: bool = False client_to_server: bool = False comments_enabled: bool = False + apply_dithering: bool = False attach_image_filename = None media_type = None image_description: str = '' @@ -1468,6 +1469,7 @@ def _bounce_dm(sender_post_id: str, session, http_prefix: str, http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, in_reply_to, in_reply_to_atom_uri, diff --git a/src/media.py b/src/media.py index 62852b2e1..551b347f7 100644 --- a/src/media.py +++ b/src/media.py @@ -686,7 +686,8 @@ def attach_media(base_dir: str, http_prefix: str, content_license_url: str, creator: str, system_language: str, - debug: bool) -> {}: + debug: bool, + apply_dithering: bool) -> {}: """Attaches media to a json object post The description can be None """ @@ -766,7 +767,7 @@ def attach_media(base_dir: str, http_prefix: str, if base_dir: if media_type.startswith('image/'): - if low_bandwidth: + if low_bandwidth or apply_dithering: convert_image_to_low_bandwidth(image_filename) exif_json: list[dict] = [] file_size_original: int = os.path.getsize(image_filename) diff --git a/src/newsdaemon.py b/src/newsdaemon.py index 675bfb337..2494f67b4 100644 --- a/src/newsdaemon.py +++ b/src/newsdaemon.py @@ -637,6 +637,7 @@ def _convert_rss_to_activitypub(base_dir: str, http_prefix: str, # consistent (it's based on the current time, not the # published time), so we change that later save_to_file: bool = False + apply_dithering: bool = False attach_image_filename = None media_type = None image_description = None @@ -650,7 +651,7 @@ def _convert_rss_to_activitypub(base_dir: str, http_prefix: str, blog = create_news_post(base_dir, domain, port, http_prefix, rss_description, - save_to_file, + save_to_file, apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, rss_title, system_language, diff --git a/src/posts.py b/src/posts.py index 927707f18..69bcbde36 100644 --- a/src/posts.py +++ b/src/posts.py @@ -1240,6 +1240,7 @@ def _create_post_s2s(base_dir: str, nickname: str, domain: str, port: int, published: str, new_post_id: str, post_context: {}, to_recipients: [], to_cc: [], in_reply_to: str, sensitive: bool, comments_enabled: bool, + apply_dithering: bool, tags: [], attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, @@ -1410,7 +1411,7 @@ def _create_post_s2s(base_dir: str, nickname: str, domain: str, port: int, media_type, image_description, video_transcript, city, low_bandwidth, media_license_url, media_creator, system_language, - debug) + debug, apply_dithering) else: if debug: print('DEBUG: creating s2s post with no attached media') @@ -1425,6 +1426,7 @@ def _create_post_c2s(base_dir: str, nickname: str, domain: str, port: int, published: str, new_post_id: str, post_context: {}, to_recipients: [], to_cc: [], in_reply_to: str, sensitive: bool, comments_enabled: bool, + apply_dithering: bool, tags: [], attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, @@ -1584,7 +1586,7 @@ def _create_post_c2s(base_dir: str, nickname: str, domain: str, port: int, media_type, image_description, video_transcript, city, low_bandwidth, media_license_url, media_creator, - system_language, debug) + system_language, debug, apply_dithering) else: if debug: print('DEBUG: creating c2s post with no attached media') @@ -1823,6 +1825,7 @@ def create_post_base(base_dir: str, to_url: str, cc_url: str, http_prefix: str, content: str, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, @@ -2022,6 +2025,7 @@ def create_post_base(base_dir: str, published, new_post_id, post_context, to_recipients, to_cc, in_reply_to, sensitive, comments_enabled, + apply_dithering, tags, attach_image_filename, media_type, image_description, video_transcript, city, @@ -2040,6 +2044,7 @@ def create_post_base(base_dir: str, published, new_post_id, post_context, to_recipients, to_cc, in_reply_to, sensitive, comments_enabled, + apply_dithering, tags, attach_image_filename, media_type, image_description, video_transcript, city, @@ -2052,6 +2057,19 @@ def create_post_base(base_dir: str, automatic_quote_approval, session, debug) + # update the image dithering flag + dither_filename = \ + acct_dir(base_dir, nickname, domain) + '/.ditherImage' + if apply_dithering: + if not is_a_file(dither_filename): + save_string('.', dither_filename, + 'EX: unable to save ditherImage flag ' + + dither_filename) + else: + if is_a_file(dither_filename): + erase_file(dither_filename, + 'EX: unable to delete ' + dither_filename) + _create_post_mentions(cc_url, new_post, to_recipients, tags) _create_post_mod_report(base_dir, is_moderation_report, @@ -2290,6 +2308,7 @@ def create_public_post(base_dir: str, nickname: str, domain: str, port: int, http_prefix: str, content: str, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, in_reply_to: str, @@ -2328,6 +2347,7 @@ def create_public_post(base_dir: str, local_actor + '/followers', http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, is_moderation_report, is_article, @@ -2354,6 +2374,7 @@ def create_reading_post(base_dir: str, book_title: str, book_url: str, book_rating: float, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, in_reply_to: str, @@ -2397,6 +2418,7 @@ def create_reading_post(base_dir: str, nickname, domain, port, http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, in_reply_to, @@ -2458,6 +2480,7 @@ def create_blog_post(base_dir: str, nickname: str, domain: str, port: int, http_prefix: str, content: str, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, in_reply_to: str, in_reply_to_atom_uri: str, @@ -2477,6 +2500,7 @@ def create_blog_post(base_dir: str, nickname, domain, port, http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, in_reply_to, in_reply_to_atom_uri, subject, @@ -2501,6 +2525,7 @@ def create_blog_post(base_dir: str, def create_news_post(base_dir: str, domain: str, port: int, http_prefix: str, content: str, save_to_file: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, subject: str, system_language: str, @@ -2525,7 +2550,7 @@ def create_news_post(base_dir: str, create_public_post(base_dir, 'news', domain, port, http_prefix, content, save_to_file, - client_to_server, False, + client_to_server, False, apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, in_reply_to, in_reply_to_atom_uri, subject, @@ -2548,6 +2573,7 @@ def create_question_post(base_dir: str, content: str, q_options: [], save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, subject: str, duration_days: int, @@ -2581,6 +2607,7 @@ def create_question_post(base_dir: str, local_actor + '/followers', http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, is_moderation_report, is_article, @@ -2624,6 +2651,7 @@ def create_unlisted_post(base_dir: str, http_prefix: str, content: str, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, in_reply_to: str, @@ -2657,6 +2685,7 @@ def create_unlisted_post(base_dir: str, 'https://www.w3.org/ns/activitystreams#Public', http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, is_moderation_report, is_article, @@ -2685,6 +2714,7 @@ def create_followers_only_post(base_dir: str, http_prefix: str, content: str, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, in_reply_to: str, @@ -2720,6 +2750,7 @@ def create_followers_only_post(base_dir: str, local_actor + '/followers', None, http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, is_moderation_report, is_article, @@ -2783,6 +2814,7 @@ def create_direct_message_post(base_dir: str, http_prefix: str, content: str, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, in_reply_to: str, @@ -2827,6 +2859,7 @@ def create_direct_message_post(base_dir: str, post_to, post_cc, http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, is_moderation_report, is_article, @@ -2864,6 +2897,7 @@ def create_report_post(base_dir: str, nickname: str, domain: str, port: int, http_prefix: str, content: str, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, debug: bool, subject: str, @@ -2969,6 +3003,7 @@ def create_report_post(base_dir: str, to_url, post_cc, http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, is_moderation_report, is_article, @@ -3177,6 +3212,7 @@ def send_post(signing_priv_key_pem: str, project_version: str, http_prefix: str, content: str, save_to_file: bool, client_to_server: bool, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, federation_list: [], send_threads: [], post_log: [], @@ -3266,6 +3302,7 @@ def send_post(signing_priv_key_pem: str, project_version: str, to_person_id, cc_str, http_prefix, content, save_to_file, client_to_server, comments_enabled, + apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, is_moderation_report, is_article, in_reply_to, diff --git a/src/sendC2S.py b/src/sendC2S.py index 048f6ecf2..dedcfe9b0 100644 --- a/src/sendC2S.py +++ b/src/sendC2S.py @@ -28,6 +28,7 @@ def send_post_via_server(signing_priv_key_pem: str, project_version: str, cc_str: str, http_prefix: str, content: str, comments_enabled: bool, + apply_dithering: bool, attach_image_filename: str, media_type: str, image_description: str, video_transcript: str, city: str, cached_webfingers: {}, person_cache: {}, @@ -133,7 +134,7 @@ def send_post_via_server(signing_priv_key_pem: str, project_version: str, from_nickname, from_domain, from_port, to_person_id, cc_str, http_prefix, content, save_to_file, client_to_server, - comments_enabled, + comments_enabled, apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, is_moderation_report, is_article, in_reply_to, diff --git a/src/tests.py b/src/tests.py index fd4418265..c24c2559b 100644 --- a/src/tests.py +++ b/src/tests.py @@ -832,9 +832,10 @@ def create_server_alice(path: str, domain: str, port: int, add_follower_of_person(path, nickname, domain, 'bob', bob_address, federation_list, False, False) if has_posts: - test_save_to_file = True + test_save_to_file: bool = True client_to_server: bool = False - test_comments_enabled = True + test_comments_enabled: bool = True + test_apply_dithering: bool = False test_attach_image_filename = None test_media_type = None test_image_description = None @@ -869,6 +870,7 @@ def create_server_alice(path: str, domain: str, port: int, test_save_to_file, client_to_server, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, @@ -889,6 +891,7 @@ def create_server_alice(path: str, domain: str, port: int, test_save_to_file, client_to_server, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, @@ -910,6 +913,7 @@ def create_server_alice(path: str, domain: str, port: int, test_save_to_file, client_to_server, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, @@ -1041,6 +1045,7 @@ def create_server_bob(path: str, domain: str, port: int, if has_posts: test_save_to_file: bool = True test_comments_enabled: bool = True + test_apply_dithering: bool = False test_attach_image_filename = None test_image_description = None test_media_type = None @@ -1075,6 +1080,7 @@ def create_server_bob(path: str, domain: str, port: int, test_save_to_file, client_to_server, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, @@ -1096,6 +1102,7 @@ def create_server_bob(path: str, domain: str, port: int, test_save_to_file, client_to_server, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, @@ -1116,6 +1123,7 @@ def create_server_bob(path: str, domain: str, port: int, test_save_to_file, client_to_server, test_comments_enabled, + test_apply_dithering, test_attach_image_filename, test_media_type, test_image_description, test_video_transcript, @@ -1550,13 +1558,16 @@ def test_post_message_between_servers(base_dir: str) -> None: auto_cw_cache: dict = {} searchable_by: list[str] = [] mitm_servers: list[str] = [] + comments_enabled: bool = True + apply_dithering: bool = False send_result = \ send_post(signing_priv_key_pem, __version__, session_alice, alice_dir, 'alice', alice_domain, alice_port, 'bob', bob_domain, bob_port, cc_url, http_prefix, 'Why is a mouse when it spins? ' + 'यह एक परीक्षण है #sillyquestion', - save_to_file, client_to_server, True, + save_to_file, client_to_server, comments_enabled, + apply_dithering, attached_image_filename, media_type, attached_image_description, video_transcript, city, federation_list, @@ -1955,13 +1966,20 @@ def test_follow_between_servers(base_dir: str) -> None: auto_cw_cache: dict = {} searchable_by: list[str] = [] mitm_servers: list[str] = [] + comments_enabled: bool = True + apply_dithering: bool = False + attached_image_filename: str = None + media_type: str = None + attached_image_description: str = None send_result = \ send_post(signing_priv_key_pem, __version__, session_alice, alice_dir, 'alice', alice_domain, alice_port, 'bob', bob_domain, bob_port, cc_url, http_prefix, 'Alice message', save_to_file, - client_to_server, True, - None, None, None, video_transcript, city, federation_list, + client_to_server, comments_enabled, apply_dithering, + attached_image_filename, media_type, + attached_image_description, video_transcript, + city, federation_list, alice_send_threads, alice_post_log, alice_cached_webfingers, alice_person_cache, is_article, system_language, languages_understood, @@ -2375,13 +2393,20 @@ def test_shared_items_federation(base_dir: str) -> None: auto_cw_cache: dict = {} searchable_by: list[str] = [] mitm_servers: list[str] = [] + comments_enabled: bool = True + apply_dithering: bool = False + attached_image_filename: str = None + media_type: str = None + attached_image_description: str = None send_result = \ send_post(signing_priv_key_pem, __version__, session_alice, alice_dir, 'alice', alice_domain, alice_port, 'bob', bob_domain, bob_port, cc_url, http_prefix, 'Alice message', save_to_file, - client_to_server, True, - None, None, None, video_transcript, city, federation_list, + client_to_server, comments_enabled, apply_dithering, + attached_image_filename, media_type, + attached_image_description, + video_transcript, city, federation_list, alice_send_threads, alice_post_log, alice_cached_webfingers, alice_person_cache, is_article, system_language, languages_understood, @@ -2829,13 +2854,20 @@ def test_group_follow(base_dir: str) -> None: auto_cw_cache = {} searchable_by: list[str] = [] mitm_servers: list[str] = [] + comments_enabled: bool = True + apply_dithering: bool = False + attached_image_filename: str = None + media_type: str = None + attached_image_description: str = None send_result = \ send_post(signing_priv_key_pem, __version__, session_alice, alice_dir, 'alice', alice_domain, alice_port, 'testgroup', testgroup_domain, testgroupPort, cc_url, http_prefix, "Alice group message", - save_to_file, client_to_server, True, - None, None, None, video_transcript, city, federation_list, + save_to_file, client_to_server, comments_enabled, + apply_dithering, attached_image_filename, + media_type, attached_image_description, + video_transcript, city, federation_list, alice_send_threads, alice_post_log, alice_cached_webfingers, alice_person_cache, is_article, system_language, languages_understood, @@ -3217,9 +3249,10 @@ def _test_create_person_account(base_dir: str): test_event_end_time = None test_event_category: str = '' test_location = None - test_is_article = False - save_to_file = True - comments_enabled = True + test_is_article: bool = False + save_to_file: bool = True + comments_enabled: bool = True + test_apply_dithering: bool = True attach_image_filename = None media_type = None conversation_id = None @@ -3246,7 +3279,8 @@ def _test_create_person_account(base_dir: str): create_public_post(base_dir, nickname, domain, port, http_prefix, content, save_to_file, client_to_server, - comments_enabled, attach_image_filename, media_type, + comments_enabled, test_apply_dithering, + attach_image_filename, media_type, 'Not suitable for Vogons', '', 'London, England', test_in_reply_to, test_in_reply_to_atom_uri, test_subject, test_schedule_post, @@ -3276,7 +3310,8 @@ def _test_create_person_account(base_dir: str): create_public_post(base_dir, nickname, domain, port, http_prefix, content, save_to_file, client_to_server, - comments_enabled, attach_image_filename, media_type, + comments_enabled, test_apply_dithering, + attach_image_filename, media_type, 'Not suitable for Vogons', '', 'London, England', test_in_reply_to, test_in_reply_to_atom_uri, test_subject, test_schedule_post, @@ -3498,6 +3533,8 @@ def test_client_to_server(base_dir: str): buy_url = '' chat_url = '' video_transcript = None + comments_enabled: bool = True + apply_dithering: bool = False auto_cw_cache = {} searchable_by: list[str] = [] mitm_servers: list[str] = [] @@ -3507,7 +3544,8 @@ def test_client_to_server(base_dir: str): alice_domain, alice_port, 'bob', bob_domain, bob_port, None, http_prefix, 'Sent from my ActivityPub client', - True, attached_image_filename, media_type, + comments_enabled, apply_dithering, + attached_image_filename, media_type, attached_image_description, video_transcript, city, cached_webfingers, person_cache, is_article, @@ -5345,6 +5383,7 @@ def _test_reply_to_public_post(base_dir: str) -> None: save_to_file: bool = False client_to_server: bool = False comments_enabled: bool = True + test_apply_dithering: bool = False attach_image_filename = None media_type = None image_description: str = 'Some description' @@ -5352,13 +5391,13 @@ def _test_reply_to_public_post(base_dir: str) -> None: test_in_reply_to = post_id test_in_reply_to_atom_uri = None test_subject = None - test_schedule_post = False + test_schedule_post: bool = False test_event_date = None test_event_time = None test_event_end_time = None test_event_category = '' test_location = None - test_is_article = False + test_is_article: bool = False conversation_id = None convthread_id = None low_bandwidth: bool = True @@ -5379,6 +5418,7 @@ def _test_reply_to_public_post(base_dir: str) -> None: create_public_post(base_dir, nickname, domain, port, http_prefix, content, save_to_file, client_to_server, comments_enabled, + test_apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, test_in_reply_to, @@ -6458,6 +6498,7 @@ def _test_links_within_post(base_dir: str) -> None: save_to_file: bool = False client_to_server: bool = False comments_enabled: bool = True + test_apply_dithering: bool = False attach_image_filename = None media_type = None image_description = None @@ -6493,6 +6534,7 @@ def _test_links_within_post(base_dir: str) -> None: create_public_post(base_dir, nickname, domain, port, http_prefix, content, save_to_file, client_to_server, comments_enabled, + test_apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, test_in_reply_to, test_in_reply_to_atom_uri, @@ -6536,13 +6578,23 @@ def _test_links_within_post(base_dir: str) -> None: "

#taggedthing

" + save_to_file: bool = False + client_to_server: bool = False + comments_enabled: bool = True + apply_dithering: bool = False + attach_image_filename: str = None + media_type: str = None + image_description: str = '' + video_transcript: str = '' + city: str = '' post_json_object = \ create_public_post(base_dir, nickname, domain, port, http_prefix, - content, - False, - False, True, - None, None, - '', '', None, + content, save_to_file, + client_to_server, comments_enabled, + apply_dithering, + attach_image_filename, media_type, + image_description, + video_transcript, city, test_in_reply_to, test_in_reply_to_atom_uri, test_subject, test_schedule_post, test_event_date, test_event_time, @@ -6564,11 +6616,12 @@ def _test_links_within_post(base_dir: str) -> None: "gerbils and that is all she wrote.

" post_json_object = \ create_public_post(base_dir, nickname, domain, port, http_prefix, - content, - False, - False, True, - None, None, - '', '', None, + content, save_to_file, + client_to_server, comments_enabled, + apply_dithering, + attach_image_filename, media_type, + image_description, + video_transcript, city, test_in_reply_to, test_in_reply_to_atom_uri, test_subject, test_schedule_post, test_event_date, test_event_time, @@ -7657,6 +7710,7 @@ def _test_can_replyto(base_dir: str) -> None: save_to_file: bool = False client_to_server: bool = False comments_enabled: bool = True + test_apply_dithering: bool = False attach_image_filename = None media_type = None image_description = None @@ -7692,6 +7746,7 @@ def _test_can_replyto(base_dir: str) -> None: create_public_post(base_dir, nickname, domain, port, http_prefix, content, save_to_file, client_to_server, comments_enabled, + test_apply_dithering, attach_image_filename, media_type, image_description, video_transcript, city, test_in_reply_to, test_in_reply_to_atom_uri, diff --git a/src/webapp_create_post.py b/src/webapp_create_post.py index 442fe0da0..12e5f1681 100644 --- a/src/webapp_create_post.py +++ b/src/webapp_create_post.py @@ -647,6 +647,12 @@ def html_new_post(edit_post_params: {}, ' \n' + # dithering + dither_filename = acct_dir(base_dir, nickname, domain) + '/.ditherImage' + apply_dithering = is_a_file(dither_filename) + new_post_image_section += \ + edit_check_box(translate['Apply dithering to images.'], + 'ditherImage', apply_dithering) media_creator_str = translate['Media creator'] new_post_image_section += \ edit_text_field(media_creator_str, 'mediaCreator', '', '') diff --git a/translations/ar.json b/translations/ar.json index f444fad05..7760c8da1 100644 --- a/translations/ar.json +++ b/translations/ar.json @@ -772,5 +772,6 @@ "Availability": "التوافر", "Loops Instances": "حلقات التكرار", "Disinformation Instances": "أمثلة على التضليل الإعلامي", - "Allow this account to be added to lists": "السماح بإضافة هذا الحساب إلى القوائم" + "Allow this account to be added to lists": "السماح بإضافة هذا الحساب إلى القوائم", + "Apply dithering to images.": "طبّق تقنية التدرج النقطي (dithering) على الصور." } diff --git a/translations/bn.json b/translations/bn.json index 7888fde48..d60dcb3f9 100644 --- a/translations/bn.json +++ b/translations/bn.json @@ -772,5 +772,6 @@ "Availability": "প্রাপ্যতা", "Loops Instances": "লুপ ইনস্ট্যান্স", "Disinformation Instances": "ভুল তথ্যের উদাহরণ", - "Allow this account to be added to lists": "এই অ্যাকাউন্টটিকে তালিকায় যুক্ত করার অনুমতি দিন" + "Allow this account to be added to lists": "এই অ্যাকাউন্টটিকে তালিকায় যুক্ত করার অনুমতি দিন", + "Apply dithering to images.": "ছবিতে ডিদারিং প্রয়োগ করুন।" } diff --git a/translations/ca.json b/translations/ca.json index 17f8272e3..52d64bcb2 100644 --- a/translations/ca.json +++ b/translations/ca.json @@ -772,5 +772,6 @@ "Availability": "Disponibilitat", "Loops Instances": "Instàncies de bucles", "Disinformation Instances": "Instàncies de desinformació", - "Allow this account to be added to lists": "Permet que aquest compte s'afegeixi a les llistes" + "Allow this account to be added to lists": "Permet que aquest compte s'afegeixi a les llistes", + "Apply dithering to images.": "Aplica el dithering a les imatges." } diff --git a/translations/cy.json b/translations/cy.json index 86390cfe0..fb8350ad8 100644 --- a/translations/cy.json +++ b/translations/cy.json @@ -772,5 +772,6 @@ "Availability": "Argaeledd", "Loops Instances": "Achosion Dolenni", "Disinformation Instances": "Achosion o Ddadwybodaeth", - "Allow this account to be added to lists": "Caniatáu i'r cyfrif hwn gael ei ychwanegu at restrau" + "Allow this account to be added to lists": "Caniatáu i'r cyfrif hwn gael ei ychwanegu at restrau", + "Apply dithering to images.": "Cymhwyso dithering i ddelweddau." } diff --git a/translations/de.json b/translations/de.json index b1e6e48c9..3f41b91de 100644 --- a/translations/de.json +++ b/translations/de.json @@ -772,5 +772,6 @@ "Availability": "Verfügbarkeit", "Loops Instances": "Schleifeninstanzen", "Disinformation Instances": "Fälle von Desinformation", - "Allow this account to be added to lists": "Erlauben, dass dieses Konto zu Listen hinzugefügt wird" + "Allow this account to be added to lists": "Erlauben, dass dieses Konto zu Listen hinzugefügt wird", + "Apply dithering to images.": "Wenden Sie Dithering auf Bilder an." } diff --git a/translations/el.json b/translations/el.json index 15fee87cc..4a470217a 100644 --- a/translations/el.json +++ b/translations/el.json @@ -772,5 +772,6 @@ "Availability": "Διαθεσιμότητα", "Loops Instances": "Παρουσίες βρόχων", "Disinformation Instances": "Περιπτώσεις παραπληροφόρησης", - "Allow this account to be added to lists": "Να επιτρέπεται η προσθήκη αυτού του λογαριασμού σε λίστες" + "Allow this account to be added to lists": "Να επιτρέπεται η προσθήκη αυτού του λογαριασμού σε λίστες", + "Apply dithering to images.": "Εφαρμογή πρόσμειξης σε εικόνες." } diff --git a/translations/en.json b/translations/en.json index 52d2fd512..33380071f 100644 --- a/translations/en.json +++ b/translations/en.json @@ -772,5 +772,6 @@ "Availability": "Availability", "Loops Instances": "Loops Instances", "Disinformation Instances": "Disinformation Instances", - "Allow this account to be added to lists": "Allow this account to be added to lists" + "Allow this account to be added to lists": "Allow this account to be added to lists", + "Apply dithering to images.": "Apply dithering to images." } diff --git a/translations/es.json b/translations/es.json index 4b15a992d..3262c0277 100644 --- a/translations/es.json +++ b/translations/es.json @@ -772,5 +772,6 @@ "Availability": "Disponibilidad", "Loops Instances": "Instancias de bucles", "Disinformation Instances": "Casos de desinformación", - "Allow this account to be added to lists": "Permitir que esta cuenta se añada a listas" + "Allow this account to be added to lists": "Permitir que esta cuenta se añada a listas", + "Apply dithering to images.": "Aplica tramado a las imágenes." } diff --git a/translations/fa.json b/translations/fa.json index 1d778deec..45d7b8f5b 100644 --- a/translations/fa.json +++ b/translations/fa.json @@ -772,5 +772,6 @@ "Availability": "در دسترس بودن", "Loops Instances": "نمونه‌های حلقه‌ها", "Disinformation Instances": "موارد انتشار اطلاعات نادرست", - "Allow this account to be added to lists": "اجازه دهید این حساب به لیست‌ها اضافه شود" + "Allow this account to be added to lists": "اجازه دهید این حساب به لیست‌ها اضافه شود", + "Apply dithering to images.": "اعمال لرزش (dithering) روی تصاویر" } diff --git a/translations/fi.json b/translations/fi.json index 7598dbdfc..f601d7ebb 100644 --- a/translations/fi.json +++ b/translations/fi.json @@ -772,5 +772,6 @@ "Availability": "Saatavuus", "Loops Instances": "Silmukat-instanssit", "Disinformation Instances": "Disinformaatiotapaukset", - "Allow this account to be added to lists": "Salli tämän tilin lisääminen listoihin" + "Allow this account to be added to lists": "Salli tämän tilin lisääminen listoihin", + "Apply dithering to images.": "Käytä kuviin rasterointia." } diff --git a/translations/fr.json b/translations/fr.json index 45de77352..5b377627c 100644 --- a/translations/fr.json +++ b/translations/fr.json @@ -772,5 +772,6 @@ "Availability": "Disponibilité", "Loops Instances": "Instances de boucles", "Disinformation Instances": "Cas de désinformation", - "Allow this account to be added to lists": "Autoriser l'ajout de ce compte à des listes" + "Allow this account to be added to lists": "Autoriser l'ajout de ce compte à des listes", + "Apply dithering to images.": "Appliquez le tramage aux images." } diff --git a/translations/ga.json b/translations/ga.json index 91011c7d8..e445d413c 100644 --- a/translations/ga.json +++ b/translations/ga.json @@ -772,5 +772,6 @@ "Availability": "Infhaighteacht", "Loops Instances": "Cásanna Lúb", "Disinformation Instances": "Cásanna Mífhaisnéise", - "Allow this account to be added to lists": "Ceadaigh an cuntas seo a chur le liostaí" + "Allow this account to be added to lists": "Ceadaigh an cuntas seo a chur le liostaí", + "Apply dithering to images.": "Cuir díodrú i bhfeidhm ar íomhánna." } diff --git a/translations/he.json b/translations/he.json index 6e1c6fd42..351b32084 100644 --- a/translations/he.json +++ b/translations/he.json @@ -772,5 +772,6 @@ "Availability": "זְמִינוּת", "Loops Instances": "מופעי לולאות", "Disinformation Instances": "מקרים של דיסאינפורמציה", - "Allow this account to be added to lists": "אפשר הוספת חשבון זה לרשימות" + "Allow this account to be added to lists": "אפשר הוספת חשבון זה לרשימות", + "Apply dithering to images.": "החלת דיטרינג על תמונות." } diff --git a/translations/hi.json b/translations/hi.json index 782f393e0..a2e0fbdba 100644 --- a/translations/hi.json +++ b/translations/hi.json @@ -772,5 +772,6 @@ "Availability": "उपलब्धता", "Loops Instances": "लूप इंस्टेंस", "Disinformation Instances": "गलत सूचना के उदाहरण", - "Allow this account to be added to lists": "इस अकाउंट को लिस्ट में जोड़ने की अनुमति दें" + "Allow this account to be added to lists": "इस अकाउंट को लिस्ट में जोड़ने की अनुमति दें", + "Apply dithering to images.": "इमेज पर डिथरिंग लागू करें।" } diff --git a/translations/it.json b/translations/it.json index 97bad5b99..07af8ec7f 100644 --- a/translations/it.json +++ b/translations/it.json @@ -772,5 +772,6 @@ "Availability": "Disponibilità", "Loops Instances": "Istanze di cicli", "Disinformation Instances": "Esempi di disinformazione", - "Allow this account to be added to lists": "Consenti l'aggiunta di questo account agli elenchi" + "Allow this account to be added to lists": "Consenti l'aggiunta di questo account agli elenchi", + "Apply dithering to images.": "Applica il dithering alle immagini." } diff --git a/translations/ja.json b/translations/ja.json index bd360fc06..89b365ef8 100644 --- a/translations/ja.json +++ b/translations/ja.json @@ -772,5 +772,6 @@ "Availability": "可用性", "Loops Instances": "ループインスタンス", "Disinformation Instances": "偽情報事例", - "Allow this account to be added to lists": "このアカウントをリストに追加できるようにする" + "Allow this account to be added to lists": "このアカウントをリストに追加できるようにする", + "Apply dithering to images.": "画像にディザリングを適用します。" } diff --git a/translations/ko.json b/translations/ko.json index 5cb2102a2..f3de4fa16 100644 --- a/translations/ko.json +++ b/translations/ko.json @@ -772,5 +772,6 @@ "Availability": "유효성", "Loops Instances": "루프 인스턴스", "Disinformation Instances": "허위 정보 사례", - "Allow this account to be added to lists": "이 계정을 목록에 추가할 수 있도록 허용" + "Allow this account to be added to lists": "이 계정을 목록에 추가할 수 있도록 허용", + "Apply dithering to images.": "이미지에 디더링을 적용합니다." } diff --git a/translations/ku.json b/translations/ku.json index 5de9c2122..d49847329 100644 --- a/translations/ku.json +++ b/translations/ku.json @@ -772,5 +772,6 @@ "Availability": "Berdestbûnî", "Loops Instances": "Nimûneyên Loopan", "Disinformation Instances": "Nimûneyên Dezînformasyonê", - "Allow this account to be added to lists": "Destûrê bide ku ev hesab li navnîşan were zêdekirin" + "Allow this account to be added to lists": "Destûrê bide ku ev hesab li navnîşan were zêdekirin", + "Apply dithering to images.": "Ditheringê li ser wêneyan bicîh bîne." } diff --git a/translations/nl.json b/translations/nl.json index cc6604c61..23e914934 100644 --- a/translations/nl.json +++ b/translations/nl.json @@ -772,5 +772,6 @@ "Availability": "Beschikbaarheid", "Loops Instances": "Lusinstanties", "Disinformation Instances": "Voorbeelden van desinformatie", - "Allow this account to be added to lists": "Toestaan ​​dat dit account aan lijsten wordt toegevoegd" + "Allow this account to be added to lists": "Toestaan ​​dat dit account aan lijsten wordt toegevoegd", + "Apply dithering to images.": "Pas dithering toe op afbeeldingen." } diff --git a/translations/oc.json b/translations/oc.json index 491f5337a..a4ccee324 100644 --- a/translations/oc.json +++ b/translations/oc.json @@ -768,5 +768,6 @@ "Availability": "Disponibilitat", "Loops Instances": "Instàncias de bucles", "Disinformation Instances": "Instàncias de desinformacion", - "Allow this account to be added to lists": "Autorizar aqueste compte a èsser apondut a las listas" + "Allow this account to be added to lists": "Autorizar aqueste compte a èsser apondut a las listas", + "Apply dithering to images.": "Aplicar lo tremolament a d'imatges." } diff --git a/translations/pl.json b/translations/pl.json index e6afad162..692105dd2 100644 --- a/translations/pl.json +++ b/translations/pl.json @@ -772,5 +772,6 @@ "Availability": "Dostępność", "Loops Instances": "Instancje pętli", "Disinformation Instances": "Przypadki dezinformacji", - "Allow this account to be added to lists": "Zezwól na dodawanie tego konta do list" + "Allow this account to be added to lists": "Zezwól na dodawanie tego konta do list", + "Apply dithering to images.": "Zastosuj dithering do obrazów." } diff --git a/translations/pt.json b/translations/pt.json index 138ef0333..1735eced2 100644 --- a/translations/pt.json +++ b/translations/pt.json @@ -772,5 +772,6 @@ "Availability": "Disponibilidade", "Loops Instances": "Instâncias de Loops", "Disinformation Instances": "Casos de desinformação", - "Allow this account to be added to lists": "Permitir que esta conta seja adicionada às listas" + "Allow this account to be added to lists": "Permitir que esta conta seja adicionada às listas", + "Apply dithering to images.": "Aplicar dithering às imagens." } diff --git a/translations/ru.json b/translations/ru.json index 84cef6094..d6a3c3243 100644 --- a/translations/ru.json +++ b/translations/ru.json @@ -772,5 +772,6 @@ "Availability": "Доступность", "Loops Instances": "Экземпляры циклов", "Disinformation Instances": "Случаи дезинформации", - "Allow this account to be added to lists": "Разрешить добавление этого аккаунта в списки" + "Allow this account to be added to lists": "Разрешить добавление этого аккаунта в списки", + "Apply dithering to images.": "Примените дизеринг к изображениям." } diff --git a/translations/sw.json b/translations/sw.json index 6d9431c57..9928f77dc 100644 --- a/translations/sw.json +++ b/translations/sw.json @@ -772,5 +772,6 @@ "Availability": "Upatikanaji", "Loops Instances": "Matukio ya Mizunguko", "Disinformation Instances": "Matukio ya Taarifa Potofu", - "Allow this account to be added to lists": "Ruhusu akaunti hii iongezwe kwenye orodha" + "Allow this account to be added to lists": "Ruhusu akaunti hii iongezwe kwenye orodha", + "Apply dithering to images.": "Weka upau wa kuchorea kwenye picha." } diff --git a/translations/tr.json b/translations/tr.json index bb5342f9c..b66f0c9b9 100644 --- a/translations/tr.json +++ b/translations/tr.json @@ -772,5 +772,6 @@ "Availability": "Müsaitlik", "Loops Instances": "Döngü Örnekleri", "Disinformation Instances": "Dezenformasyon Vakaları", - "Allow this account to be added to lists": "Bu hesabın listelere eklenmesine izin ver" + "Allow this account to be added to lists": "Bu hesabın listelere eklenmesine izin ver", + "Apply dithering to images.": "Görüntülere dithering uygulayın." } diff --git a/translations/uk.json b/translations/uk.json index 08de33c37..b547aad3c 100644 --- a/translations/uk.json +++ b/translations/uk.json @@ -772,5 +772,6 @@ "Availability": "Наявність", "Loops Instances": "Екземпляри циклів", "Disinformation Instances": "Випадки дезінформації", - "Allow this account to be added to lists": "Дозволити додавання цього облікового запису до списків" + "Allow this account to be added to lists": "Дозволити додавання цього облікового запису до списків", + "Apply dithering to images.": "Застосуйте дизеринг до зображень." } diff --git a/translations/yi.json b/translations/yi.json index 0838f7143..c8da171ad 100644 --- a/translations/yi.json +++ b/translations/yi.json @@ -772,5 +772,6 @@ "Availability": "פאַראַנען", "Loops Instances": "לופּס אינסטאַנסן", "Disinformation Instances": "דיסאינפארמאציע אינסטאַנצן", - "Allow this account to be added to lists": "ערלויבן דעם חשבון צו ווערן צוגעגעבן צו ליסטעס" + "Allow this account to be added to lists": "ערלויבן דעם חשבון צו ווערן צוגעגעבן צו ליסטעס", + "Apply dithering to images.": "צולייגן דיטערינג צו בילדער." } diff --git a/translations/zh.json b/translations/zh.json index ab4e0ad41..a351c8b94 100644 --- a/translations/zh.json +++ b/translations/zh.json @@ -772,5 +772,6 @@ "Availability": "可用性", "Loops Instances": "循环实例", "Disinformation Instances": "虚假信息实例", - "Allow this account to be added to lists": "允许将此帐户添加到列表中" + "Allow this account to be added to lists": "允许将此帐户添加到列表中", + "Apply dithering to images.": "对图像应用抖动处理。" }